summaryrefslogtreecommitdiff
path: root/libbcachefs/btree_iter.c
diff options
context:
space:
mode:
Diffstat (limited to 'libbcachefs/btree_iter.c')
-rw-r--r--libbcachefs/btree_iter.c25
1 files changed, 7 insertions, 18 deletions
diff --git a/libbcachefs/btree_iter.c b/libbcachefs/btree_iter.c
index 3977bb1f..dc2b2a08 100644
--- a/libbcachefs/btree_iter.c
+++ b/libbcachefs/btree_iter.c
@@ -1174,17 +1174,10 @@ int bch2_btree_path_traverse_one(struct btree_trans *trans,
path->uptodate = BTREE_ITER_UPTODATE;
out:
- if (bch2_err_matches(ret, BCH_ERR_transaction_restart) != !!trans->restarted) {
- struct printbuf buf = PRINTBUF;
-
- prt_printf(&buf, "ret %s (%i) trans->restarted %s (%i)\n",
- bch2_err_str(ret), ret,
- bch2_err_str(trans->restarted), trans->restarted);
-#ifdef CONFIG_BCACHEFS_DEBUG
- bch2_prt_backtrace(&buf, &trans->last_restarted);
-#endif
- panic("%s", buf.buf);
- }
+ if (bch2_err_matches(ret, BCH_ERR_transaction_restart) != !!trans->restarted)
+ panic("ret %s (%i) trans->restarted %s (%i)\n",
+ bch2_err_str(ret), ret,
+ bch2_err_str(trans->restarted), trans->restarted);
bch2_btree_path_verify(trans, path);
return ret;
}
@@ -1367,14 +1360,14 @@ void bch2_trans_restart_error(struct btree_trans *trans, u32 restart_count)
{
panic("trans->restart_count %u, should be %u, last restarted by %pS\n",
trans->restart_count, restart_count,
- (void *) trans->last_begin_ip);
+ (void *) trans->last_restarted_ip);
}
void bch2_trans_in_restart_error(struct btree_trans *trans)
{
panic("in transaction restart: %s, last restarted by %pS\n",
bch2_err_str(trans->restarted),
- (void *) trans->last_begin_ip);
+ (void *) trans->last_restarted_ip);
}
noinline __cold
@@ -2872,7 +2865,7 @@ u32 bch2_trans_begin(struct btree_trans *trans)
if (unlikely(time_after(jiffies, trans->srcu_lock_time + msecs_to_jiffies(10))))
bch2_trans_reset_srcu_lock(trans);
- trans->last_begin_ip = _RET_IP_;
+ trans->last_restarted_ip = _RET_IP_;
if (trans->restarted) {
bch2_btree_path_traverse_all(trans);
trans->notrace_relock_fail = false;
@@ -3053,10 +3046,6 @@ void bch2_trans_exit(struct btree_trans *trans)
if (trans->paths)
mempool_free(trans->paths, &c->btree_paths_pool);
-#ifdef CONFIG_BCACHEFS_DEBUG
- darray_exit(&trans->last_restarted);
-#endif
-
trans->mem = (void *) 0x1;
trans->paths = (void *) 0x1;
}