Skip to content

Commit 0b6ec0c

Browse files
author
Kent Overstreet
committed
bcachefs: Fix assertion pop in topology repair
Fixes: baefd3f ("bcachefs: btree_cache.freeable list fixes") Signed-off-by: Kent Overstreet <[email protected]>
1 parent bcf77a0 commit 0b6ec0c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

fs/bcachefs/btree_gc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ static int set_node_max(struct bch_fs *c, struct btree *b, struct bpos new_max)
182182
bch2_btree_node_drop_keys_outside_node(b);
183183

184184
mutex_lock(&c->btree_cache.lock);
185-
bch2_btree_node_hash_remove(&c->btree_cache, b);
185+
__bch2_btree_node_hash_remove(&c->btree_cache, b);
186186

187187
bkey_copy(&b->key, &new->k_i);
188188
ret = __bch2_btree_node_hash_insert(&c->btree_cache, b);

fs/bcachefs/btree_update_interior.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2398,7 +2398,8 @@ static int __bch2_btree_node_update_key(struct btree_trans *trans,
23982398
if (new_hash) {
23992399
mutex_lock(&c->btree_cache.lock);
24002400
bch2_btree_node_hash_remove(&c->btree_cache, new_hash);
2401-
bch2_btree_node_hash_remove(&c->btree_cache, b);
2401+
2402+
__bch2_btree_node_hash_remove(&c->btree_cache, b);
24022403

24032404
bkey_copy(&b->key, new_key);
24042405
ret = __bch2_btree_node_hash_insert(&c->btree_cache, b);

0 commit comments

Comments
 (0)