aboutsummaryrefslogtreecommitdiff
path: root/fs/bcachefs/super-io.c
diff options
context:
space:
mode:
authorGravatar Kent Overstreet <kent.overstreet@gmail.com> 2022-02-22 04:53:48 -0500
committerGravatar Kent Overstreet <kent.overstreet@linux.dev> 2023-10-22 17:09:24 -0400
commit702a4ef07774fbc565f3e567073d2f83f9602667 (patch)
tree2a3075cca3b847265a4c5d345b40e53cf9f684e8 /fs/bcachefs/super-io.c
parentbcachefs: Fix a use after free (diff)
downloadlinux-702a4ef07774fbc565f3e567073d2f83f9602667.tar.gz
linux-702a4ef07774fbc565f3e567073d2f83f9602667.tar.bz2
linux-702a4ef07774fbc565f3e567073d2f83f9602667.zip
bcachefs: Add tabstops to printbufs
Now, when outputting to printbufs, we can set tabstops and left or right justify text to them - this is to be used by the userspace 'bcachefs fs usage' command. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to 'fs/bcachefs/super-io.c')
-rw-r--r--fs/bcachefs/super-io.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/bcachefs/super-io.c b/fs/bcachefs/super-io.c
index e1ff14eedaea..f95c9d754530 100644
--- a/fs/bcachefs/super-io.c
+++ b/fs/bcachefs/super-io.c
@@ -1061,7 +1061,7 @@ static void bch2_sb_members_to_text(struct printbuf *out, struct bch_sb *sb,
pr_buf(out, "Device: %u", i);
pr_newline(out);
- printbuf_indent_push(out, 2);
+ pr_indent_push(out, 2);
pr_buf(out, "UUID: ");
pr_uuid(out, m->uuid.b);
@@ -1129,7 +1129,7 @@ static void bch2_sb_members_to_text(struct printbuf *out, struct bch_sb *sb,
BCH_MEMBER_DISCARD(m));
pr_newline(out);
- printbuf_indent_pop(out, 2);
+ pr_indent_pop(out, 2);
}
}
@@ -1471,9 +1471,9 @@ void bch2_sb_field_to_text(struct printbuf *out, struct bch_sb *sb,
pr_newline(out);
if (ops && ops->to_text) {
- printbuf_indent_push(out, 2);
+ pr_indent_push(out, 2);
bch2_sb_field_ops[type]->to_text(out, sb, f);
- printbuf_indent_pop(out, 2);
+ pr_indent_pop(out, 2);
}
}
@@ -1656,9 +1656,9 @@ void bch2_sb_to_text(struct printbuf *out, struct bch_sb *sb,
pr_newline(out);
pr_buf(out, "layout:");
pr_newline(out);
- printbuf_indent_push(out, 2);
+ pr_indent_push(out, 2);
bch2_sb_layout_to_text(out, &sb->layout);
- printbuf_indent_pop(out, 2);
+ pr_indent_pop(out, 2);
}
vstruct_for_each(sb, f)