aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/sfc/siena.c
diff options
context:
space:
mode:
authorSteve Hodgson <shodgson@solarflare.com>2010-02-03 09:30:17 +0000
committerDavid S. Miller <davem@davemloft.net>2010-02-03 19:12:43 -0800
commit8b2103add08b79abd3ac7015b4bac744c0af534e (patch)
tree018ee0b97a17a702dd163d17cf13483ae1906408 /drivers/net/sfc/siena.c
parent5297a98d5dd6de86fe1e2ffc9ea60cdf59b71443 (diff)
sfc: Handle firmware assertion failure while resetting
This allows the driver to recover if the MC firmware has crashed due to an assertion failure. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/siena.c')
-rw-r--r--drivers/net/sfc/siena.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/sfc/siena.c b/drivers/net/sfc/siena.c
index f8c6771e66d..0e4c13abf08 100644
--- a/drivers/net/sfc/siena.c
+++ b/drivers/net/sfc/siena.c
@@ -181,6 +181,12 @@ static int siena_test_registers(struct efx_nic *efx)
static int siena_reset_hw(struct efx_nic *efx, enum reset_type method)
{
+ int rc;
+
+ /* Recover from a failed assertion pre-reset */
+ rc = efx_mcdi_handle_assertion(efx);
+ if (rc)
+ return rc;
if (method == RESET_TYPE_WORLD)
return efx_mcdi_reset_mc(efx);