Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1614331

[PATCH] net: ethernet: ti: cpsw: wake tx queues on ndo_tx_timeout

From Grygorii Strashko <grygorii.strashko@ti.com>
Newsgroups linux.kernel
Subject [PATCH] net: ethernet: ti: cpsw: wake tx queues on ndo_tx_timeout
Date 2017-04-01 01:50 +0200
Message-ID <tresO-2Rp-3@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


In case, if TX watchdog is fired some or all netdev TX queues will be
stopped and as part of recovery it is required not only to drain and
reinitailize CPSW TX channeles, but also wake up stoppted TX queues what
doesn't happen now and netdevice will stop transmiting data until
reopenned.

Hence, add netif_tx_wake_all_queues() call in .ndo_tx_timeout() to complete
recovery and restore TX path.

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
---
 drivers/net/ethernet/ti/cpsw.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c
index 86d6f10..71fd4ef 100644
--- a/drivers/net/ethernet/ti/cpsw.c
+++ b/drivers/net/ethernet/ti/cpsw.c
@@ -1819,6 +1819,8 @@ static void cpsw_ndo_tx_timeout(struct net_device *ndev)
 	}
 
 	cpsw_intr_enable(cpsw);
+	netif_trans_update(ndev);
+	netif_tx_wake_all_queues(ndev);
 }
 
 static int cpsw_ndo_set_mac_address(struct net_device *ndev, void *p)
-- 
2.10.1

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH] net: ethernet: ti: cpsw: wake tx queues on ndo_tx_timeout Grygorii Strashko <grygorii.strashko@ti.com> - 2017-04-01 01:50 +0200
  Re: [PATCH] net: ethernet: ti: cpsw: wake tx queues on  ndo_tx_timeout David Miller <davem@davemloft.net> - 2017-04-03 04:50 +0200

csiph-web