Subject: PR/34775 CVS commit: src/sys
To: None <,,,>
From: Chuck Silvers <>
List: netbsd-bugs
Date: 02/04/2007 15:05:12
The following reply was made to PR kern/34775; it has been noted by GNATS.

From: Chuck Silvers <>
Subject: PR/34775 CVS commit: src/sys
Date: Sun,  4 Feb 2007 15:03:20 +0000 (UTC)

 Module Name:	src
 Committed By:	chs
 Date:		Sun Feb  4 15:03:20 UTC 2007
 Modified Files:
 	src/sys/fs/union: union_subr.c union_vfsops.c union_vnops.c
 	src/sys/kern: vfs_lookup.c vfs_syscalls.c
 	src/sys/nfs: nfs_export.c
 Log Message:
 more fixes for the new vnode locking scheme:
  - don't use SAVESTART in calls to relookup() from unionfs,
    just vref() the desired vnode when we need to.
  - fix locking and refcounting in the unionfs EEXIST error cases.
  - release any vnode locks before calling VFS_ROOT(), vfs_busy() is enough.
    this allows us to simplify union_root() and fix PR 3006.
  - union_lock() doesn't handle shared lock requests correctly,
    so convert them to exclusive instead.  fixes PR 34775.
  - in relookup(), avoid reusing "dp" for different purposes,
    the error handling wasn't right.  (actually just get rid of dp.)
    also, change relookup() to ignore LOCKLEAF and always return the
    vnode locked since the callers already expect this.
 To generate a diff of this commit:
 cvs rdiff -r1.23 -r1.24 src/sys/fs/union/union_subr.c
 cvs rdiff -r1.42 -r1.43 src/sys/fs/union/union_vfsops.c
 cvs rdiff -r1.18 -r1.19 src/sys/fs/union/union_vnops.c
 cvs rdiff -r1.80 -r1.81 src/sys/kern/vfs_lookup.c
 cvs rdiff -r1.297 -r1.298 src/sys/kern/vfs_syscalls.c
 cvs rdiff -r1.24 -r1.25 src/sys/nfs/nfs_export.c
 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.