linux-stable/fs/overlayfs
Jeff Layton d03732a4b7 overlayfs: set ctime when setting mtime and atime
[ Upstream commit 03dbab3bba ]

Nathan reported that he was seeing the new warning in
setattr_copy_mgtime pop when starting podman containers. Overlayfs is
trying to set the atime and mtime via notify_change without also
setting the ctime.

POSIX states that when the atime and mtime are updated via utimes() that
we must also update the ctime to the current time. The situation with
overlayfs copy-up is analogies, so add ATTR_CTIME to the bitmask.
notify_change will fill in the value.

Reported-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Jeff Layton <jlayton@kernel.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Christian Brauner <brauner@kernel.org>
Acked-by: Amir Goldstein <amir73il@gmail.com>
Message-Id: <20230913-ctime-v1-1-c6bc509cbc27@kernel.org>
Signed-off-by: Christian Brauner <brauner@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-10-25 11:13:32 +02:00
..
Kconfig
Makefile
copy_up.c overlayfs: set ctime when setting mtime and atime 2023-10-25 11:13:32 +02:00
dir.c ovl: fix missing negative dentry check in ovl_rename() 2021-10-17 10:08:32 +02:00
inode.c ovl: perform vfs_getxattr() with mounter creds 2021-02-23 14:00:31 +01:00
namei.c ovl: fix error handling in ovl_verify_set_fh() 2018-11-21 09:24:04 +01:00
overlayfs.h ovl: fix format of setxattr debug 2018-10-10 08:54:27 +02:00
ovl_entry.h
readdir.c ovl: fix wrong use of impure dir cache in ovl_iterate() 2018-09-09 19:55:58 +02:00
super.c
util.c ovl: fix memory leak on unlink of indexed file 2018-10-10 08:54:27 +02:00