]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: simplify return values in btrfs_check_raid_min_devices
authorAnand Jain <anand.jain@oracle.com>
Tue, 27 Jul 2021 23:03:05 +0000 (07:03 +0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 23 Aug 2021 11:19:09 +0000 (13:19 +0200)
commit2799e2572e704a571366ab6aeb34f6dc6a766a6c
treef7d06b092b80f8a5fde7ea548f8e742ddb4d3094
parent38ce6e17653d3881da7eae4a336740f72e4770a0
btrfs: simplify return values in btrfs_check_raid_min_devices

Function btrfs_check_raid_min_devices() returns error code from the enum
btrfs_err_code and it starts from 1. So there is no need to check if ret
is > 0. So drop this check and also drop the local variable ret.

Signed-off-by: Anand Jain <anand.jain@oracle.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/volumes.c