summaryrefslogtreecommitdiffstats
path: root/sys/dev/md
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2003-05-31 16:42:45 +0000
committerphk <phk@FreeBSD.org>2003-05-31 16:42:45 +0000
commit0129a20107a4d816f5acb9c683952803b97583be (patch)
tree5bac77896fbd3b5412e6f42140c8335ad91f96d2 /sys/dev/md
parent8c39502975cf4f5d36d87e3991fb70ba5ce2f8ac (diff)
downloadFreeBSD-src-0129a20107a4d816f5acb9c683952803b97583be.zip
FreeBSD-src-0129a20107a4d816f5acb9c683952803b97583be.tar.gz
The IO_NOWDRAIN and B_NOWDRAIN hacks are no longer needed to prevent
deadlocks with vnode backed md(4) devices because md now uses a kthread to run the bio requests instead of doing it directly from the bio down path.
Diffstat (limited to 'sys/dev/md')
-rw-r--r--sys/dev/md/md.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/md/md.c b/sys/dev/md/md.c
index 7071a3e..1577f02 100644
--- a/sys/dev/md/md.c
+++ b/sys/dev/md/md.c
@@ -497,8 +497,7 @@ mdstart_vnode(struct md_s *sc, struct bio *bp)
auio.uio_td = curthread;
/*
* When reading set IO_DIRECT to try to avoid double-caching
- * the data. When writing IO_DIRECT is not optimal, but we
- * must set IO_NOWDRAIN to avoid a wdrain deadlock.
+ * the data. When writing IO_DIRECT is not optimal.
*/
if (bp->bio_cmd == BIO_READ) {
vn_lock(sc->vnode, LK_EXCLUSIVE | LK_RETRY, curthread);
@@ -506,7 +505,7 @@ mdstart_vnode(struct md_s *sc, struct bio *bp)
} else {
(void) vn_start_write(sc->vnode, &mp, V_WAIT);
vn_lock(sc->vnode, LK_EXCLUSIVE | LK_RETRY, curthread);
- error = VOP_WRITE(sc->vnode, &auio, IO_NOWDRAIN, sc->cred);
+ error = VOP_WRITE(sc->vnode, &auio, 0, sc->cred);
vn_finished_write(mp);
}
VOP_UNLOCK(sc->vnode, 0, curthread);
OpenPOWER on IntegriCloud