Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6a808c6c authored by Amit Kumar Salecha's avatar Amit Kumar Salecha Committed by David S. Miller
Browse files

netxen: fix tx timeout recovery



o In case of tx timeout, firmare may be healthy, but some pci-func may
  see no response from it. Force firmware reset, if some pci-func
  explicitly requests so.

Signed-off-by: default avatarAmit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent bc86fcba
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -778,6 +778,9 @@ netxen_need_fw_reset(struct netxen_adapter *adapter)
	if (NX_IS_REVISION_P2(adapter->ahw.revision_id))
		return 1;

	if (adapter->need_fw_reset)
		return 1;

	/* last attempt had failed */
	if (NXRD32(adapter, CRB_CMDPEG_STATE) == PHAN_INITIALIZE_FAILED)
		return 1;
+3 −1
Original line number Diff line number Diff line
@@ -2284,8 +2284,10 @@ netxen_check_health(struct netxen_adapter *adapter)
	}

	state = NXRD32(adapter, NX_CRB_DEV_STATE);
	if (state == NX_DEV_NEED_RESET)
	if (state == NX_DEV_NEED_RESET) {
		adapter->need_fw_reset = 1;
		goto detach;
	}

	if (NX_IS_REVISION_P2(adapter->ahw.revision_id))
		return 0;