Don't flush possibilly relocated file system block if write is done
asynchronously. They will be flushed later when necessary and flushing now makes sequential write access very slow.
This commit is contained in:
parent
db8595f14f
commit
c17241f92a
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ufs_inode.c,v 1.22 2001/02/27 02:55:40 chs Exp $ */
|
||||
/* $NetBSD: ufs_inode.c,v 1.23 2001/04/18 03:48:23 enami Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1991, 1993
|
||||
|
@ -288,9 +288,10 @@ out:
|
|||
* We need to flush pages to the new disk locations.
|
||||
*/
|
||||
|
||||
(uobj->pgops->pgo_flush)(uobj, oldeof & ~(bsize - 1),
|
||||
MIN((oldeof + bsize) & ~(bsize - 1), neweof),
|
||||
PGO_CLEANIT | ((flags & B_SYNC) ? PGO_SYNCIO : 0));
|
||||
if ((flags & B_SYNC) != 0)
|
||||
(*uobj->pgops->pgo_flush)(uobj, oldeof & ~(bsize - 1),
|
||||
MIN((oldeof + bsize) & ~(bsize - 1), neweof),
|
||||
PGO_CLEANIT | PGO_SYNCIO);
|
||||
}
|
||||
if (pgs2[0] != NULL) {
|
||||
uvm_page_unbusy(pgs2, npages2);
|
||||
|
|
Loading…
Reference in New Issue