Skip to content

Commit

Permalink
sfc: Improve log messages in case we abort probe due to a pending reset
Browse files Browse the repository at this point in the history
The current informational message doesn't properly explain what
happens, and could also appear if we defer a reset during
suspend/resume.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
  • Loading branch information
Ben Hutchings committed Aug 24, 2012
1 parent 8b7325b commit b812f8b
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions drivers/net/ethernet/sfc/efx.c
Original file line number Diff line number Diff line change
Expand Up @@ -2311,11 +2311,8 @@ static void efx_reset_work(struct work_struct *data)

/* If we're not READY then don't reset. Leave the reset_pending
* flags set so that efx_pci_probe_main will be retried */
if (efx->state != STATE_READY) {
netif_info(efx, drv, efx->net_dev,
"scheduled reset quenched; NIC not ready\n");
if (efx->state != STATE_READY)
return;
}

rtnl_lock();
(void)efx_reset(efx, fls(pending) - 1);
Expand Down Expand Up @@ -2703,6 +2700,8 @@ static int __devinit efx_pci_probe(struct pci_dev *pci_dev,
* probably hosed anyway.
*/
if (efx->reset_pending) {
netif_err(efx, probe, efx->net_dev,
"aborting probe due to scheduled reset\n");
rc = -EIO;
goto fail4;
}
Expand Down

0 comments on commit b812f8b

Please sign in to comment.