Skip to content

Commit 2fa88b1

Browse files
author
Kent Overstreet
committed
bcachefs: kill btree_trans_too_many_iters() in bch2_bucket_alloc_freelist()
When we're called via trans commit -> btree split -> allocator We may have already arbitrarily many btree_paths, for the transaction commit we're trying to do; when this happens, the btree_trans_too_many_iters() call causes us to livelock. Since the allocator calls btree_iter_dontneed to release paths as it iterates, this shouldn't cause any problems. Signed-off-by: Kent Overstreet <[email protected]>
1 parent 73f8859 commit 2fa88b1

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

fs/bcachefs/alloc_foreground.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -496,12 +496,6 @@ static struct open_bucket *bch2_bucket_alloc_freelist(struct btree_trans *trans,
496496
for (alloc_cursor = max(alloc_cursor, bkey_start_offset(k.k));
497497
alloc_cursor < k.k->p.offset;
498498
alloc_cursor++) {
499-
ret = btree_trans_too_many_iters(trans);
500-
if (ret) {
501-
ob = ERR_PTR(ret);
502-
break;
503-
}
504-
505499
s->buckets_seen++;
506500

507501
u64 bucket = alloc_cursor & ~(~0ULL << 56);

0 commit comments

Comments
 (0)