* [PATCH] f2fs: check curseg->inited before write_sum_page in change_curseg
@ 2024-10-21 4:48 Yongpeng Yang
2024-10-21 9:05 ` Chao Yu
2024-10-28 17:40 ` [f2fs-dev] " patchwork-bot+f2fs
0 siblings, 2 replies; 3+ messages in thread
From: Yongpeng Yang @ 2024-10-21 4:48 UTC (permalink / raw)
To: Jaegeuk Kim, Chao Yu; +Cc: linux-f2fs-devel, linux-kernel, Yongpeng Yang
In the __f2fs_init_atgc_curseg->get_atssr_segment calling,
curseg->segno is NULL_SEGNO, indicating that there is no summary
block that needs to be written.
Signed-off-by: Yongpeng Yang <yangyongpeng1@oppo.com>
---
fs/f2fs/segment.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c
index 1766254279d2..35f0b5065554 100644
--- a/fs/f2fs/segment.c
+++ b/fs/f2fs/segment.c
@@ -2926,7 +2926,8 @@ static int change_curseg(struct f2fs_sb_info *sbi, int type)
struct f2fs_summary_block *sum_node;
struct page *sum_page;
- write_sum_page(sbi, curseg->sum_blk, GET_SUM_BLOCK(sbi, curseg->segno));
+ if (curseg->inited)
+ write_sum_page(sbi, curseg->sum_blk, GET_SUM_BLOCK(sbi, curseg->segno));
__set_test_and_inuse(sbi, new_segno);
--
2.40.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] f2fs: check curseg->inited before write_sum_page in change_curseg
2024-10-21 4:48 [PATCH] f2fs: check curseg->inited before write_sum_page in change_curseg Yongpeng Yang
@ 2024-10-21 9:05 ` Chao Yu
2024-10-28 17:40 ` [f2fs-dev] " patchwork-bot+f2fs
1 sibling, 0 replies; 3+ messages in thread
From: Chao Yu @ 2024-10-21 9:05 UTC (permalink / raw)
To: Yongpeng Yang, Jaegeuk Kim; +Cc: Chao Yu, linux-f2fs-devel, linux-kernel
On 2024/10/21 12:48, Yongpeng Yang wrote:
> In the __f2fs_init_atgc_curseg->get_atssr_segment calling,
> curseg->segno is NULL_SEGNO, indicating that there is no summary
> block that needs to be written.
>
Fixes: 093749e296e2 ("f2fs: support age threshold based garbage collection")
> Signed-off-by: Yongpeng Yang <yangyongpeng1@oppo.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Thanks,
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [f2fs-dev] [PATCH] f2fs: check curseg->inited before write_sum_page in change_curseg
2024-10-21 4:48 [PATCH] f2fs: check curseg->inited before write_sum_page in change_curseg Yongpeng Yang
2024-10-21 9:05 ` Chao Yu
@ 2024-10-28 17:40 ` patchwork-bot+f2fs
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+f2fs @ 2024-10-28 17:40 UTC (permalink / raw)
To: Yongpeng Yang; +Cc: jaegeuk, chao, linux-kernel, linux-f2fs-devel
Hello:
This patch was applied to jaegeuk/f2fs.git (dev)
by Jaegeuk Kim <jaegeuk@kernel.org>:
On Mon, 21 Oct 2024 12:48:01 +0800 you wrote:
> In the __f2fs_init_atgc_curseg->get_atssr_segment calling,
> curseg->segno is NULL_SEGNO, indicating that there is no summary
> block that needs to be written.
>
> Signed-off-by: Yongpeng Yang <yangyongpeng1@oppo.com>
> ---
> fs/f2fs/segment.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
Here is the summary with links:
- [f2fs-dev] f2fs: check curseg->inited before write_sum_page in change_curseg
https://git.kernel.org/jaegeuk/f2fs/c/f2bbbe277c22
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:[~2024-10-28 17:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-10-21 4:48 [PATCH] f2fs: check curseg->inited before write_sum_page in change_curseg Yongpeng Yang
2024-10-21 9:05 ` Chao Yu
2024-10-28 17:40 ` [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
all inboxes | Powered by JetHome®