]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
bnxt_en: Call bnxt_ulp_stop() during tx timeout.
authorMichael Chan <michael.chan@broadcom.com>
Wed, 8 Mar 2017 23:44:33 +0000 (18:44 -0500)
committerSomasundaram Krishnasamy <somasundaram.krishnasamy@oracle.com>
Tue, 11 Jul 2017 00:04:08 +0000 (17:04 -0700)
Orabug: 264025332632559926366387

If we call bnxt_reset_task() due to tx timeout, we should call
bnxt_ulp_stop() to inform the RDMA driver about the error and the
impending reset.

Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit b386cd362ffea09d05c56bfa85d104562e860647)
Signed-off-by: Brian Maly <brian.maly@oracle.com>
Signed-off-by: Somasundaram Krishnasamy <somasundaram.krishnasamy@oracle.com>
drivers/net/ethernet/broadcom/bnxt/bnxt.c

index 574b5f72e51ad803c7f71113d4132f9f2874c6dc..81581dd533feca1595d66dd52484586f28f4a795 100644 (file)
@@ -6529,8 +6529,14 @@ static void bnxt_reset_task(struct bnxt *bp, bool silent)
        if (!silent)
                bnxt_dbg_dump_states(bp);
        if (netif_running(bp->dev)) {
+               int rc;
+
+               if (!silent)
+                       bnxt_ulp_stop(bp);
                bnxt_close_nic(bp, false, false);
-               bnxt_open_nic(bp, false, false);
+               rc = bnxt_open_nic(bp, false, false);
+               if (!silent && !rc)
+                       bnxt_ulp_start(bp);
        }
 }