projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1ab5be4
)
NFSv4: Just don't cache negative dentries on case insensitive servers
author
Trond Myklebust
<trond.myklebust@hammerspace.com>
Fri, 17 Dec 2021 20:36:55 +0000
(15:36 -0500)
committer
Anna Schumaker
<Anna.Schumaker@Netapp.com>
Thu, 6 Jan 2022 19:00:20 +0000
(14:00 -0500)
If the directory contents change, we cannot rely on the negative dentry
being cacheable.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
fs/nfs/dir.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/nfs/dir.c
b/fs/nfs/dir.c
index 9883f72fdb6fa372fd3870b0af377074b2317182..7ebfe4e3cf85213537f2c204c0b6516443a9830b 100644
(file)
--- a/
fs/nfs/dir.c
+++ b/
fs/nfs/dir.c
@@
-1436,6
+1436,9
@@
int nfs_neg_need_reval(struct inode *dir, struct dentry *dentry,
return 0;
if (NFS_SERVER(dir)->flags & NFS_MOUNT_LOOKUP_CACHE_NONEG)
return 1;
+ /* Case insensitive server? Revalidate negative dentries */
+ if (nfs_server_capable(dir, NFS_CAP_CASE_INSENSITIVE))
+ return 1;
return !nfs_check_verifier(dir, dentry, flags & LOOKUP_RCU);
}