gfs2: Always update inode ctime in set_acl
Andreas Gruenbacher
maintainerPATCH 1/1 gfs2: Always update inode ctime in set_acl
Three-entry POSIX ACLs can be stored in the file mode permission bits, with no need to store them in extended attributes. When a process sets such a minimal ACL, the kernel updates the file mode like chmod does, and removes any existing extended attributes for that ACL. Make sure the ctime is always updated in that case.
Fixes xfstest generic/307.
Signed-off-by Andreas Gruenbacher <[email protected]>
--- fs/gfs2/acl.c | 1 + 1 file changed, 1 insertion(+)
fs/gfs2/acl.c +1 -0
@@ -141,6 +141,7 @@ int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) ret =__gfs2_set_acl (inode, acl, type);if (!ret && mode != inode->i_mode) { + inode->i_ctime =current_time (inode); inode->i_mode = mode;mark_inode_dirty (inode); }
Signature · 1 line
2.13.3
PATCH 1/1 gfs2: Always update inode ctime in set_acl
----- Original Message -----
| Three-entry POSIX ACLs can be stored in the file mode permission bits, | with no need to store them in extended attributes. When a process sets | such a minimal ACL, the kernel updates the file mode like chmod does, | and removes any existing extended attributes for that ACL. Make sure | the ctime is always updated in that case. | | Fixes xfstest generic/307. | | Signed-off-by: Andreas Gruenbacher <[email protected]> | --- | fs/gfs2/acl.c | 1 + | 1 file changed, 1 insertion(+)
Hi,
Thanks. This is now pushed to the for-next branch of the linux-gfs2 tree:
https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git/commit/?h=for-next&id=7b532754bac64bc7fe67317205e248558cdd3d3b
Regards,
Bob Peterson
Red Hat File Systems