diff options
author | 2025-03-30 16:50:59 -0400 | |
---|---|---|
committer | 2025-03-30 18:25:12 -0400 | |
commit | edaed8ee8cb3fdb6b9fcde65ff31e99e4db59cab (patch) | |
tree | 529edc01e471d2e5aff02705fca13c42361cf0b2 /fs/bcachefs/journal_io.c | |
parent | bcachefs: Reorder error messages that include journal debug (diff) | |
download | wireguard-linux-edaed8ee8cb3fdb6b9fcde65ff31e99e4db59cab.tar.xz wireguard-linux-edaed8ee8cb3fdb6b9fcde65ff31e99e4db59cab.zip |
bcachefs: BCH_JSET_ENTRY_log_bkey
Add a journal entry type for logging - but logging a bkey, not a string;
to be used for data move path debugging.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to '')
-rw-r--r-- | fs/bcachefs/journal_io.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/fs/bcachefs/journal_io.c b/fs/bcachefs/journal_io.c index 228e531921b7..2debc213e47c 100644 --- a/fs/bcachefs/journal_io.c +++ b/fs/bcachefs/journal_io.c @@ -764,6 +764,23 @@ static void journal_entry_overwrite_to_text(struct printbuf *out, struct bch_fs journal_entry_btree_keys_to_text(out, c, entry); } +static int journal_entry_log_bkey_validate(struct bch_fs *c, + struct jset *jset, + struct jset_entry *entry, + unsigned version, int big_endian, + struct bkey_validate_context from) +{ + from.flags = 0; + return journal_entry_btree_keys_validate(c, jset, entry, + version, big_endian, from); +} + +static void journal_entry_log_bkey_to_text(struct printbuf *out, struct bch_fs *c, + struct jset_entry *entry) +{ + journal_entry_btree_keys_to_text(out, c, entry); +} + static int journal_entry_write_buffer_keys_validate(struct bch_fs *c, struct jset *jset, struct jset_entry *entry, |