summaryrefslogtreecommitdiff
path: root/fs/smb/client/fscache.h
diff options
context:
space:
mode:
authorJeff Layton <jlayton@kernel.org>2023-07-05 22:01:39 +0300
committerChristian Brauner <brauner@kernel.org>2023-07-24 11:30:05 +0300
commit9448765397b6e6522dff485f4b480b7ee020a536 (patch)
treeacb5fdc22a99d514c61607e6a23caba67828d4bf /fs/smb/client/fscache.h
parenta58451279c25fc7330156d5c2f01aa950ceef90e (diff)
downloadlinux-9448765397b6e6522dff485f4b480b7ee020a536.tar.xz
smb: convert to ctime accessor functions
In later patches, we're going to change how the inode's ctime field is used. Switch to using accessor functions instead of raw accesses of inode->i_ctime. Acked-by: Tom Talpey <tom@talpey.com> Reviewed-by: Sergey Senozhatsky <senozhatsky@chromium.org> Signed-off-by: Jeff Layton <jlayton@kernel.org> Acked-by: Steve French <stfrench@microsoft.com> Message-Id: <20230705190309.579783-72-jlayton@kernel.org> Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'fs/smb/client/fscache.h')
-rw-r--r--fs/smb/client/fscache.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/smb/client/fscache.h b/fs/smb/client/fscache.h
index 173999610997..84f3b09367d2 100644
--- a/fs/smb/client/fscache.h
+++ b/fs/smb/client/fscache.h
@@ -50,12 +50,13 @@ void cifs_fscache_fill_coherency(struct inode *inode,
struct cifs_fscache_inode_coherency_data *cd)
{
struct cifsInodeInfo *cifsi = CIFS_I(inode);
+ struct timespec64 ctime = inode_get_ctime(inode);
memset(cd, 0, sizeof(*cd));
cd->last_write_time_sec = cpu_to_le64(cifsi->netfs.inode.i_mtime.tv_sec);
cd->last_write_time_nsec = cpu_to_le32(cifsi->netfs.inode.i_mtime.tv_nsec);
- cd->last_change_time_sec = cpu_to_le64(cifsi->netfs.inode.i_ctime.tv_sec);
- cd->last_change_time_nsec = cpu_to_le32(cifsi->netfs.inode.i_ctime.tv_nsec);
+ cd->last_change_time_sec = cpu_to_le64(ctime.tv_sec);
+ cd->last_change_time_nsec = cpu_to_le32(ctime.tv_nsec);
}