aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXin LI <delphij@FreeBSD.org>2007-06-08 07:05:08 +0000
committerXin LI <delphij@FreeBSD.org>2007-06-08 07:05:08 +0000
commit7b8c8b858c1f611ec3fe35565ec7fcf72f2c76c7 (patch)
treedef99a338215a5fcf24180e1057a8d4498825952
parent4f68049e7bbdbfd60e01f3dab5ab511d67331dbb (diff)
downloadsrc-7b8c8b858c1f611ec3fe35565ec7fcf72f2c76c7.tar.gz
src-7b8c8b858c1f611ec3fe35565ec7fcf72f2c76c7.zip
In getblk(), before gbincore(), use BO_LOCK directly when locking
the bufobj, rather than using VI_LOCK, like what was done with revision 1.453.
Notes
Notes: svn path=/head/; revision=170424
-rw-r--r--sys/kern/vfs_bio.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c
index 18c6d59cb550..58cedf360913 100644
--- a/sys/kern/vfs_bio.c
+++ b/sys/kern/vfs_bio.c
@@ -2450,7 +2450,7 @@ loop:
mtx_unlock(&nblock);
}
- VI_LOCK(vp);
+ BO_LOCK(bo);
bp = gbincore(bo, blkno);
if (bp != NULL) {
int lockflags;
@@ -2579,7 +2579,7 @@ loop:
* returned by getnewbuf() is locked. Note that the returned
* buffer is also considered valid (not marked B_INVAL).
*/
- VI_UNLOCK(vp);
+ BO_UNLOCK(bo);
/*
* If the user does not want us to create the buffer, bail out
* here.