summaryrefslogtreecommitdiff
path: root/fs/bcachefs/super-io.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2024-01-05 19:58:50 +0300
committerKent Overstreet <kent.overstreet@linux.dev>2024-01-06 07:24:21 +0300
commit1f5af5fc178588ff1f1293b5ddadd4228ce5095e (patch)
tree7d216adaf1195331ec45469c20c6d916a8492091 /fs/bcachefs/super-io.c
parentc13fbb7de2fc4fd61a44ebfa4ba182f35e0a3286 (diff)
downloadlinux-1f5af5fc178588ff1f1293b5ddadd4228ce5095e.tar.xz
bcachefs: %pg is banished
not portable to userspace Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/super-io.c')
-rw-r--r--fs/bcachefs/super-io.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/fs/bcachefs/super-io.c b/fs/bcachefs/super-io.c
index 427426bb326c..042e08a92d4b 100644
--- a/fs/bcachefs/super-io.c
+++ b/fs/bcachefs/super-io.c
@@ -170,8 +170,12 @@ int bch2_sb_realloc(struct bch_sb_handle *sb, unsigned u64s)
u64 max_bytes = 512 << sb->sb->layout.sb_max_size_bits;
if (new_bytes > max_bytes) {
- pr_err("%pg: superblock too big: want %zu but have %llu",
- sb->bdev, new_bytes, max_bytes);
+ struct printbuf buf = PRINTBUF;
+
+ prt_bdevname(&buf, sb->bdev);
+ prt_printf(&buf, ": superblock too big: want %zu but have %llu", new_bytes, max_bytes);
+ pr_err("%s", buf.buf);
+ printbuf_exit(&buf);
return -BCH_ERR_ENOSPC_sb;
}
}