diff options
| -rw-r--r-- | fs/nfs/delegation.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/nfs/delegation.c b/fs/nfs/delegation.c index 76d205d1c7bc..07b839560576 100644 --- a/fs/nfs/delegation.c +++ b/fs/nfs/delegation.c | |||
| @@ -93,7 +93,7 @@ int nfs4_check_delegation(struct inode *inode, fmode_t flags) | |||
| 93 | return nfs4_do_check_delegation(inode, flags, false); | 93 | return nfs4_do_check_delegation(inode, flags, false); |
| 94 | } | 94 | } |
| 95 | 95 | ||
| 96 | static int nfs_delegation_claim_locks(struct nfs_open_context *ctx, struct nfs4_state *state, const nfs4_stateid *stateid) | 96 | static int nfs_delegation_claim_locks(struct nfs4_state *state, const nfs4_stateid *stateid) |
| 97 | { | 97 | { |
| 98 | struct inode *inode = state->inode; | 98 | struct inode *inode = state->inode; |
| 99 | struct file_lock *fl; | 99 | struct file_lock *fl; |
| @@ -108,7 +108,7 @@ static int nfs_delegation_claim_locks(struct nfs_open_context *ctx, struct nfs4_ | |||
| 108 | spin_lock(&flctx->flc_lock); | 108 | spin_lock(&flctx->flc_lock); |
| 109 | restart: | 109 | restart: |
| 110 | list_for_each_entry(fl, list, fl_list) { | 110 | list_for_each_entry(fl, list, fl_list) { |
| 111 | if (nfs_file_open_context(fl->fl_file) != ctx) | 111 | if (nfs_file_open_context(fl->fl_file)->state != state) |
| 112 | continue; | 112 | continue; |
| 113 | spin_unlock(&flctx->flc_lock); | 113 | spin_unlock(&flctx->flc_lock); |
| 114 | status = nfs4_lock_delegation_recall(fl, state, stateid); | 114 | status = nfs4_lock_delegation_recall(fl, state, stateid); |
| @@ -156,7 +156,7 @@ again: | |||
| 156 | seq = raw_seqcount_begin(&sp->so_reclaim_seqcount); | 156 | seq = raw_seqcount_begin(&sp->so_reclaim_seqcount); |
| 157 | err = nfs4_open_delegation_recall(ctx, state, stateid, type); | 157 | err = nfs4_open_delegation_recall(ctx, state, stateid, type); |
| 158 | if (!err) | 158 | if (!err) |
| 159 | err = nfs_delegation_claim_locks(ctx, state, stateid); | 159 | err = nfs_delegation_claim_locks(state, stateid); |
| 160 | if (!err && read_seqcount_retry(&sp->so_reclaim_seqcount, seq)) | 160 | if (!err && read_seqcount_retry(&sp->so_reclaim_seqcount, seq)) |
| 161 | err = -EAGAIN; | 161 | err = -EAGAIN; |
| 162 | mutex_unlock(&sp->so_delegreturn_mutex); | 162 | mutex_unlock(&sp->so_delegreturn_mutex); |
