summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/vm/vm_pager.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/vm/vm_pager.c b/sys/vm/vm_pager.c
index 342c98a20873..46bdd411bee9 100644
--- a/sys/vm/vm_pager.c
+++ b/sys/vm/vm_pager.c
@@ -371,7 +371,6 @@ getpbuf(pfreecnt)
struct buf *bp;
s = splvm();
- GIANT_REQUIRED;
mtx_lock(&pbuf_mtx);
for (;;) {
@@ -445,7 +444,6 @@ relpbuf(bp, pfreecnt)
int s;
s = splvm();
- mtx_lock(&pbuf_mtx);
if (bp->b_rcred != NOCRED) {
crfree(bp->b_rcred);
@@ -461,6 +459,7 @@ relpbuf(bp, pfreecnt)
BUF_UNLOCK(bp);
+ mtx_lock(&pbuf_mtx);
TAILQ_INSERT_HEAD(&bswlist, bp, b_freelist);
if (bswneeded) {