diff options
| author | Andreas Gruenbacher <agruenba@redhat.com> | 2026-01-12 16:08:02 +0300 |
|---|---|---|
| committer | Andreas Gruenbacher <agruenba@redhat.com> | 2026-01-26 16:28:17 +0300 |
| commit | 08ca56ffcd43b37061bc675545796b3f01f9937d (patch) | |
| tree | eb2c3f3fb27a51bfe78f5c2c3178b71536f60aec | |
| parent | 4a94f052e0982794aa65312fe8b69999e4494a20 (diff) | |
| download | linux-08ca56ffcd43b37061bc675545796b3f01f9937d.tar.xz | |
gfs2: gfs2_chain_bio start sector fix
Pass the start sector into gfs2_chain_bio(): the new bio isn't
necessarily contiguous with the previous one.
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
| -rw-r--r-- | fs/gfs2/lops.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/gfs2/lops.c b/fs/gfs2/lops.c index c3317432a25b..879635ebddae 100644 --- a/fs/gfs2/lops.c +++ b/fs/gfs2/lops.c @@ -479,13 +479,13 @@ static void gfs2_jhead_process_page(struct gfs2_jdesc *jd, unsigned long index, } static struct bio *gfs2_chain_bio(struct bio *prev, unsigned int nr_iovecs, - blk_opf_t opf) + sector_t sector, blk_opf_t opf) { struct bio *new; new = bio_alloc(prev->bi_bdev, nr_iovecs, opf, GFP_NOIO); bio_clone_blkg_association(new, prev); - new->bi_iter.bi_sector = bio_end_sector(prev); + new->bi_iter.bi_sector = sector; bio_chain(new, prev); submit_bio(prev); return new; @@ -548,7 +548,7 @@ int gfs2_find_jhead(struct gfs2_jdesc *jd, struct gfs2_log_header_host *head) unsigned int blocks = (PAGE_SIZE - off) >> bsize_shift; - bio = gfs2_chain_bio(bio, blocks, + bio = gfs2_chain_bio(bio, blocks, sector, REQ_OP_READ); goto add_block_to_new_bio; } |
