svn commit: r267060 - head/sys/fs/tmpfs

Konstantin Belousov kib at FreeBSD.org
Wed Jun 4 15:30:49 UTC 2014


Author: kib
Date: Wed Jun  4 15:30:49 2014
New Revision: 267060
URL: http://svnweb.freebsd.org/changeset/base/267060

Log:
  Allow shared locking for the tmpfs vnodes.
  
  Tested by:	pho
  Sponsored by:	The FreeBSD Foundation
  MFC after:	1 week

Modified:
  head/sys/fs/tmpfs/tmpfs_subr.c

Modified: head/sys/fs/tmpfs/tmpfs_subr.c
==============================================================================
--- head/sys/fs/tmpfs/tmpfs_subr.c	Wed Jun  4 15:18:46 2014	(r267059)
+++ head/sys/fs/tmpfs/tmpfs_subr.c	Wed Jun  4 15:30:49 2014	(r267060)
@@ -595,6 +595,8 @@ loop1:
 	default:
 		panic("tmpfs_alloc_vp: type %p %d", node, (int)node->tn_type);
 	}
+	if (vp->v_type != VFIFO)
+		VN_LOCK_ASHARE(vp);
 
 	error = insmntque1(vp, mp, tmpfs_insmntque_dtr, NULL);
 	if (error)


More information about the svn-src-head mailing list