netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net v2 1/2] octeontx2-pf: check negative error code in otx2_open()
@ 2024-03-26  6:12 Su Hui
  2024-03-26  6:12 ` [PATCH net v2 2/2] octeontx2-pf: remove unused variables req_hdr and rsp_hdr Su Hui
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Su Hui @ 2024-03-26  6:12 UTC (permalink / raw)
  To: sgoutham, gakula, sbhatta, hkelam, davem, edumazet, kuba, pabeni
  Cc: Su Hui, saikrishnag, netdev, linux-kernel, kernel-janitors

otx2_rxtx_enable() return negative error code such as -EIO,
check -EIO rather than EIO to fix this problem.

Fixes: c926252205c4 ("octeontx2-pf: Disable packet I/O for graceful exit")
Signed-off-by: Su Hui <suhui@nfschina.com>
Reviewed-by: Subbaraya Sundeep <sbhatta@marvell.com>
---
v2: add "net" in subject
 drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
index b40bd0e46751..3f46d5e0fb2e 100644
--- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
+++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
@@ -1933,7 +1933,7 @@ int otx2_open(struct net_device *netdev)
 	 * mcam entries are enabled to receive the packets. Hence disable the
 	 * packet I/O.
 	 */
-	if (err == EIO)
+	if (err == -EIO)
 		goto err_disable_rxtx;
 	else if (err)
 		goto err_tx_stop_queues;
-- 
2.30.2


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

end of thread, other threads:[~2024-03-26 15:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-26  6:12 [PATCH net v2 1/2] octeontx2-pf: check negative error code in otx2_open() Su Hui
2024-03-26  6:12 ` [PATCH net v2 2/2] octeontx2-pf: remove unused variables req_hdr and rsp_hdr Su Hui
2024-03-26 14:27   ` Simon Horman
2024-03-26 14:19 ` [PATCH net v2 1/2] octeontx2-pf: check negative error code in otx2_open() Simon Horman
2024-03-26 15:51 ` Kalesh Anakkur Purayil

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).