summaryrefslogtreecommitdiff
path: root/fs/bcachefs/journal.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2021-03-19 16:30:01 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-22 17:08:56 -0400
commitba401eaac380d9598b0a346290a77e43cb4b8211 (patch)
treedba95e1a9cc2aab2a4b5bb248f5697bfb9f1674d /fs/bcachefs/journal.c
parent2c944fa12dc731bf43532d99a2bfbe8c4b7186e5 (diff)
bcachefs: Don't list non journal devs in journal_debug_to_text()
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/journal.c')
-rw-r--r--fs/bcachefs/journal.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/bcachefs/journal.c b/fs/bcachefs/journal.c
index d5bbbf619359..22069c277c15 100644
--- a/fs/bcachefs/journal.c
+++ b/fs/bcachefs/journal.c
@@ -1236,6 +1236,9 @@ void __bch2_journal_debug_to_text(struct printbuf *out, struct journal *j)
&c->rw_devs[BCH_DATA_journal]) {
struct journal_device *ja = &ca->journal;
+ if (!test_bit(ca->dev_idx, c->rw_devs[BCH_DATA_journal].d))
+ continue;
+
if (!ja->nr)
continue;