projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
15860ab
)
NFS: Use delegations to optimise ACCESS calls
author
Trond Myklebust
<Trond.Myklebust@netapp.com>
Tue, 23 Dec 2008 20:21:55 +0000
(15:21 -0500)
committer
Trond Myklebust
<Trond.Myklebust@netapp.com>
Tue, 23 Dec 2008 20:21:55 +0000
(15:21 -0500)
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
fs/nfs/dir.c
patch
|
blob
|
history
diff --git
a/fs/nfs/dir.c
b/fs/nfs/dir.c
index ff167aa624345f6ff27753f534b366890728603a..ed7024c348850adb826aa7d9c0318e91cb7a0fb1 100644
(file)
--- a/
fs/nfs/dir.c
+++ b/
fs/nfs/dir.c
@@
-1797,7
+1797,8
@@
static int nfs_access_get_cached(struct inode *inode, struct rpc_cred *cred, str
cache = nfs_access_search_rbtree(inode, cred);
if (cache == NULL)
goto out;
- if (!time_in_range(jiffies, cache->jiffies, cache->jiffies + nfsi->attrtimeo))
+ if (!nfs_have_delegation(inode, FMODE_READ) &&
+ !time_in_range(jiffies, cache->jiffies, cache->jiffies + nfsi->attrtimeo))
goto out_stale;
res->jiffies = cache->jiffies;
res->cred = cache->cred;