diff options
| author | Christoph Hellwig <hch@lst.de> | 2025-07-18 11:14:50 +0300 |
|---|---|---|
| committer | Trond Myklebust <trond.myklebust@hammerspace.com> | 2025-07-22 15:10:41 +0300 |
| commit | f5b3108e6a14418b120a3c38ca589b8d6cf87627 (patch) | |
| tree | 8ba599afdc2b384122ae7a8e613c0c6f874b34f8 /include/linux | |
| parent | 2fb4af5ea3c735a205d97de10f044f809b20af51 (diff) | |
| download | linux-f5b3108e6a14418b120a3c38ca589b8d6cf87627.tar.xz | |
NFS: use a hash table for delegation lookup
nfs_delegation_find_inode currently has to walk the entire list of
delegations per inode, which can become pretty large, and can become even
larger when increasing the delegation watermark.
Add a hash table to speed up the delegation lookup, sized as a fraction
of the delegation watermark.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20250718081509.2607553-6-hch@lst.de
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/nfs_fs_sb.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/nfs_fs_sb.h b/include/linux/nfs_fs_sb.h index a9b44f12623f..d30c0245031c 100644 --- a/include/linux/nfs_fs_sb.h +++ b/include/linux/nfs_fs_sb.h @@ -255,6 +255,8 @@ struct nfs_server { struct list_head layouts; struct list_head delegations; atomic_long_t nr_active_delegations; + unsigned int delegation_hash_mask; + struct hlist_head *delegation_hash_table; struct list_head ss_copies; struct list_head ss_src_copies; |
