ovl: update ctime when changing file attribution
PATCH 1/1 ovl: update ctime when changing file attribution
Currently we keep size, mode and times of overlay inode as the same as upper inode, so should update ctime when changing file attribution as well.
Signed-off-by Chengguang Xu <[email protected]>
--- fs/overlayfs/file.c | 2 ++ 1 file changed, 2 insertions(+)
fs/overlayfs/file.c +2 -0
@@ -546,6 +546,8 @@ static long ovl_ioctl_set_flags(struct file *file, unsigned int cmd, ret =ovl_real_ioctl (file, cmd, arg);ovl_copyflags (ovl_inode_real (inode), inode); +/* Update ctime */ +ovl_copyattr (ovl_inode_real (inode), inode); unlock:inode_unlock (inode);
Signature · 1 line
2.27.0
Miklos Szeredi
maintainerQuoted 4 lines · Chengguang Xu
Currently we keep size, mode and times of overlay inode as the same as upper inode, so should update ctime when changing file attribution as well.
Updated and pushed.
Thanks,
Miklos
Quoted 23 lines
Signed-off-by Chengguang Xu <[email protected]>--- fs/overlayfs/file.c | 2 ++ 1 file changed, 2 insertions(+)fs/overlayfs/file.c +2
-1@@ -546,6 +546,8 @@ static long ovl_ioctl_set_flags(struct file *file, unsigned int cmd, ret =ovl_real_ioctl (file, cmd, arg);ovl_copyflags (ovl_inode_real (inode), inode); +/* Update ctime */ +ovl_copyattr (ovl_inode_real (inode), inode); unlock:inode_unlock (inode); --2.27.0