x(transaction_commit, 72) \
x(write_super, 73) \
x(trans_restart_would_deadlock_recursion_limit, 74) \
- x(trans_restart_write_buffer_flush, 75)
+ x(trans_restart_write_buffer_flush, 75) \
+ x(trans_restart_split_race, 76)
enum bch_persistent_counters {
#define x(t, n, ...) BCH_COUNTER_##t,
* We could attempt to avoid the transaction restart, by calling
* bch2_btree_path_upgrade() and allocating more nodes:
*/
- if (b->c.level >= as->update_level)
+ if (b->c.level >= as->update_level) {
+ trace_and_count(c, trans_restart_split_race, trans, _THIS_IP_);
return btree_trans_restart(trans, BCH_ERR_transaction_restart_split_race);
+ }
return btree_split(as, trans, path, b, keys, flags);
}
TP_ARGS(trans, caller_ip)
);
+DEFINE_EVENT(transaction_event, trans_restart_split_race,
+ TP_PROTO(struct btree_trans *trans,
+ unsigned long caller_ip),
+ TP_ARGS(trans, caller_ip)
+);
+
DEFINE_EVENT(transaction_event, trans_blocked_journal_reclaim,
TP_PROTO(struct btree_trans *trans,
unsigned long caller_ip),