Commit a0acc24f authored by Kent Overstreet's avatar Kent Overstreet

bcachefs: Fix open coded set_btree_iter_dontneed()

Signed-off-by: default avatarKent Overstreet <kent.overstreet@linux.dev>
parent 267b801f
......@@ -377,7 +377,7 @@ static struct open_bucket *try_alloc_bucket(struct btree_trans *trans, struct bc
ob = __try_alloc_bucket(c, ca, b, watermark, a, s, cl);
if (!ob)
iter.path->preserve = false;
set_btree_iter_dontneed(&iter);
err:
if (iter.trans && iter.path)
set_btree_iter_dontneed(&iter);
......@@ -447,7 +447,7 @@ bch2_bucket_alloc_early(struct btree_trans *trans,
ob = __try_alloc_bucket(trans->c, ca, k.k->p.offset, watermark, a, s, cl);
next:
citer.path->preserve = false;
set_btree_iter_dontneed(&citer);
bch2_trans_iter_exit(trans, &citer);
if (ob)
break;
......@@ -502,7 +502,7 @@ static struct open_bucket *bch2_bucket_alloc_freelist(struct btree_trans *trans,
ob = try_alloc_bucket(trans, ca, watermark,
alloc_cursor, s, k, cl);
if (ob) {
iter.path->preserve = false;
set_btree_iter_dontneed(&iter);
break;
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment