From: Kent Overstreet Date: Tue, 13 Aug 2024 03:29:46 +0000 (-0400) Subject: bcachefs: Fix warning in __bch2_fsck_err() for trans not passed in X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=c99471024f24b3cbafc02bf5b112ecf34b0dbd40;p=users%2Fdwmw2%2Flinux.git bcachefs: Fix warning in __bch2_fsck_err() for trans not passed in Signed-off-by: Kent Overstreet --- diff --git a/fs/bcachefs/btree_io.c b/fs/bcachefs/btree_io.c index 2c424435ca4aa..70ebcca08ba2c 100644 --- a/fs/bcachefs/btree_io.c +++ b/fs/bcachefs/btree_io.c @@ -1767,6 +1767,8 @@ static int __bch2_btree_root_read(struct btree_trans *trans, enum btree_id id, set_btree_node_read_in_flight(b); + /* we can't pass the trans to read_done() for fsck errors, so it must be unlocked */ + bch2_trans_unlock(trans); bch2_btree_node_read(trans, b, true); if (btree_node_read_error(b)) {