diff mbox series

[net-next] net: hinic: simplify the return hinic_configure_max_qnum()

Message ID 20201209092241.20361-1-zhengyongjun3@huawei.com
State Superseded
Headers show
Series [net-next] net: hinic: simplify the return hinic_configure_max_qnum() | expand

Commit Message

Zheng Yongjun Dec. 9, 2020, 9:22 a.m. UTC
Simplify the return expression.

Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
---
 drivers/net/ethernet/huawei/hinic/hinic_main.c | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

Comments

David Miller Dec. 10, 2020, 1:12 a.m. UTC | #1
From: Zheng Yongjun <zhengyongjun3@huawei.com>
Date: Wed, 9 Dec 2020 17:22:41 +0800

> Simplify the return expression.
> 
> Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>

Applied.
diff mbox series

Patch

diff --git a/drivers/net/ethernet/huawei/hinic/hinic_main.c b/drivers/net/ethernet/huawei/hinic/hinic_main.c
index 350225bbe0be..9a9b09401d01 100644
--- a/drivers/net/ethernet/huawei/hinic/hinic_main.c
+++ b/drivers/net/ethernet/huawei/hinic/hinic_main.c
@@ -313,13 +313,7 @@  static void free_rxqs(struct hinic_dev *nic_dev)
 
 static int hinic_configure_max_qnum(struct hinic_dev *nic_dev)
 {
-	int err;
-
-	err = hinic_set_max_qnum(nic_dev, nic_dev->hwdev->nic_cap.max_qps);
-	if (err)
-		return err;
-
-	return 0;
+	return hinic_set_max_qnum(nic_dev, nic_dev->hwdev->nic_cap.max_qps);
 }
 
 static int hinic_rss_init(struct hinic_dev *nic_dev)