linux/fs/orangefs
Jeff Layton 541d4c798a fs: drop the timespec64 arg from generic_update_time
In future patches we're going to change how the ctime is updated
to keep track of when it has been queried. The way that the update_time
operation works (and a lot of its callers) make this difficult, since
they grab a timestamp early and then pass it down to eventually be
copied into the inode.

All of the existing update_time callers pass in the result of
current_time() in some fashion. Drop the "time" parameter from
generic_update_time, and rework it to fetch its own timestamp.

This change means that an update_time could fetch a different timestamp
than was seen in inode_needs_update_time. update_time is only ever
called with one of two flag combinations: Either S_ATIME is set, or
S_MTIME|S_CTIME|S_VERSION are set.

With this change we now treat the flags argument as an indicator that
some value needed to be updated when last checked, rather than an
indication to update specific timestamps.

Rework the logic for updating the timestamps and put it in a new
inode_update_timestamps helper that other update_time routines can use.
S_ATIME is as treated as we always have, but if any of the other three
are set, then we attempt to update all three.

Also, some callers of generic_update_time need to know what timestamps
were actually updated. Change it to return an S_* flag mask to indicate
that and rework the callers to expect it.

Signed-off-by: Jeff Layton <jlayton@kernel.org>
Reviewed-by: Jan Kara <jack@suse.cz>
Message-Id: <20230807-mgctime-v7-3-d1dec143a704@kernel.org>
Signed-off-by: Christian Brauner <brauner@kernel.org>
2023-08-09 08:56:37 +02:00
..
acl.c fs: port acl to mnt_idmap 2023-01-19 09:24:28 +01:00
dcache.c fs: orangefs: fix error return code of orangefs_revalidate_lookup() 2021-10-11 14:25:34 -04:00
devorangefs-req.c Merge branch 'work.compat' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2018-06-16 16:21:50 +09:00
dir.c Orangefs: change iterate to iterate_shared 2022-10-03 13:05:38 -04:00
downcall.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
file.c orangefs: Provide a splice-read wrapper 2023-05-24 08:42:16 -06:00
inode.c fs: drop the timespec64 arg from generic_update_time 2023-08-09 08:56:37 +02:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
namei.c orangefs: convert to ctime accessor functions 2023-07-24 10:30:03 +02:00
orangefs-bufmap.c orangefs: Fix the size of a memory allocation in orangefs_bufmap_alloc() 2021-12-31 14:37:43 -05:00
orangefs-bufmap.h orangefs: copy Orangefs-sized blocks into the pagecache if possible. 2019-05-03 14:32:39 -04:00
orangefs-cache.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
orangefs-debug.h orangefs: remove unused code 2018-04-03 21:55:28 -04:00
orangefs-debugfs.c orangefs: Fix kmemleak in orangefs_{kernel,client}_debug_init() 2022-12-07 15:18:30 -05:00
orangefs-debugfs.h orangefs: fix build warning from debugfs cleanup patch 2019-07-04 10:30:33 +02:00
orangefs-dev-proto.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
orangefs-kernel.h fs: port ->permission() to pass mnt_idmap 2023-01-19 09:24:28 +01:00
orangefs-mod.c orangefs: Fix sysfs not cleanup when dev init failed 2022-12-07 15:18:29 -05:00
orangefs-sysfs.c orangefs: Fix kmemleak in orangefs_sysfs_init() 2022-12-07 15:18:30 -05:00
orangefs-sysfs.h Orangefs: change pvfs2 filenames to orangefs 2015-12-04 12:56:14 -05:00
orangefs-utils.c orangefs: convert to ctime accessor functions 2023-07-24 10:30:03 +02:00
protocol.h orangefs: specify user pointers when using dev_map_desc and bufmap 2018-06-01 14:51:36 -04:00
super.c fs: allocate inode by using alloc_inode_sb() 2022-03-22 15:57:03 -07:00
symlink.c orangefs: stop setting atime on inode dirty 2017-11-13 15:10:11 -05:00
upcall.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
waitqueue.c orangefs: service ops done for writeback are not killable 2019-05-03 14:32:38 -04:00
xattr.c fs: drop unused posix acl handlers 2023-03-06 09:57:12 +01:00