Re: [PATCH 2/5] NFS: __nfs_revalidate_inode() - use the nfs4_label to update file security info

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 4 Nov 2013 21:00:46 +0000
"Myklebust, Trond" <Trond.Myklebust@xxxxxxxxxx> wrote:

> 
> On Nov 4, 2013, at 15:51, Trond Myklebust <Trond.Myklebust@xxxxxxxxxx> wrote:
> 
> > Currently, we just discard the nfs4_label information, instead of using it
> > to update the file LSM security info.
> > 
> > Signed-off-by: Trond Myklebust <Trond.Myklebust@xxxxxxxxxx>
> 
> I forgot to add a "Reported-by: Jeff Layton <jlayton@xxxxxxxxxx>”. Fixed now...
> 
> > ---
> > fs/nfs/inode.c | 1 +
> > 1 file changed, 1 insertion(+)
> > 
> > diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
> > index 471ba59c42f9..09d4df5f588a 100644
> > --- a/fs/nfs/inode.c
> > +++ b/fs/nfs/inode.c
> > @@ -920,6 +920,7 @@ __nfs_revalidate_inode(struct nfs_server *server, struct inode *inode)
> > 		goto err_out;
> > 	}
> > 
> > +	nfs_setsecurity(inode, fattr, label);
> > 	if (nfsi->cache_validity & NFS_INO_INVALID_ACL)
> > 		nfs_zap_acl_cache(inode);
> > 
> > -- 
> > 1.8.3.1
> > 
> 

No worries -- looks fine.

Out of curiousity, is there a reason to call nfs_setsecurity prior to
zapping the ACL cache? The patch I had proposed did it afterward, but I
didn't think it mattered much either way...

Thanks,
-- 
Jeff Layton <jlayton@xxxxxxxxxx>
--
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




[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux