[LU-11154] use proper flags for FS_IOC_{FSSET,FSGET}XATTR Created: 18/Jul/18 Updated: 23/Aug/18 Resolved: 23/Aug/18 |
|
| Status: | Resolved |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | Lustre 2.11.0 |
| Fix Version/s: | Lustre 2.12.0 |
| Type: | Bug | Priority: | Major |
| Reporter: | Wang Shilong (Inactive) | Assignee: | Wang Shilong (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | quota | ||
| Issue Links: |
|
||||||||
| Severity: | 3 | ||||||||
| Rank (Obsolete): | 9223372036854775807 | ||||||||
| Description |
|
Alexander Mitin commented on The wrong constant is used in the implementation of this feature. File: lustre/utils/lfs_project.c When process fsx.fsx_xflags bits the following functions use the wrong constant value to check the project inherit flag.
These functions are using FS_IOC_FSGETXATTR and FS_IOC_FSGETXATTR ioctl calls to get or set fsxattr structure. Currently, to process fsx_xflags field from the fsxattr structure these functions use the constant LL_PROJINHERIT_FL, which is defined as the following: #define LL_PROJINHERIT_FL 0x20000000 However, when processing fsx_xflags from the fsxattr structure , the different constant should be used: FS_XFLAG_PROJINHERIT, which is defined in linux/fs.h file as following: #define FS_XFLAG_PROJINHERIT 0x00000200 /* create with parents projid */ See the following https://github.com/torvalds/linux/blob/master/include/uapi/linux/fs.h#L155 https://github.com/torvalds/linux/blob/master/include/uapi/linux/fs.h#L178 |
| Comments |
| Comment by Gerrit Updater [ 18/Jul/18 ] |
|
Wang Shilong (wshilong@ddn.com) uploaded a new patch: https://review.whamcloud.com/32828 XATTR |
| Comment by Gerrit Updater [ 23/Aug/18 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/32828/ XATTR |
| Comment by Peter Jones [ 23/Aug/18 ] |
|
Landed for 2.12 |