diff --git a/sys/dev/vinum/vinumrequest.c b/sys/dev/vinum/vinumrequest.c index c81a4ca090ad..ffbc76bd4a80 100644 --- a/sys/dev/vinum/vinumrequest.c +++ b/sys/dev/vinum/vinumrequest.c @@ -33,7 +33,7 @@ * otherwise) arising in any way out of the use of this software, even if * advised of the possibility of such damage. * - * $Id: vinumrequest.c,v 1.26 1999/06/24 08:56:03 grog Exp $ + * $Id: vinumrequest.c,v 1.23 1999/03/20 21:58:38 grog Exp grog $ */ #include @@ -725,7 +725,10 @@ build_rq_buffer(struct rqelement *rqe, struct plex *plex) /* Initialize the buf struct */ bp->b_flags = ubp->b_flags & (B_NOCACHE | B_READ | B_ASYNC); /* copy these flags from user bp */ - bp->b_flags |= B_CALL; /* inform us when it's done */ + bp->b_flags |= B_CALL; /* inform us when it's done */ + BUF_LOCKINIT(bp); /* get a lock for the buffer */ + BUF_LOCK(bp, LK_EXCLUSIVE); /* and lock it */ + /* * XXX Should we check for reviving plexes here, and * set B_ORDERED if so? diff --git a/sys/dev/vinum/vinumrevive.c b/sys/dev/vinum/vinumrevive.c index 25c0ff8b6bf9..9eec5f5170a9 100644 --- a/sys/dev/vinum/vinumrevive.c +++ b/sys/dev/vinum/vinumrevive.c @@ -33,7 +33,7 @@ * otherwise) arising in any way out of the use of this software, even if * advised of the possibility of such damage. * - * $Id: vinumrevive.c,v 1.12 1999/05/15 05:49:21 grog Exp $ + * $Id: vinumrevive.c,v 1.7 1999/02/28 02:12:18 grog Exp grog $ */ #include @@ -146,6 +146,8 @@ revive_block(int sdno) bp->b_dev = VINUMRBDEV(sdno, VINUM_RAWSD_TYPE); /* create the device number */ bp->b_flags = B_ORDERED; /* and make this an ordered write */ + BUF_LOCKINIT(bp); /* get a lock for the buffer */ + BUF_LOCK(bp, LK_EXCLUSIVE); /* and lock it */ bp->b_resid = 0x0; bp->b_blkno = sd->revived; /* write it to here */ sdio(bp); /* perform the I/O */