diff options
author | 2000-11-09 16:46:52 +0000 | |
---|---|---|
committer | 2000-11-09 16:46:52 +0000 | |
commit | b26ca4767d855f178facf7512d2118a589f3d582 (patch) | |
tree | 6cde8b5390335400999986c8e86984cc96e8b054 /sys/kern/kern_physio.c | |
parent | add uvm(9) from netbsd; as a side effect increase art's guilt factor ;) (diff) | |
download | wireguard-openbsd-b26ca4767d855f178facf7512d2118a589f3d582.tar.xz wireguard-openbsd-b26ca4767d855f178facf7512d2118a589f3d582.zip |
Use PHOLD/PRELE instead of manually fiddling with p_holdcnt.
Diffstat (limited to 'sys/kern/kern_physio.c')
-rw-r--r-- | sys/kern/kern_physio.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/kern_physio.c b/sys/kern/kern_physio.c index 2086bab06a8..6aa0b547718 100644 --- a/sys/kern/kern_physio.c +++ b/sys/kern/kern_physio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_physio.c,v 1.8 2000/03/16 22:11:04 art Exp $ */ +/* $OpenBSD: kern_physio.c,v 1.9 2000/11/09 16:46:52 art Exp $ */ /* $NetBSD: kern_physio.c,v 1.28 1997/05/19 10:43:28 pk Exp $ */ /*- @@ -182,7 +182,7 @@ physio(strategy, bp, dev, flags, minphys, uio) * saves it in b_saveaddr. However, vunmapbuf() * restores it. */ - p->p_holdcnt++; + PHOLD(p); #if defined(UVM) uvm_vslock(p, bp->b_data, todo, (flags & B_READ) ? VM_PROT_READ | VM_PROT_WRITE : VM_PROT_READ); @@ -224,7 +224,7 @@ physio(strategy, bp, dev, flags, minphys, uio) #else vsunlock(bp->b_data, todo); #endif - p->p_holdcnt--; + PRELE(p); /* remember error value (save a splbio/splx pair) */ if (bp->b_flags & B_ERROR) |