android_kernel_asus_sm8350/fs/overlayfs
Jeff Layton 91ae08dc30 overlayfs: set ctime when setting mtime and atime
[ Upstream commit 03dbab3bba5f009d053635c729d1244f2c8bad38 ]

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:53:23 +02:00
..
copy_up.c overlayfs: set ctime when setting mtime and atime 2023-10-25 11:53:23 +02:00
dir.c ovl: Use ovl mounter's fsuid and fsgid in ovl_link() 2023-01-18 11:41:43 +01:00
export.c ovl: drop WARN_ON() dentry is NULL in ovl_encode_fh() 2022-08-25 11:17:23 +02:00
file.c ovl: fix deadlock in splice write 2021-11-17 09:48:49 +01:00
inode.c ovl: perform vfs_getxattr() with mounter creds 2021-02-17 10:35:15 +01:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
namei.c new helper: lookup_positive_unlocked() 2023-09-23 10:59:40 +02:00
overlayfs.h ovl: fix warning in ovl_create_real() 2021-12-22 09:29:40 +01:00
ovl_entry.h ovl: check type and offset of struct vfsmount in ovl_entry 2023-08-30 16:27:09 +02:00
readdir.c ovl: fix wrong WARN_ON() in ovl_cache_update_ino() 2020-02-11 04:35:24 -08:00
super.c ovl: fix warning in ovl_create_real() 2021-12-22 09:29:40 +01:00
util.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00