On Nov. 10, 2008, 22:47 +0200, Benny Halevy <bhalevy@xxxxxxxxxxx> wrote: > From: Andy Adamson <andros@xxxxxxxxxx> > > Separate the access bits from the want bits and enable __set_bit to > work correctly with st_access_bmap. > > Signed-off-by: Andy Adamson<andros@xxxxxxxxxx> > Signed-off-by: Benny Halevy <bhalevy@xxxxxxxxxxx> > --- > fs/nfsd/nfs4state.c | 3 ++- > 1 files changed, 2 insertions(+), 1 deletions(-) > > diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c > index b772469..db79c0c 100644 > --- a/fs/nfsd/nfs4state.c > +++ b/fs/nfsd/nfs4state.c > @@ -1186,7 +1186,8 @@ init_stateid(struct nfs4_stateid *stp, struct nfs4_file *fp, struct nfsd4_open * > stp->st_stateid.si_generation = 0; > stp->st_access_bmap = 0; > stp->st_deny_bmap = 0; > - __set_bit(open->op_share_access, &stp->st_access_bmap); > + __set_bit(open->op_share_access & ~NFS4_SHARE_WANT_MASK, review 11-13: should be (open->op_share_access & NFS4_SHARE_DENY_MASK) also, define NFS4_SHARE_ACCESS_MASK (== NFS4_SHARE_DENY_MASK) and use it in access_valid() as well. > + &stp->st_access_bmap); > __set_bit(open->op_share_deny, &stp->st_deny_bmap); > stp->st_openstp = NULL; > } -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html