Commit 48940662 authored by Daniel J Blueman's avatar Daniel J Blueman Committed by Chris Mason

btrfs: fix message printing

Fix various messages to include newline and module prefix.
Signed-off-by: default avatarDaniel J Blueman <daniel@quora.org>
parent 94edf4ae
...@@ -243,7 +243,7 @@ void __btrfs_abort_transaction(struct btrfs_trans_handle *trans, ...@@ -243,7 +243,7 @@ void __btrfs_abort_transaction(struct btrfs_trans_handle *trans,
struct btrfs_root *root, const char *function, struct btrfs_root *root, const char *function,
unsigned int line, int errno) unsigned int line, int errno)
{ {
WARN_ONCE(1, KERN_DEBUG "btrfs: Transaction aborted"); WARN_ONCE(1, KERN_DEBUG "btrfs: Transaction aborted\n");
trans->aborted = errno; trans->aborted = errno;
/* Nothing used. The other threads that have joined this /* Nothing used. The other threads that have joined this
* transaction may be able to continue. */ * transaction may be able to continue. */
...@@ -549,11 +549,11 @@ int btrfs_parse_options(struct btrfs_root *root, char *options) ...@@ -549,11 +549,11 @@ int btrfs_parse_options(struct btrfs_root *root, char *options)
btrfs_set_opt(info->mount_opt, ENOSPC_DEBUG); btrfs_set_opt(info->mount_opt, ENOSPC_DEBUG);
break; break;
case Opt_defrag: case Opt_defrag:
printk(KERN_INFO "btrfs: enabling auto defrag"); printk(KERN_INFO "btrfs: enabling auto defrag\n");
btrfs_set_opt(info->mount_opt, AUTO_DEFRAG); btrfs_set_opt(info->mount_opt, AUTO_DEFRAG);
break; break;
case Opt_recovery: case Opt_recovery:
printk(KERN_INFO "btrfs: enabling auto recovery"); printk(KERN_INFO "btrfs: enabling auto recovery\n");
btrfs_set_opt(info->mount_opt, RECOVERY); btrfs_set_opt(info->mount_opt, RECOVERY);
break; break;
case Opt_skip_balance: case Opt_skip_balance:
...@@ -1602,7 +1602,7 @@ static int btrfs_interface_init(void) ...@@ -1602,7 +1602,7 @@ static int btrfs_interface_init(void)
static void btrfs_interface_exit(void) static void btrfs_interface_exit(void)
{ {
if (misc_deregister(&btrfs_misc) < 0) if (misc_deregister(&btrfs_misc) < 0)
printk(KERN_INFO "misc_deregister failed for control device"); printk(KERN_INFO "btrfs: misc_deregister failed for control device\n");
} }
static int __init init_btrfs_fs(void) static int __init init_btrfs_fs(void)
......
...@@ -639,7 +639,7 @@ static int __btrfs_open_devices(struct btrfs_fs_devices *fs_devices, ...@@ -639,7 +639,7 @@ static int __btrfs_open_devices(struct btrfs_fs_devices *fs_devices,
bdev = blkdev_get_by_path(device->name->str, flags, holder); bdev = blkdev_get_by_path(device->name->str, flags, holder);
if (IS_ERR(bdev)) { if (IS_ERR(bdev)) {
printk(KERN_INFO "open %s failed\n", device->name->str); printk(KERN_INFO "btrfs: open %s failed\n", device->name->str);
goto error; goto error;
} }
filemap_write_and_wait(bdev->bd_inode->i_mapping); filemap_write_and_wait(bdev->bd_inode->i_mapping);
...@@ -3769,7 +3769,7 @@ static int __btrfs_map_block(struct btrfs_mapping_tree *map_tree, int rw, ...@@ -3769,7 +3769,7 @@ static int __btrfs_map_block(struct btrfs_mapping_tree *map_tree, int rw,
read_unlock(&em_tree->lock); read_unlock(&em_tree->lock);
if (!em) { if (!em) {
printk(KERN_CRIT "unable to find logical %llu len %llu\n", printk(KERN_CRIT "btrfs: unable to find logical %llu len %llu\n",
(unsigned long long)logical, (unsigned long long)logical,
(unsigned long long)*length); (unsigned long long)*length);
BUG(); BUG();
...@@ -4226,7 +4226,7 @@ int btrfs_map_bio(struct btrfs_root *root, int rw, struct bio *bio, ...@@ -4226,7 +4226,7 @@ int btrfs_map_bio(struct btrfs_root *root, int rw, struct bio *bio,
total_devs = bbio->num_stripes; total_devs = bbio->num_stripes;
if (map_length < length) { if (map_length < length) {
printk(KERN_CRIT "mapping failed logical %llu bio len %llu " printk(KERN_CRIT "btrfs: mapping failed logical %llu bio len %llu "
"len %llu\n", (unsigned long long)logical, "len %llu\n", (unsigned long long)logical,
(unsigned long long)length, (unsigned long long)length,
(unsigned long long)map_length); (unsigned long long)map_length);
......
...@@ -97,7 +97,7 @@ static int zlib_compress_pages(struct list_head *ws, ...@@ -97,7 +97,7 @@ static int zlib_compress_pages(struct list_head *ws,
*total_in = 0; *total_in = 0;
if (Z_OK != zlib_deflateInit(&workspace->def_strm, 3)) { if (Z_OK != zlib_deflateInit(&workspace->def_strm, 3)) {
printk(KERN_WARNING "deflateInit failed\n"); printk(KERN_WARNING "btrfs: deflateInit failed\n");
ret = -1; ret = -1;
goto out; goto out;
} }
...@@ -125,7 +125,7 @@ static int zlib_compress_pages(struct list_head *ws, ...@@ -125,7 +125,7 @@ static int zlib_compress_pages(struct list_head *ws,
while (workspace->def_strm.total_in < len) { while (workspace->def_strm.total_in < len) {
ret = zlib_deflate(&workspace->def_strm, Z_SYNC_FLUSH); ret = zlib_deflate(&workspace->def_strm, Z_SYNC_FLUSH);
if (ret != Z_OK) { if (ret != Z_OK) {
printk(KERN_DEBUG "btrfs deflate in loop returned %d\n", printk(KERN_DEBUG "btrfs: deflate in loop returned %d\n",
ret); ret);
zlib_deflateEnd(&workspace->def_strm); zlib_deflateEnd(&workspace->def_strm);
ret = -1; ret = -1;
...@@ -252,7 +252,7 @@ static int zlib_decompress_biovec(struct list_head *ws, struct page **pages_in, ...@@ -252,7 +252,7 @@ static int zlib_decompress_biovec(struct list_head *ws, struct page **pages_in,
} }
if (Z_OK != zlib_inflateInit2(&workspace->inf_strm, wbits)) { if (Z_OK != zlib_inflateInit2(&workspace->inf_strm, wbits)) {
printk(KERN_WARNING "inflateInit failed\n"); printk(KERN_WARNING "btrfs: inflateInit failed\n");
return -1; return -1;
} }
while (workspace->inf_strm.total_in < srclen) { while (workspace->inf_strm.total_in < srclen) {
...@@ -336,7 +336,7 @@ static int zlib_decompress(struct list_head *ws, unsigned char *data_in, ...@@ -336,7 +336,7 @@ static int zlib_decompress(struct list_head *ws, unsigned char *data_in,
} }
if (Z_OK != zlib_inflateInit2(&workspace->inf_strm, wbits)) { if (Z_OK != zlib_inflateInit2(&workspace->inf_strm, wbits)) {
printk(KERN_WARNING "inflateInit failed\n"); printk(KERN_WARNING "btrfs: inflateInit failed\n");
return -1; return -1;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment