diff options
author | Matthew Wilcox (Oracle) <willy@infradead.org> | 2025-07-08 18:03:43 +0100 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2025-07-22 15:57:30 +0000 |
commit | a9249a2671bca27860b152fc5db32d448f359af3 (patch) | |
tree | 95e2e4ebd4fa1d3215d5a9e4c2ae6335a2b4eabb | |
parent | d6966e7ed280caf1f4397c4a0cad14618e5ff5f7 (diff) |
f2fs: Use a folio iterator in f2fs_handle_step_decompress()
Change from bio_for_each_segment_all() to bio_for_each_folio_all()
to iterate over each folio instead of each page.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
-rw-r--r-- | fs/f2fs/data.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c index 7993b2f8d711..47c10cec1540 100644 --- a/fs/f2fs/data.c +++ b/fs/f2fs/data.c @@ -233,16 +233,15 @@ static void f2fs_verify_and_finish_bio(struct bio *bio, bool in_task) static void f2fs_handle_step_decompress(struct bio_post_read_ctx *ctx, bool in_task) { - struct bio_vec *bv; - struct bvec_iter_all iter_all; + struct folio_iter fi; bool all_compressed = true; block_t blkaddr = ctx->fs_blkaddr; - bio_for_each_segment_all(bv, ctx->bio, iter_all) { - struct page *page = bv->bv_page; + bio_for_each_folio_all(fi, ctx->bio) { + struct folio *folio = fi.folio; - if (f2fs_is_compressed_page(page)) - f2fs_end_read_compressed_page(page, false, blkaddr, + if (f2fs_is_compressed_page(&folio->page)) + f2fs_end_read_compressed_page(&folio->page, false, blkaddr, in_task); else all_compressed = false; |