aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/disk-io.c
diff options
context:
space:
mode:
authorAnand Jain <anand.jain@oracle.com>2015-09-25 02:43:01 -0400
committerDavid Sterba <dsterba@suse.com>2015-09-29 10:30:00 -0400
commita4553fefb59cb0336f543fa567170b47e90142a9 (patch)
tree103dcab4eeecae6d9ee4e796bcdb4209aa340ca4 /fs/btrfs/disk-io.c
parent57d816a15ba2c2690c57635134bc01cf4da4623c (diff)
Btrfs: consolidate btrfs_error() to btrfs_std_error()
btrfs_error() and btrfs_std_error() does the same thing and calls _btrfs_std_error(), so consolidate them together. And the main motivation is that btrfs_error() is closely named with btrfs_err(), one handles error action the other is to log the error, so don't closely name them. Signed-off-by: Anand Jain <anand.jain@oracle.com> Suggested-by: David Sterba <dsterba@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/disk-io.c')
-rw-r--r--fs/btrfs/disk-io.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c
index 357d9f9c9968..0f8e33f2bcea 100644
--- a/fs/btrfs/disk-io.c
+++ b/fs/btrfs/disk-io.c
@@ -2377,7 +2377,7 @@ static int btrfs_replay_log(struct btrfs_fs_info *fs_info,
2377 /* returns with log_tree_root freed on success */ 2377 /* returns with log_tree_root freed on success */
2378 ret = btrfs_recover_log_trees(log_tree_root); 2378 ret = btrfs_recover_log_trees(log_tree_root);
2379 if (ret) { 2379 if (ret) {
2380 btrfs_error(tree_root->fs_info, ret, 2380 btrfs_std_error(tree_root->fs_info, ret,
2381 "Failed to recover log tree"); 2381 "Failed to recover log tree");
2382 free_extent_buffer(log_tree_root->node); 2382 free_extent_buffer(log_tree_root->node);
2383 kfree(log_tree_root); 2383 kfree(log_tree_root);
@@ -3556,7 +3556,7 @@ static int write_all_supers(struct btrfs_root *root, int max_mirrors)
3556 if (ret) { 3556 if (ret) {
3557 mutex_unlock( 3557 mutex_unlock(
3558 &root->fs_info->fs_devices->device_list_mutex); 3558 &root->fs_info->fs_devices->device_list_mutex);
3559 btrfs_error(root->fs_info, ret, 3559 btrfs_std_error(root->fs_info, ret,
3560 "errors while submitting device barriers."); 3560 "errors while submitting device barriers.");
3561 return ret; 3561 return ret;
3562 } 3562 }
@@ -3596,7 +3596,7 @@ static int write_all_supers(struct btrfs_root *root, int max_mirrors)
3596 mutex_unlock(&root->fs_info->fs_devices->device_list_mutex); 3596 mutex_unlock(&root->fs_info->fs_devices->device_list_mutex);
3597 3597
3598 /* FUA is masked off if unsupported and can't be the reason */ 3598 /* FUA is masked off if unsupported and can't be the reason */
3599 btrfs_error(root->fs_info, -EIO, 3599 btrfs_std_error(root->fs_info, -EIO,
3600 "%d errors while writing supers", total_errors); 3600 "%d errors while writing supers", total_errors);
3601 return -EIO; 3601 return -EIO;
3602 } 3602 }
@@ -3614,7 +3614,7 @@ static int write_all_supers(struct btrfs_root *root, int max_mirrors)
3614 } 3614 }
3615 mutex_unlock(&root->fs_info->fs_devices->device_list_mutex); 3615 mutex_unlock(&root->fs_info->fs_devices->device_list_mutex);
3616 if (total_errors > max_errors) { 3616 if (total_errors > max_errors) {
3617 btrfs_error(root->fs_info, -EIO, 3617 btrfs_std_error(root->fs_info, -EIO,
3618 "%d errors while writing supers", total_errors); 3618 "%d errors while writing supers", total_errors);
3619 return -EIO; 3619 return -EIO;
3620 } 3620 }