diff options
| author | Kent Overstreet <[email protected]> | 2024-10-03 01:35:38 +0000 |
|---|---|---|
| committer | Kent Overstreet <[email protected]> | 2024-10-03 01:37:42 +0000 |
| commit | d28786606a51620df7b7a3e7231338d9bc081656 (patch) | |
| tree | 78687800dfed859057d0ee05dfa6d29a159c6254 /fs/bcachefs/btree_trans_commit.c | |
| parent | bcachefs: Fix bch2_inode_is_open() check (diff) | |
| download | kernel-d28786606a51620df7b7a3e7231338d9bc081656.tar.gz kernel-d28786606a51620df7b7a3e7231338d9bc081656.zip | |
bcachefs: Fix trans_commit disk accounting revert
We only are applying JSET_ENTRY_TYPE_write_buffer_keys, revert path was
missed.
Fixes: a3581ca35d2b ("bcachefs: Fix BCH_TRANS_COMMIT_skip_accounting_apply")
Signed-off-by: Kent Overstreet <[email protected]>
Diffstat (limited to 'fs/bcachefs/btree_trans_commit.c')
| -rw-r--r-- | fs/bcachefs/btree_trans_commit.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/bcachefs/btree_trans_commit.c b/fs/bcachefs/btree_trans_commit.c index 1a74a1a252ee..9bf471fa4361 100644 --- a/fs/bcachefs/btree_trans_commit.c +++ b/fs/bcachefs/btree_trans_commit.c @@ -832,7 +832,8 @@ revert_fs_usage: for (struct jset_entry *entry2 = trans->journal_entries; entry2 != entry; entry2 = vstruct_next(entry2)) - if (jset_entry_is_key(entry2) && entry2->start->k.type == KEY_TYPE_accounting) { + if (entry2->type == BCH_JSET_ENTRY_write_buffer_keys && + entry2->start->k.type == KEY_TYPE_accounting) { struct bkey_s_accounting a = bkey_i_to_s_accounting(entry2->start); bch2_accounting_neg(a); |
