summaryrefslogtreecommitdiffstats
path: root/sys/ufs
diff options
context:
space:
mode:
authordillon <dillon@FreeBSD.org>2001-12-20 22:42:27 +0000
committerdillon <dillon@FreeBSD.org>2001-12-20 22:42:27 +0000
commitac9876d609290ddd585a1e5a67550061f01c20dd (patch)
tree74464ed2703c6925992ebe509294859864e96118 /sys/ufs
parent53b1a7ecefc98fa3a2e71925a3be359d4873214b (diff)
downloadFreeBSD-src-ac9876d609290ddd585a1e5a67550061f01c20dd.zip
FreeBSD-src-ac9876d609290ddd585a1e5a67550061f01c20dd.tar.gz
Fix a BUF_TIMELOCK race against BUF_LOCK and fix a deadlock in vget()
against VM_WAIT in the pageout code. Both fixes involve adjusting the lockmgr's timeout capability so locks obtained with timeouts do not interfere with locks obtained without a timeout. Hopefully MFC: before the 4.5 release
Diffstat (limited to 'sys/ufs')
-rw-r--r--sys/ufs/ffs/ffs_vfsops.c2
-rw-r--r--sys/ufs/ifs/ifs_vfsops.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c
index d6bc8b1..a9985d5 100644
--- a/sys/ufs/ffs/ffs_vfsops.c
+++ b/sys/ufs/ffs/ffs_vfsops.c
@@ -1186,7 +1186,7 @@ restart:
* FFS supports lock sharing in the stack of vnodes
*/
vp->v_vnlock = &vp->v_lock;
- lockinit(vp->v_vnlock, PINOD, "inode", 0, LK_CANRECURSE);
+ lockinit(vp->v_vnlock, PINOD, "inode", VLKTIMEOUT, LK_CANRECURSE);
vp->v_data = ip;
ip->i_vnode = vp;
ip->i_fs = fs = ump->um_fs;
diff --git a/sys/ufs/ifs/ifs_vfsops.c b/sys/ufs/ifs/ifs_vfsops.c
index 0cbf5d0..7eade14 100644
--- a/sys/ufs/ifs/ifs_vfsops.c
+++ b/sys/ufs/ifs/ifs_vfsops.c
@@ -221,7 +221,7 @@ restart:
* IFS supports lock sharing in the stack of vnodes
*/
vp->v_vnlock = &vp->v_lock;
- lockinit(vp->v_vnlock, PINOD, "inode", 0, LK_CANRECURSE);
+ lockinit(vp->v_vnlock, PINOD, "inode", VLKTIMEOUT, LK_CANRECURSE);
vp->v_data = ip;
ip->i_vnode = vp;
ip->i_fs = fs = ump->um_fs;
OpenPOWER on IntegriCloud