[PATCH -next] scsi: fcoe: simplify the return expression of fcoe_sysfs_setup

From: Qinglang Miao
Date: Mon Sep 21 2020 - 09:12:01 EST


Simplify the return expression.

Signed-off-by: Qinglang Miao <miaoqinglang@xxxxxxxxxx>
---
drivers/scsi/fcoe/fcoe_sysfs.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/drivers/scsi/fcoe/fcoe_sysfs.c b/drivers/scsi/fcoe/fcoe_sysfs.c
index 2cb7a8c93..ffef2c8ed 100644
--- a/drivers/scsi/fcoe/fcoe_sysfs.c
+++ b/drivers/scsi/fcoe/fcoe_sysfs.c
@@ -1053,16 +1053,10 @@ EXPORT_SYMBOL_GPL(fcoe_fcf_device_add);

int __init fcoe_sysfs_setup(void)
{
- int error;
-
atomic_set(&ctlr_num, 0);
atomic_set(&fcf_num, 0);

- error = bus_register(&fcoe_bus_type);
- if (error)
- return error;
-
- return 0;
+ return bus_register(&fcoe_bus_type);
}

void __exit fcoe_sysfs_teardown(void)
--
2.23.0