Skip to content

Commit 1deed57

Browse files
author
Trond Myklebust
committed
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 <[email protected]>
1 parent af20b7b commit 1deed57

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/nfs/delegation.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ void nfs_inode_reclaim_delegation(struct inode *inode, const struct cred *cred,
199199
delegation = rcu_dereference(NFS_I(inode)->delegation);
200200
if (delegation != NULL) {
201201
spin_lock(&delegation->lock);
202-
if (delegation->inode != NULL) {
202+
if (nfs4_is_valid_delegation(delegation, 0)) {
203203
nfs4_stateid_copy(&delegation->stateid, stateid);
204204
delegation->type = type;
205205
delegation->pagemod_limit = pagemod_limit;

0 commit comments

Comments
 (0)