From: Pan Bian Date: Sun, 4 Dec 2016 04:51:53 +0000 (+0800) Subject: btrfs: return the actual error value from from btrfs_uuid_tree_iterate X-Git-Tag: v4.14-rc1~1552^2~9^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=73ba39ab9307340dc98ec3622891314bbc09cc2e;p=platform%2Fkernel%2Flinux-rpi3.git btrfs: return the actual error value from from btrfs_uuid_tree_iterate In function btrfs_uuid_tree_iterate(), errno is assigned to variable ret on errors. However, it directly returns 0. It may be better to return ret. This patch also removes the warning, because the caller already prints a warning. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188731 Signed-off-by: Pan Bian Reviewed-by: Omar Sandoval [ edited subject ] Signed-off-by: David Sterba --- diff --git a/fs/btrfs/uuid-tree.c b/fs/btrfs/uuid-tree.c index 161342b..726f928 100644 --- a/fs/btrfs/uuid-tree.c +++ b/fs/btrfs/uuid-tree.c @@ -352,7 +352,5 @@ skip: out: btrfs_free_path(path); - if (ret) - btrfs_warn(fs_info, "btrfs_uuid_tree_iterate failed %d", ret); - return 0; + return ret; }