[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20181226050517.74381-1-kjlu@umn.edu>
Date: Tue, 25 Dec 2018 23:05:17 -0600
From: Kangjie Lu <kjlu@....edu>
To: kjlu@....edu
Cc: pakki001@....edu,
Solarflare linux maintainers <linux-net-drivers@...arflare.com>,
Edward Cree <ecree@...arflare.com>,
Bert Kenward <bkenward@...arflare.com>,
"David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH] net: sfc: checks status of efx_mcdi_rpc
efx_mcdi_rpc() could fail. The fix checks its status and issues an error
message if it fails.
Signed-off-by: Kangjie Lu <kjlu@....edu>
---
drivers/net/ethernet/sfc/mcdi.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/sfc/mcdi.c b/drivers/net/ethernet/sfc/mcdi.c
index dfad93fca0a6..9486e6534dea 100644
--- a/drivers/net/ethernet/sfc/mcdi.c
+++ b/drivers/net/ethernet/sfc/mcdi.c
@@ -1819,6 +1819,9 @@ void efx_mcdi_set_id_led(struct efx_nic *efx, enum efx_led_mode mode)
rc = efx_mcdi_rpc(efx, MC_CMD_SET_ID_LED, inbuf, sizeof(inbuf),
NULL, 0, NULL);
+ if (rc)
+ netif_err(efx, hw, efx->net_dev, "%s: failed rc=%d\n",
+ __func__, rc);
}
static int efx_mcdi_reset_func(struct efx_nic *efx)
--
2.17.2 (Apple Git-113)
Powered by blists - more mailing lists