diff options
author | Matthew Dillon <dillon@FreeBSD.org> | 2002-12-28 20:28:10 +0000 |
---|---|---|
committer | Matthew Dillon <dillon@FreeBSD.org> | 2002-12-28 20:28:10 +0000 |
commit | 45587e2514893f6a1b4194908398c95700faab2b (patch) | |
tree | 095dcb0d1beff9fe8e8cfa8605299973e1abf296 /sys/kern/vfs_vnops.c | |
parent | 06d66a71a1f44f649e1e41fc6dc9b51b07c91585 (diff) | |
download | src-45587e2514893f6a1b4194908398c95700faab2b.tar.gz src-45587e2514893f6a1b4194908398c95700faab2b.zip |
Abstract-out the constants for the sequential heuristic.
No operational changes.
MFC after: 1 day
Notes
Notes:
svn path=/head/; revision=108356
Diffstat (limited to 'sys/kern/vfs_vnops.c')
-rw-r--r-- | sys/kern/vfs_vnops.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index 01afcd9701a9..a801728c721e 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -340,9 +340,9 @@ sequential_heuristic(struct uio *uio, struct file *fp) * are. */ fp->f_seqcount += (uio->uio_resid + BKVASIZE - 1) / BKVASIZE; - if (fp->f_seqcount >= 127) - fp->f_seqcount = 127; - return(fp->f_seqcount << 16); + if (fp->f_seqcount > IO_SEQMAX) + fp->f_seqcount = IO_SEQMAX; + return(fp->f_seqcount << IO_SEQSHIFT); } /* |