]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - releases/3.14.25/nfs-don-t-try-to-reclaim-delegation-open-state-if-recovery-failed.patch
4.14-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 3.14.25 / nfs-don-t-try-to-reclaim-delegation-open-state-if-recovery-failed.patch
1 From f8ebf7a8ca35dde321f0cd385fee6f1950609367 Mon Sep 17 00:00:00 2001
2 From: Trond Myklebust <trond.myklebust@primarydata.com>
3 Date: Fri, 17 Oct 2014 23:02:52 +0300
4 Subject: NFS: Don't try to reclaim delegation open state if recovery failed
5
6 From: Trond Myklebust <trond.myklebust@primarydata.com>
7
8 commit f8ebf7a8ca35dde321f0cd385fee6f1950609367 upstream.
9
10 If state recovery failed, then we should not attempt to reclaim delegated
11 state.
12
13 http://lkml.kernel.org/r/CAN-5tyHwG=Cn2Q9KsHWadewjpTTy_K26ee+UnSvHvG4192p-Xw@mail.gmail.com
14 Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
15 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
16
17 ---
18 fs/nfs/delegation.c | 2 ++
19 1 file changed, 2 insertions(+)
20
21 --- a/fs/nfs/delegation.c
22 +++ b/fs/nfs/delegation.c
23 @@ -109,6 +109,8 @@ again:
24 continue;
25 if (!test_bit(NFS_DELEGATED_STATE, &state->flags))
26 continue;
27 + if (!nfs4_valid_open_stateid(state))
28 + continue;
29 if (!nfs4_stateid_match(&state->stateid, stateid))
30 continue;
31 get_nfs_open_context(ctx);