projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
46280d9
)
NFSv4: nfs_set_open_stateid must not trigger state recovery for closed state
author
Trond Myklebust
<
[email protected]
>
Tue, 7 Nov 2017 18:10:46 +0000
(13:10 -0500)
committer
Anna Schumaker
<
[email protected]
>
Fri, 17 Nov 2017 21:43:49 +0000
(16:43 -0500)
In nfs_set_open_stateid_locked, we must ignore stateids from closed state.
Reported-by: Andrew W Elble <
[email protected]
>
Signed-off-by: Trond Myklebust <
[email protected]
>
Signed-off-by: Anna Schumaker <
[email protected]
>
fs/nfs/nfs4proc.c
patch
|
blob
|
history
diff --git
a/fs/nfs/nfs4proc.c
b/fs/nfs/nfs4proc.c
index 1090016a238fd962d0ce86fb66b98ae447f27013..2c9c225796106ac4eeb8e32f25bf1974fed60e96 100644
(file)
--- a/
fs/nfs/nfs4proc.c
+++ b/
fs/nfs/nfs4proc.c
@@
-1541,7
+1541,8
@@
static void nfs_set_open_stateid_locked(struct nfs4_state *state,
write_seqlock(&state->seqlock);
}
- if (!nfs4_stateid_match_other(stateid, &state->open_stateid)) {
+ if (test_bit(NFS_OPEN_STATE, &state->flags) &&
+ !nfs4_stateid_match_other(stateid, &state->open_stateid)) {
nfs4_stateid_copy(freeme, &state->open_stateid);
nfs_test_and_clear_all_open_stateid(state);
}