]> git.baikalelectronics.ru Git - kernel.git/commit
f2fs: invalidate meta pages only for post_read required inode
authorChao Yu <chao@kernel.org>
Tue, 12 Jul 2022 15:26:43 +0000 (23:26 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Sun, 31 Jul 2022 03:17:06 +0000 (20:17 -0700)
commit4d35a60bb2e9383af71a4ae592b2a231192e6936
tree1382ddb49e198f3c6b0d98d3840b336421939b86
parent32d52fd5ad51c1fe4d13c82684c89b517b13d225
f2fs: invalidate meta pages only for post_read required inode

After commit b97569502e32 ("f2fs: invalidate META_MAPPING before
IPU/DIO write"), invalidate_mapping_pages() will be called to
avoid race condition in between IPU/DIO and readahead for GC.

However, readahead flow is only used for post_read required inode,
so this patch adds check condition to avoids unnecessary page cache
invalidating for non-post_read inode.

Signed-off-by: Chao Yu <chao.yu@oppo.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/data.c
fs/f2fs/f2fs.h
fs/f2fs/segment.c