Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Bogendoerfer <tbogendoerfer@suse.de>2018-08-24 13:20:03 +0200
committerThomas Bogendoerfer <tbogendoerfer@suse.de>2018-08-24 13:20:14 +0200
commita4f807897541c406cba3393e206f694fd882cc7f (patch)
tree74952cea0757b62302ff58af68235a173ae9432e
parent9c84c72ae14a8f50634662aa8d6cd4200608db3f (diff)
ixgbe: Reorder Tx/Rx shutdown to reduce time needed to stop
device (bsc#1101557). suse-commit: 8d80da6f72d6cce060fb64a3a1ff62db6d9bd6bf
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_main.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index d97434604a51..384f0f081464 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -5828,6 +5828,13 @@ void ixgbe_down(struct ixgbe_adapter *adapter)
if (test_and_set_bit(__IXGBE_DOWN, &adapter->state))
return; /* do nothing if already down */
+ /* Shut off incoming Tx traffic */
+ netif_tx_stop_all_queues(netdev);
+
+ /* call carrier off first to avoid false dev_watchdog timeouts */
+ netif_carrier_off(netdev);
+ netif_tx_disable(netdev);
+
/* disable receives */
hw->mac.ops.disable_rx(hw);
@@ -5836,14 +5843,6 @@ void ixgbe_down(struct ixgbe_adapter *adapter)
/* this call also flushes the previous write */
ixgbe_disable_rx_queue(adapter, adapter->rx_ring[i]);
- usleep_range(10000, 20000);
-
- netif_tx_stop_all_queues(netdev);
-
- /* call carrier off first to avoid false dev_watchdog timeouts */
- netif_carrier_off(netdev);
- netif_tx_disable(netdev);
-
ixgbe_irq_disable(adapter);
ixgbe_napi_disable_all(adapter);