summaryrefslogtreecommitdiffstats
path: root/fs/nfsd/nfs4proc.c
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@redhat.com>2011-10-10 23:44:19 +0200
committerJ. Bruce Fields <bfields@redhat.com>2011-10-11 18:15:15 +0200
commitb6d2f1ca3c1162f51098969e9c52fd099720416a (patch)
treebf8fa7abd3b601902ac034248a07b274b33e45fd /fs/nfsd/nfs4proc.c
parentnfsd4: move name-length checks to xdr (diff)
downloadlinux-b6d2f1ca3c1162f51098969e9c52fd099720416a.tar.xz
linux-b6d2f1ca3c1162f51098969e9c52fd099720416a.zip
nfsd4: more robust ignoring of WANT bits in OPEN
Mask out the WANT bits right at the start instead of on each use. Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd/nfs4proc.c')
-rw-r--r--fs/nfsd/nfs4proc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/nfsd/nfs4proc.c b/fs/nfsd/nfs4proc.c
index 4e41f65c7021..5b192a2512b6 100644
--- a/fs/nfsd/nfs4proc.c
+++ b/fs/nfsd/nfs4proc.c
@@ -315,6 +315,9 @@ nfsd4_open(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
if (open->op_create && open->op_claim_type != NFS4_OPEN_CLAIM_NULL)
return nfserr_inval;
+ /* We don't yet support WANT bits: */
+ open->op_share_access &= NFS4_SHARE_ACCESS_MASK;
+
/*
* RFC5661 18.51.3
* Before RECLAIM_COMPLETE done, server should deny new lock