mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-12 09:58:36 +00:00
Partially fixed write clustering for cases where cluster_wbuild() is
called from vfs_bio_awrite() without going through cluster_write() or ufs_bmaparray(), in particular for all writes to block disk devices. Only ufs_bmaparray() sets vp->v_maxio in a correct way, and it doesn't seem to be called early enough even for regular files.
This commit is contained in:
parent
91d56ec1d0
commit
809e3a8464
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=35595
@ -33,7 +33,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)vfs_cluster.c 8.7 (Berkeley) 2/13/94
|
||||
* $Id: vfs_cluster.c,v 1.59 1998/03/16 18:39:41 julian Exp $
|
||||
* $Id: vfs_cluster.c,v 1.60 1998/03/19 22:48:13 dyson Exp $
|
||||
*/
|
||||
|
||||
#include "opt_debug_cluster.h"
|
||||
@ -648,6 +648,9 @@ cluster_wbuild(vp, size, start_lbn, len)
|
||||
int i, j, s;
|
||||
int totalwritten = 0;
|
||||
int dbsize = btodb(size);
|
||||
|
||||
if (vp->v_maxio == 0)
|
||||
vp->v_maxio = DFLTPHYS;
|
||||
while (len > 0) {
|
||||
s = splbio();
|
||||
if (((tbp = gbincore(vp, start_lbn)) == NULL) ||
|
||||
|
Loading…
Reference in New Issue
Block a user