mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-04-11 07:11:51 -04:00
bcachefs: Change "disk accounting version 0" check to commit only
6.11 had a bug where we'd sometimes create disk accounting keys with version 0, which causes issues for journal replay - but we don't need to delete existing accounting keys with version 0. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
@@ -134,7 +134,8 @@ int bch2_accounting_validate(struct bch_fs *c, struct bkey_s_c k,
|
||||
void *end = &acc_k + 1;
|
||||
int ret = 0;
|
||||
|
||||
bkey_fsck_err_on(bversion_zero(k.k->bversion),
|
||||
bkey_fsck_err_on((flags & BCH_VALIDATE_commit) &&
|
||||
bversion_zero(k.k->bversion),
|
||||
c, accounting_key_version_0,
|
||||
"accounting key with version=0");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user