diff options
-rw-r--r-- | fs/bcachefs/btree_iter.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/bcachefs/btree_iter.c b/fs/bcachefs/btree_iter.c index 05dc48611c64..0f136cb51e4e 100644 --- a/fs/bcachefs/btree_iter.c +++ b/fs/bcachefs/btree_iter.c @@ -2990,6 +2990,8 @@ void bch2_trans_begin(struct btree_trans *trans) } trans_for_each_path(trans, path) { + path->should_be_locked = false; + /* * XXX: we probably shouldn't be doing this if the transaction * was restarted, but currently we still overflow transaction @@ -2998,7 +3000,7 @@ void bch2_trans_begin(struct btree_trans *trans) if (!path->ref && !path->preserve) __bch2_path_free(trans, path); else - path->preserve = path->should_be_locked = false; + path->preserve = false; } bch2_trans_cond_resched(trans); |