summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_descrip.c
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2008-11-03 20:31:00 +0000
committerjhb <jhb@FreeBSD.org>2008-11-03 20:31:00 +0000
commitee8312c8bb0864cea61a7e69692721d017fad2b0 (patch)
tree5032e5735ee46031c2d08581b929a41b96043dea /sys/kern/kern_descrip.c
parent26a604f3bccb7c4a377c7cbf4facbae8c20e1fed (diff)
downloadFreeBSD-src-ee8312c8bb0864cea61a7e69692721d017fad2b0.zip
FreeBSD-src-ee8312c8bb0864cea61a7e69692721d017fad2b0.tar.gz
Use shared vnode locks instead of exclusive vnode locks for the access(),
chdir(), chroot(), eaccess(), fpathconf(), fstat(), fstatfs(), lseek() (when figuring out the current size of the file in the SEEK_END case), pathconf(), readlink(), and statfs() system calls. Submitted by: ups (mostly) Tested by: pho MFC after: 1 month
Diffstat (limited to 'sys/kern/kern_descrip.c')
-rw-r--r--sys/kern/kern_descrip.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c
index ec07d0f..df92aca 100644
--- a/sys/kern/kern_descrip.c
+++ b/sys/kern/kern_descrip.c
@@ -1241,7 +1241,7 @@ fpathconf(struct thread *td, struct fpathconf_args *uap)
if (vp != NULL) {
int vfslocked;
vfslocked = VFS_LOCK_GIANT(vp->v_mount);
- vn_lock(vp, LK_EXCLUSIVE | LK_RETRY);
+ vn_lock(vp, LK_SHARED | LK_RETRY);
error = VOP_PATHCONF(vp, uap->name, td->td_retval);
VOP_UNLOCK(vp, 0);
VFS_UNLOCK_GIANT(vfslocked);
OpenPOWER on IntegriCloud