]> git.ipfire.org Git - thirdparty/linux.git/commit
gfs2: Initialize bio->bi_opf early
authorAndreas Gruenbacher <agruenba@redhat.com>
Thu, 11 Dec 2025 01:55:47 +0000 (01:55 +0000)
committerAndreas Gruenbacher <agruenba@redhat.com>
Mon, 26 Jan 2026 13:28:17 +0000 (14:28 +0100)
commit4a94f052e0982794aa65312fe8b69999e4494a20
treed16f74884e35f8d07305faa4d67ccd39ee82e8f9
parent59d81037d32ff1e415dcaa359c238c9ca730932d
gfs2: Initialize bio->bi_opf early

Pass the right blk_opf_t value to bio_alloc() so that ->bi_ops is
initialized correctly and doesn't have to be changed later.  Adjust the
call chain to pass that value through to where it is needed (and only
there).

Add a separate blk_opf_t argument to gfs2_chain_bio() instead of copying
the value from the previous bio.

Fixes: 8a157e0a0aa5 ("gfs2: Fix use of bio_chain")
Reported-by: syzbot+f6539d4ce3f775aee0cc@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=f6539d4ce3f775aee0cc
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/log.c
fs/gfs2/lops.c
fs/gfs2/lops.h