f2fs: try to allocate sections from zoned area except file pinning
PATCH 1/1 f2fs: try to allocate sections from zoned area except file pinning
From: Daeho Jeong <[email protected]>
We don't need to allocate blocks sequentially out of the section boundary. Instead of that, try to allocate sections from zoned area as many as possible, since conventional area should be used for file pinning.
Signed-off-by Daeho Jeong <[email protected]>
--- fs/f2fs/segment.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/segment.c +1 -1
@@ -2711,7 +2711,7 @@ static int get_new_segment(struct f2fs_sb_info *sbi,if (sbi->blkzone_alloc_policy ==BLKZONE_ALLOC_PRIOR_CONV || pinning) segno =0 ;else - segno =max (first_zoned_segno (sbi), *newseg); + segno =first_zoned_segno (sbi); hint = GET_SEC_FROM_SEG(sbi, segno); }#endif
Signature · 1 line
2.47.0.163.g1226f6d8fa-goog
Quoted 8 lines · Daeho Jeong
From: Daeho Jeong <[email protected]>
We don't need to allocate blocks sequentially out of the section boundary. Instead of that, try to allocate sections from zoned area as many as possible, since conventional area should be used for file pinning.
Signed-off-by Daeho Jeong <[email protected]>
Reviewed-by Chao Yu <[email protected]>
Thanks,