summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2016-09-22 13:39:19 -0400
committerAnna Schumaker <Anna.Schumaker@Netapp.com>2016-09-27 14:35:23 -0400
commit76e8a1bd143a84bcc16ee1c19a2cd2715696b572 (patch)
tree5f781590d7684ed099e91d54edad4064d8d2fdff /fs
parent304020fe48c6c7fff8b5a38f382b54404f0f79d3 (diff)
downloadlinux-76e8a1bd143a84bcc16ee1c19a2cd2715696b572.tar.gz
linux-76e8a1bd143a84bcc16ee1c19a2cd2715696b572.tar.bz2
linux-76e8a1bd143a84bcc16ee1c19a2cd2715696b572.zip
NFSv4: Fix retry issues with nfs41_test/free_stateid
_nfs41_free_stateid() needs to be cached by the session, but nfs41_test_stateid() may return NFS4ERR_RETRY_UNCACHED_REP (in which case we should just retry). Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Tested-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfs/nfs4proc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index fdd7faceaf22..79109c84f18d 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -8929,6 +8929,7 @@ static void nfs4_handle_delay_or_session_error(struct nfs_server *server,
exception->retry = 0;
switch(err) {
case -NFS4ERR_DELAY:
+ case -NFS4ERR_RETRY_UNCACHED_REP:
nfs4_handle_exception(server, err, exception);
break;
case -NFS4ERR_BADSESSION:
@@ -9034,7 +9035,7 @@ static struct rpc_task *_nfs41_free_stateid(struct nfs_server *server,
msg.rpc_argp = &data->args;
msg.rpc_resp = &data->res;
- nfs4_init_sequence(&data->args.seq_args, &data->res.seq_res, 0);
+ nfs4_init_sequence(&data->args.seq_args, &data->res.seq_res, 1);
if (privileged)
nfs4_set_sequence_privileged(&data->args.seq_args);