netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] cxgb4: fix error return code in adap_init0()
@ 2018-03-28 12:51 Wei Yongjun
  2018-03-30 13:52 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Wei Yongjun @ 2018-03-28 12:51 UTC (permalink / raw)
  To: Ganesh Goudar, Kumar Sanghvi; +Cc: Wei Yongjun, netdev, kernel-janitors

Fix to return a negative error code from the hash filter init error
handling case instead of 0, as done elsewhere in this function.

Fixes: 5c31254e35a8 ("cxgb4: initialize hash-filter configuration")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
index 57d38f8..0072580 100644
--- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
+++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
@@ -4449,7 +4449,8 @@ static int adap_init0(struct adapter *adap)
 		adap->params.ofldq_wr_cred = val[5];
 
 		if (caps_cmd.niccaps & htons(FW_CAPS_CONFIG_NIC_HASHFILTER)) {
-			if (init_hash_filter(adap) < 0)
+			ret = init_hash_filter(adap);
+			if (ret < 0)
 				goto bye;
 		} else {
 			adap->params.offload = 1;

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net-next] cxgb4: fix error return code in adap_init0()
  2018-03-28 12:51 [PATCH net-next] cxgb4: fix error return code in adap_init0() Wei Yongjun
@ 2018-03-30 13:52 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2018-03-30 13:52 UTC (permalink / raw)
  To: weiyongjun1; +Cc: ganeshgr, kumaras, netdev, kernel-janitors

From: Wei Yongjun <weiyongjun1@huawei.com>
Date: Wed, 28 Mar 2018 12:51:09 +0000

> Fix to return a negative error code from the hash filter init error
> handling case instead of 0, as done elsewhere in this function.
> 
> Fixes: 5c31254e35a8 ("cxgb4: initialize hash-filter configuration")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>

Applied, thanks Wei.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-03-30 13:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-28 12:51 [PATCH net-next] cxgb4: fix error return code in adap_init0() Wei Yongjun
2018-03-30 13:52 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).