diff options
author | dillon <dillon@FreeBSD.org> | 2001-11-05 18:48:54 +0000 |
---|---|---|
committer | dillon <dillon@FreeBSD.org> | 2001-11-05 18:48:54 +0000 |
commit | 1147eaf58a59e2d2aa15fb9395dc939c237e6269 (patch) | |
tree | de03e156782fad9ffef4684a7cf3f1908967e835 /sys/ufs | |
parent | 815c903d62ca6edef2915e089d29443365138986 (diff) | |
download | FreeBSD-src-1147eaf58a59e2d2aa15fb9395dc939c237e6269.zip FreeBSD-src-1147eaf58a59e2d2aa15fb9395dc939c237e6269.tar.gz |
Implement IO_NOWDRAIN and B_NOWDRAIN - prevents the buffer cache from blocking
in wdrain during a write. This flag needs to be used in devices whos
strategy routines turn-around and issue another high level I/O, such as
when MD turns around and issues a VOP_WRITE to vnode backing store, in order
to avoid deadlocking the dirty buffer draining code.
Remove a vprintf() warning from MD when the backing vnode is found to be
in-use. The syncer of buf_daemon could be flushing the backing vnode at
the time of an MD operation so the warning is not correct.
MFC after: 1 week
Diffstat (limited to 'sys/ufs')
-rw-r--r-- | sys/ufs/ufs/ufs_readwrite.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/ufs/ufs/ufs_readwrite.c b/sys/ufs/ufs/ufs_readwrite.c index 83673eb..bc19b98 100644 --- a/sys/ufs/ufs/ufs_readwrite.c +++ b/sys/ufs/ufs/ufs_readwrite.c @@ -511,6 +511,8 @@ WRITE(ap) break; if (ioflag & IO_DIRECT) bp->b_flags |= B_DIRECT; + if (ioflag & IO_NOWDRAIN) + bp->b_flags |= B_NOWDRAIN; if (uio->uio_offset + xfersize > ip->i_size) { ip->i_size = uio->uio_offset + xfersize; |