[07/10] net/bnxt: reduce cleanup time during reset recovery
diff mbox series

Message ID 20191004050246.90165-8-ajit.khaparde@broadcom.com
State Changes Requested, archived
Delegated to: Ferruh Yigit
Headers show
Series
  • bnxt patchset with bug fixes
Related show

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Ajit Khaparde Oct. 4, 2019, 5:02 a.m. UTC
From: Rahul Gupta <rahul.gupta@broadcom.com>

In stop_op(), don't wait for link down event's ASYNC response from FW.

Signed-off-by: Rahul Gupta <rahul.gupta@broadcom.com>
Reviewed-by: Kalesh Anakkur Purayil <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_ethdev.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

Patch
diff mbox series

diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c
index 3b48f44f85..fb4deef821 100644
--- a/drivers/net/bnxt/bnxt_ethdev.c
+++ b/drivers/net/bnxt/bnxt_ethdev.c
@@ -960,8 +960,12 @@  static void bnxt_dev_stop_op(struct rte_eth_dev *eth_dev)
 		eth_dev->data->dev_link.link_status = 0;
 	}
 	bnxt_dev_set_link_down_op(eth_dev);
-	/* Wait for link to be reset and the async notification to process. */
-	rte_delay_ms(BNXT_LINK_WAIT_INTERVAL * 2);
+
+	/* Wait for link to be reset and the async notification to process.
+	 * During reset recovery, there is no need to wait
+	 */
+	if (!is_bnxt_in_error(bp))
+		rte_delay_ms(BNXT_LINK_WAIT_INTERVAL * 2);
 
 	/* Clean queue intr-vector mapping */
 	rte_intr_efd_disable(intr_handle);