svn commit: r197152 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs

Pawel Jakub Dawidek pjd at FreeBSD.org
Sun Sep 13 10:29:52 UTC 2009


Author: pjd
Date: Sun Sep 13 10:29:51 2009
New Revision: 197152
URL: http://svn.freebsd.org/changeset/base/197152

Log:
  Extend scope of the z_teardown_lock lock for consistency and "just in case".
  
  MFC after:	3 days

Modified:
  head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c

Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c
==============================================================================
--- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c	Sun Sep 13 10:25:33 2009	(r197151)
+++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c	Sun Sep 13 10:29:51 2009	(r197152)
@@ -1185,8 +1185,6 @@ zfs_lookup(vnode_t *dvp, char *nm, vnode
 		}
 	}
 
-	ZFS_EXIT(zfsvfs);
-
 	/* Translate errors and add SAVENAME when needed. */
 	if (cnp->cn_flags & ISLASTCN) {
 		switch (nameiop) {
@@ -1217,6 +1215,7 @@ zfs_lookup(vnode_t *dvp, char *nm, vnode
 		if (error != 0) {
 			VN_RELE(*vpp);
 			*vpp = NULL;
+			ZFS_EXIT(zfsvfs);
 			return (error);
 		}
 	}
@@ -1238,6 +1237,8 @@ zfs_lookup(vnode_t *dvp, char *nm, vnode
 	}
 #endif
 
+	ZFS_EXIT(zfsvfs);
+
 	return (error);
 }
 


More information about the svn-src-head mailing list