bcachefs: Fix move_extent_fail counter

fail counters need to be events, not numbers of sectors - or the
calculations the tests use for determining if we've had too many
slowpath events don't work.

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
Kent Overstreet
2023-05-26 18:12:55 -04:00
parent fc0ee376bb
commit c26463ce99

View File

@@ -374,7 +374,7 @@ static int __bch2_data_update_index_update(struct btree_trans *trans,
&m->ctxt->stats->sectors_raced);
}
this_cpu_add(c->counters[BCH_COUNTER_move_extent_fail], new->k.size);
this_cpu_inc(c->counters[BCH_COUNTER_move_extent_fail]);
bch2_btree_iter_advance(&iter);
goto next;