diff options
author | Trond Myklebust <trond.myklebust@hammerspace.com> | 2022-02-07 13:37:00 -0500 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@hammerspace.com> | 2022-03-02 08:43:38 -0500 |
commit | 580f236737d13ee25d5b0b1d124f50014fe6833b (patch) | |
tree | d139d59e0826080269b22b243829a6e298c3a62c /include/linux/nfs_fs.h | |
parent | c8f0523ba398b72ffdb6e41930c089b75a6e2acf (diff) | |
download | linux-580f236737d13ee25d5b0b1d124f50014fe6833b.tar.gz linux-580f236737d13ee25d5b0b1d124f50014fe6833b.tar.bz2 linux-580f236737d13ee25d5b0b1d124f50014fe6833b.zip |
NFS: Adjust the amount of readahead performed by NFS readdir
The current NFS readdir code will always try to maximise the amount of
readahead it performs on the assumption that we can cache anything that
isn't immediately read by the process.
There are several cases where this assumption breaks down, including
when the 'ls -l' heuristic kicks in to try to force use of readdirplus
as a batch replacement for lookup/getattr.
This patch therefore tries to tone down the amount of readahead we
perform, and adjust it to try to match the amount of data being
requested by user space.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'include/linux/nfs_fs.h')
-rw-r--r-- | include/linux/nfs_fs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index 1c533f2c1f36..691a27936849 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h @@ -107,6 +107,7 @@ struct nfs_open_dir_context { __u64 dup_cookie; __u64 last_cookie; pgoff_t page_index; + unsigned int dtsize; signed char duped; bool eof; }; |