Re: [PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-08 Thread Andreas Dilger
On Nov 7, 2015, at 10:44 AM, Andreas Gruenbacher wrote: > > On Fri, Nov 6, 2015 at 9:58 PM, Andreas Dilger wrote: >> I thought you proposed adding an enum for these parameters, and possibly >> making them a single parameter flag, to make the code in the caller more >> readable. > > No, the

Re: [PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-08 Thread Andreas Dilger
On Nov 7, 2015, at 10:44 AM, Andreas Gruenbacher wrote: > > On Fri, Nov 6, 2015 at 9:58 PM, Andreas Dilger wrote: >> I thought you proposed adding an enum for these parameters, and possibly >> making them a single parameter flag, to make the code in the

Re: [PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-07 Thread Andreas Gruenbacher
On Fri, Nov 6, 2015 at 9:58 PM, Andreas Dilger wrote: > I thought you proposed adding an enum for these parameters, and possibly > making them a single parameter flag, to make the code in the caller more > readable. No, the result would just be different but not any better; vfs_rename would

Re: [PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-07 Thread Andreas Gruenbacher
On Fri, Nov 6, 2015 at 9:58 PM, Andreas Dilger wrote: > I thought you proposed adding an enum for these parameters, and possibly > making them a single parameter flag, to make the code in the caller more > readable. No, the result would just be different but not any better;

Re: [PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-06 Thread Andreas Dilger
On Nov 5, 2015, at 4:39 AM, Andreas Gruenbacher wrote: > > Richacls distinguish between creating non-directories and directories. To > support that, add an isdir parameter to may_create(). When checking > inode_permission() for create permission, pass in an additional > MAY_CREATE_FILE or

Re: [PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-06 Thread Andreas Dilger
On Nov 5, 2015, at 4:39 AM, Andreas Gruenbacher wrote: > > Richacls distinguish between creating non-directories and directories. To > support that, add an isdir parameter to may_create(). When checking > inode_permission() for create permission, pass in an additional >

[PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-05 Thread Andreas Gruenbacher
Richacls distinguish between creating non-directories and directories. To support that, add an isdir parameter to may_create(). When checking inode_permission() for create permission, pass in an additional MAY_CREATE_FILE or MAY_CREATE_DIR mask flag. To allow checking for delete *and* create

[PATCH v14 02/22] vfs: Add MAY_CREATE_FILE and MAY_CREATE_DIR permission flags

2015-11-05 Thread Andreas Gruenbacher
Richacls distinguish between creating non-directories and directories. To support that, add an isdir parameter to may_create(). When checking inode_permission() for create permission, pass in an additional MAY_CREATE_FILE or MAY_CREATE_DIR mask flag. To allow checking for delete *and* create