* [PATCH] f2fs: pass correct iostat type for single node writes
@ 2026-05-20 12:07 Wenjie Qi
2026-05-21 8:29 ` Chao Yu
2026-05-22 4:30 ` [f2fs-dev] " patchwork-bot+f2fs
0 siblings, 2 replies; 3+ messages in thread
From: Wenjie Qi @ 2026-05-20 12:07 UTC (permalink / raw)
To: jaegeuk, chao
Cc: yangyongpeng, linux-f2fs-devel, linux-kernel, qiwenjie, qwjhust
f2fs_write_single_node_folio() takes an io_type argument, but still
passes FS_GC_NODE_IO to __write_node_folio() unconditionally.
This was harmless while the helper was only used by
f2fs_move_node_folio(), whose caller passes FS_GC_NODE_IO. However,
commit fe9b8b30b971 ("f2fs: fix inline data not being written to disk
in writeback path") made f2fs_inline_data_fiemap() call the helper with
FS_NODE_IO for FIEMAP_FLAG_SYNC.
Honor the caller supplied io_type so inline-data FIEMAP sync writeback is
accounted as normal node IO instead of GC node IO, while the GC path
continues to pass FS_GC_NODE_IO explicitly.
Fixes: fe9b8b30b971 ("f2fs: fix inline data not being written to disk in writeback path")
Signed-off-by: Wenjie Qi <qiwenjie@xiaomi.com>
---
fs/f2fs/node.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c
index 4e5bd9e4cfc..6a9e77c87d1 100644
--- a/fs/f2fs/node.c
+++ b/fs/f2fs/node.c
@@ -1875,7 +1875,7 @@ int f2fs_write_single_node_folio(struct folio *node_folio, int sync_mode,
}
if (!__write_node_folio(node_folio, false, false, NULL,
- &wbc, false, FS_GC_NODE_IO, NULL))
+ &wbc, false, io_type, NULL))
err = -EAGAIN;
goto release_folio;
out_folio:
--
2.43.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] f2fs: pass correct iostat type for single node writes
2026-05-20 12:07 [PATCH] f2fs: pass correct iostat type for single node writes Wenjie Qi
@ 2026-05-21 8:29 ` Chao Yu
2026-05-22 4:30 ` [f2fs-dev] " patchwork-bot+f2fs
1 sibling, 0 replies; 3+ messages in thread
From: Chao Yu @ 2026-05-21 8:29 UTC (permalink / raw)
To: Wenjie Qi, jaegeuk
Cc: chao, yangyongpeng, linux-f2fs-devel, linux-kernel, qiwenjie
On 5/20/26 20:07, Wenjie Qi wrote:
> f2fs_write_single_node_folio() takes an io_type argument, but still
> passes FS_GC_NODE_IO to __write_node_folio() unconditionally.
>
> This was harmless while the helper was only used by
> f2fs_move_node_folio(), whose caller passes FS_GC_NODE_IO. However,
> commit fe9b8b30b971 ("f2fs: fix inline data not being written to disk
> in writeback path") made f2fs_inline_data_fiemap() call the helper with
> FS_NODE_IO for FIEMAP_FLAG_SYNC.
>
> Honor the caller supplied io_type so inline-data FIEMAP sync writeback is
> accounted as normal node IO instead of GC node IO, while the GC path
> continues to pass FS_GC_NODE_IO explicitly.
>
Cc: stable@kernel.org
> Fixes: fe9b8b30b971 ("f2fs: fix inline data not being written to disk in writeback path")
> Signed-off-by: Wenjie Qi <qiwenjie@xiaomi.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Thanks,
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [f2fs-dev] [PATCH] f2fs: pass correct iostat type for single node writes
2026-05-20 12:07 [PATCH] f2fs: pass correct iostat type for single node writes Wenjie Qi
2026-05-21 8:29 ` Chao Yu
@ 2026-05-22 4:30 ` patchwork-bot+f2fs
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+f2fs @ 2026-05-22 4:30 UTC (permalink / raw)
To: Wenjie Qi
Cc: jaegeuk, chao, qiwenjie, yangyongpeng, linux-kernel, linux-f2fs-devel
Hello:
This patch was applied to jaegeuk/f2fs.git (dev)
by Jaegeuk Kim <jaegeuk@kernel.org>:
On Wed, 20 May 2026 20:07:05 +0800 you wrote:
> f2fs_write_single_node_folio() takes an io_type argument, but still
> passes FS_GC_NODE_IO to __write_node_folio() unconditionally.
>
> This was harmless while the helper was only used by
> f2fs_move_node_folio(), whose caller passes FS_GC_NODE_IO. However,
> commit fe9b8b30b971 ("f2fs: fix inline data not being written to disk
> in writeback path") made f2fs_inline_data_fiemap() call the helper with
> FS_NODE_IO for FIEMAP_FLAG_SYNC.
>
> [...]
Here is the summary with links:
- [f2fs-dev] f2fs: pass correct iostat type for single node writes
https://git.kernel.org/jaegeuk/f2fs/c/8fdfd2d4ec98
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] 3+ messages in thread
end of thread, other threads:[~2026-05-22 4:30 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-05-20 12:07 [PATCH] f2fs: pass correct iostat type for single node writes Wenjie Qi
2026-05-21 8:29 ` Chao Yu
2026-05-22 4:30 ` [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
Powered by JetHome