sfxge(4): only raise an exception after MC assert or reboot in the common code
Fix efx_mcdi_request_poll so it only raises an exception if EIO is reported from a detected MC assert or reboot. This prevents an unnecessary exception being raised if an MCDI response error code is trandlated to EIO. Submitted by: Andy Moreton <amoreton at solarflare.com> Sponsored by: Solarflare Communications, Inc. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D6392
This commit is contained in:
parent
fdbffbab18
commit
2be4ef39bc
@ -519,6 +519,11 @@ efx_mcdi_request_poll(
|
||||
if ((rc = efx_mcdi_poll_reboot(enp)) != 0) {
|
||||
emip->emi_pending_req = NULL;
|
||||
EFSYS_UNLOCK(enp->en_eslp, state);
|
||||
|
||||
/* Reboot/Assertion */
|
||||
if (rc == EIO || rc == EINTR)
|
||||
efx_mcdi_raise_exception(enp, emrp, rc);
|
||||
|
||||
goto fail1;
|
||||
}
|
||||
}
|
||||
@ -553,10 +558,6 @@ efx_mcdi_request_poll(
|
||||
if (!emrp->emr_quiet)
|
||||
EFSYS_PROBE1(fail1, efx_rc_t, rc);
|
||||
|
||||
/* Reboot/Assertion */
|
||||
if (rc == EIO || rc == EINTR)
|
||||
efx_mcdi_raise_exception(enp, emrp, rc);
|
||||
|
||||
return (B_TRUE);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user