diff options
author | dyson <dyson@FreeBSD.org> | 1996-12-29 02:44:37 +0000 |
---|---|---|
committer | dyson <dyson@FreeBSD.org> | 1996-12-29 02:44:37 +0000 |
commit | baa03b956c25159833733ce567a847c13e9bd032 (patch) | |
tree | b2aa4239586797edd5ac58576497d919af438876 /sys/gnu/ext2fs/ext2_readwrite.c | |
parent | 5f299ee7718b583b973c7980e24f27dc06421eb8 (diff) | |
download | FreeBSD-src-baa03b956c25159833733ce567a847c13e9bd032.zip FreeBSD-src-baa03b956c25159833733ce567a847c13e9bd032.tar.gz |
This commit is the embodiment of some VFS read clustering improvements.
Firstly, now our read-ahead clustering is on a file descriptor basis and not
on a per-vnode basis. This will allow multiple processes reading the
same file to take advantage of read-ahead clustering. Secondly, there
previously was a problem with large reads still using the ramp-up
algorithm. Of course, that was bogus, and now we read the entire
"chunk" off of the disk in one operation. The read-ahead clustering
algorithm should use less CPU than the previous also (I hope :-)).
Diffstat (limited to 'sys/gnu/ext2fs/ext2_readwrite.c')
-rw-r--r-- | sys/gnu/ext2fs/ext2_readwrite.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/gnu/ext2fs/ext2_readwrite.c b/sys/gnu/ext2fs/ext2_readwrite.c index de13ed0..b96b8ad 100644 --- a/sys/gnu/ext2fs/ext2_readwrite.c +++ b/sys/gnu/ext2fs/ext2_readwrite.c @@ -114,7 +114,8 @@ READ(ap) error = bread(vp, lbn, size, NOCRED, &bp); else if (doclusterread) error = cluster_read(vp, - ip->i_size, lbn, size, NOCRED, &bp); + ip->i_size, lbn, size, NOCRED, + uio->uio_resid, (ap->a_ioflag >> 16), &bp); else if (lbn - 1 == vp->v_lastr) { int nextsize = BLKSIZE(fs, ip, nextlbn); error = breadn(vp, lbn, |