* [PATCH] f2fs: remove unneeded in-memory i_crtime copy
@ 2023-04-10 2:20 Chao Yu
2023-04-11 17:00 ` [f2fs-dev] " patchwork-bot+f2fs
0 siblings, 1 reply; 2+ messages in thread
From: Chao Yu @ 2023-04-10 2:20 UTC (permalink / raw)
To: jaegeuk; +Cc: linux-f2fs-devel, linux-kernel, Chao Yu
i_crtime will never change after inode creation, so we don't need
to copy it into f2fs_inode_info.i_disk_time[3], and monitor its
change to decide whether updating inode page, remove related stuff.
Signed-off-by: Chao Yu <chao@kernel.org>
---
fs/f2fs/f2fs.h | 5 +----
fs/f2fs/inode.c | 1 -
2 files changed, 1 insertion(+), 5 deletions(-)
diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h
index 7d9c5a65f974..e78cbc8a6248 100644
--- a/fs/f2fs/f2fs.h
+++ b/fs/f2fs/f2fs.h
@@ -844,7 +844,7 @@ struct f2fs_inode_info {
kprojid_t i_projid; /* id for project quota */
int i_inline_xattr_size; /* inline xattr size */
struct timespec64 i_crtime; /* inode creation time */
- struct timespec64 i_disk_time[4];/* inode disk times */
+ struct timespec64 i_disk_time[3];/* inode disk times */
/* for file compress */
atomic_t i_compr_blocks; /* # of compressed blocks */
@@ -3290,9 +3290,6 @@ static inline bool f2fs_is_time_consistent(struct inode *inode)
return false;
if (!timespec64_equal(F2FS_I(inode)->i_disk_time + 2, &inode->i_mtime))
return false;
- if (!timespec64_equal(F2FS_I(inode)->i_disk_time + 3,
- &F2FS_I(inode)->i_crtime))
- return false;
return true;
}
diff --git a/fs/f2fs/inode.c b/fs/f2fs/inode.c
index bb5b365a195d..cf4327ad106c 100644
--- a/fs/f2fs/inode.c
+++ b/fs/f2fs/inode.c
@@ -326,7 +326,6 @@ static void init_idisk_time(struct inode *inode)
fi->i_disk_time[0] = inode->i_atime;
fi->i_disk_time[1] = inode->i_ctime;
fi->i_disk_time[2] = inode->i_mtime;
- fi->i_disk_time[3] = fi->i_crtime;
}
static int do_read_inode(struct inode *inode)
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [f2fs-dev] [PATCH] f2fs: remove unneeded in-memory i_crtime copy
2023-04-10 2:20 [PATCH] f2fs: remove unneeded in-memory i_crtime copy Chao Yu
@ 2023-04-11 17:00 ` patchwork-bot+f2fs
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+f2fs @ 2023-04-11 17:00 UTC (permalink / raw)
To: Chao Yu; +Cc: jaegeuk, linux-kernel, linux-f2fs-devel
Hello:
This patch was applied to jaegeuk/f2fs.git (dev)
by Jaegeuk Kim <jaegeuk@kernel.org>:
On Mon, 10 Apr 2023 10:20:12 +0800 you wrote:
> i_crtime will never change after inode creation, so we don't need
> to copy it into f2fs_inode_info.i_disk_time[3], and monitor its
> change to decide whether updating inode page, remove related stuff.
>
> Signed-off-by: Chao Yu <chao@kernel.org>
> ---
> fs/f2fs/f2fs.h | 5 +----
> fs/f2fs/inode.c | 1 -
> 2 files changed, 1 insertion(+), 5 deletions(-)
Here is the summary with links:
- [f2fs-dev] f2fs: remove unneeded in-memory i_crtime copy
https://git.kernel.org/jaegeuk/f2fs/c/c277991d7cf0
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-04-11 17:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-10 2:20 [PATCH] f2fs: remove unneeded in-memory i_crtime copy Chao Yu
2023-04-11 17:00 ` [f2fs-dev] " patchwork-bot+f2fs
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox