[PATCH] Storing the ACL control flags with vfs gpfs.

Alexander Werth werth at linux.vnet.ibm.com
Mon Mar 17 08:02:10 MDT 2014


On Fri, 2014-03-14 at 11:40 +0100, Alexander Werth wrote:
> On Thu, 2014-03-13 at 12:28 -0700, Christof Schmitt wrote:
> > On Wed, Mar 12, 2014 at 02:24:48PM +0100, Alexander Werth wrote:
> > > Hi,
> > > 
> > > The current nfs4 module drops the ACL control flags from the security
> > > descriptor. The NFS4.1 spec also specifies ACL flags so I added a way to
> > > pass these control flags on to the nfs4 filesystems.
> > > 
> > > The first patch adds hocks to the nfs4_acls common code to store and
> > > retrieve the control flags in the acl struct.
> > > 
> > > 
> > > And I wrote a patch that allows to store these ACL control flags in the
> > > vfs gpfs module which is supported with gpfs 3.5 and up.
> > > The vfs gpfs patch allows to build without the control flags on older
> > > gpfs versions and also has the ability to run the same vfs module on
> > > older and newer gpfs versions.
> > > 
> > > Both patches apply to the current master.
> > > Please comment.
> > 
> > In the past, we have avoided ifdefs in the vfs_gpfs module. I am
> > wondering if it would be possible to access the flags field through a
> > pointer and avoid the gpfs 3.5 specific parts in the code. Once we no
> > longer care about older gpfs versions, we can cleanup the code and use
> > the proper struct members.
> > 
> > None of the solutions (ifdef or pointer) is perfect, but i would be
> > leaning towards always getting the same module from a compile, and avoid
> > the ifdefs.
> 
> I've redone the patch using literals and comments and some pointer
> arithmetic to avoid the dependency on the gpfs 3.5 header file.
> The literals can be replaced with the defines from the 3.5 header file
> once gpfs 3.4 is out of service.
> 
> > A smaller comment would be avoid the goto again loop, and simply
> > issuing the call again. I think the intent is to just retry once with
> > different parameters, so we don't need the loop.
> 
> Done. 
> 
> > And a very minor thing is to use the C99 style integers (e.g. uint_16)
> > instead of e.g. uin16:
> > 
> > README.Coding
> > 
> > ..., new code should adhere to the following conventions:
> > ...
> >   * Exact width integers are of type [u]int[8|16|32|64]_t
> 
> Ok, thanks.
> 
> Here's the second iteration for the patch. 
> Btw. the control flags contain the dacl protected flag which is
> important to support the "Include inheritable permissions from this
> object's parent" checkbox.
> 
> Cheers,
> Alexander

I forgot the signed-off-by and added some text to the commit message.

Please comment/push.

Cheers,
Alexander


-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-vfs-Support-NFS-control-flags-in-nfs4_acls.c.patch
Type: text/x-patch
Size: 3095 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20140317/cc45b201/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-vfs-Store-ACL-control-flags-in-gpfs-vfs-module.patch
Type: text/x-patch
Size: 8454 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20140317/cc45b201/attachment-0001.bin>


More information about the samba-technical mailing list