aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2016-12-19 10:34:14 -0500
committerTrond Myklebust <trond.myklebust@primarydata.com>2016-12-19 17:30:01 -0500
commitf07d4a31ccd7dbe3ca49bedc8298245d6877a43e (patch)
tree84875f6cb4fb85ff11a51f9e92af9504f1ac6819
parentd8d849835eb2082ea17655538a83fa467633927f (diff)
NFS: Retry the CLOSE if the embedded GETATTR is rejected with EACCES
If our CLOSE RPC call is rejected with an EACCES call, then we should remove the GETATTR call from the compound RPC and retry. This could potentially happen when there is a conflict between an ACL denying attribute reads and our use of SP4_MACH_CRED. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
-rw-r--r--fs/nfs/nfs4proc.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index c3263114c6b8..4b66b0c469cd 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -3122,6 +3122,16 @@ static void nfs4_close_done(struct rpc_task *task, void *data)
3122 res_stateid = &calldata->res.stateid; 3122 res_stateid = &calldata->res.stateid;
3123 renew_lease(server, calldata->timestamp); 3123 renew_lease(server, calldata->timestamp);
3124 break; 3124 break;
3125 case -NFS4ERR_ACCESS:
3126 if (calldata->arg.bitmask != NULL) {
3127 calldata->arg.bitmask = NULL;
3128 calldata->res.fattr = NULL;
3129 task->tk_status = 0;
3130 rpc_restart_call_prepare(task);
3131 goto out_release;
3132
3133 }
3134 break;
3125 case -NFS4ERR_ADMIN_REVOKED: 3135 case -NFS4ERR_ADMIN_REVOKED:
3126 case -NFS4ERR_STALE_STATEID: 3136 case -NFS4ERR_STALE_STATEID:
3127 case -NFS4ERR_EXPIRED: 3137 case -NFS4ERR_EXPIRED: