diff options
author | Trond Myklebust <trond.myklebust@hammerspace.com> | 2019-10-22 14:52:47 +0200 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@hammerspace.com> | 2019-11-04 03:28:46 +0100 |
commit | 1deed572351806322c3d9af005c2cf931ff23174 (patch) | |
tree | f3366bf6a2cf98b03264b13e06a077dd4fbddfc9 /fs | |
parent | NFSv4: Ignore requests to return the delegation if it was revoked (diff) | |
download | linux-1deed572351806322c3d9af005c2cf931ff23174.tar.xz linux-1deed572351806322c3d9af005c2cf931ff23174.zip |
NFSv4: Don't reclaim delegations that have been returned or revoked
If the delegation has already been revoked, we want to avoid reclaiming
it on reboot.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/nfs/delegation.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfs/delegation.c b/fs/nfs/delegation.c index ebd83e4db300..78df1cde286e 100644 --- a/fs/nfs/delegation.c +++ b/fs/nfs/delegation.c @@ -199,7 +199,7 @@ void nfs_inode_reclaim_delegation(struct inode *inode, const struct cred *cred, delegation = rcu_dereference(NFS_I(inode)->delegation); if (delegation != NULL) { spin_lock(&delegation->lock); - if (delegation->inode != NULL) { + if (nfs4_is_valid_delegation(delegation, 0)) { nfs4_stateid_copy(&delegation->stateid, stateid); delegation->type = type; delegation->pagemod_limit = pagemod_limit; |