summaryrefslogtreecommitdiffstats
path: root/sys/isa/fd.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/isa/fd.c')
-rw-r--r--sys/isa/fd.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/isa/fd.c b/sys/isa/fd.c
index 77ebb36..36e5524 100644
--- a/sys/isa/fd.c
+++ b/sys/isa/fd.c
@@ -47,7 +47,7 @@
* SUCH DAMAGE.
*
* from: @(#)fd.c 7.4 (Berkeley) 5/25/91
- * $Id: fd.c,v 1.145 1999/05/30 16:52:12 phk Exp $
+ * $Id: fd.c,v 1.146 1999/05/31 18:39:16 dfr Exp $
*
*/
@@ -2196,7 +2196,9 @@ fdformat(dev, finfo, p)
*/
PHOLD(p);
bzero((void *)bp, sizeof(struct buf));
- bp->b_flags = B_BUSY | B_PHYS | B_FORMAT;
+ BUF_LOCKINIT(bp);
+ BUF_LOCK(bp, LK_EXCLUSIVE);
+ bp->b_flags = B_PHYS | B_FORMAT;
/*
* calculate a fake blkno, so fdstrategy() would initiate a
@@ -2232,6 +2234,8 @@ fdformat(dev, finfo, p)
* allow the process to be swapped
*/
PRELE(p);
+ BUF_UNLOCK(bp);
+ BUF_LOCKFREE(bp);
free(bp, M_TEMP);
return rv;
}
OpenPOWER on IntegriCloud