From: J. Bruce Fields Date: Mon, 10 Oct 2011 21:34:31 +0000 (-0400) Subject: nfsd4: ignore WANT bits in open downgrade X-Git-Tag: v2.6.34.13~84 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=472f63d1e3530286e1b1773cd50d11add1faa54f;p=people%2Fms%2Flinux.git nfsd4: ignore WANT bits in open downgrade commit c30e92df30d7d5fe65262fbce5d1b7de675fe34e upstream. We don't use WANT bits yet--and sending them can probably trigger a BUG() further down. Signed-off-by: J. Bruce Fields Signed-off-by: Paul Gortmaker --- diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 6a8fedaa4f55..aa763391e33c 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c @@ -3065,6 +3065,8 @@ nfsd4_open_downgrade(struct svc_rqst *rqstp, if (!access_valid(od->od_share_access, cstate->minorversion) || !deny_valid(od->od_share_deny)) return nfserr_inval; + /* We don't yet support WANT bits: */ + od->od_share_access &= NFS4_SHARE_ACCESS_MASK; nfs4_lock_state(); if ((status = nfs4_preprocess_seqid_op(cstate,