diff options
author | Masahisa Kojima <masahisa.kojima@linaro.org> | 2018-10-23 13:24:28 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-10-23 19:55:35 +0200 |
commit | 8d5b0bf611ec5b7618d5b772dddc93b8afa78cb8 (patch) | |
tree | 52f5d7e199ab7b77ef6c22be72a3b680899a6863 /drivers/net | |
parent | net: socionext: Add dummy PHY register read in phy_write() (diff) | |
download | linux-8d5b0bf611ec5b7618d5b772dddc93b8afa78cb8.tar.xz linux-8d5b0bf611ec5b7618d5b772dddc93b8afa78cb8.zip |
net: socionext: Reset tx queue in ndo_stop
We observed that packets and bytes count are not reset
when user performs interface down. Eventually, tx queue is
exhausted and packets will not be sent out.
To avoid this problem, resets tx queue in ndo_stop.
Fixes: 533dd11a12f6 ("net: socionext: Add Synquacer NetSec driver")
Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org>
Signed-off-by: Yoshitoyo Osaki <osaki.yoshitoyo@socionext.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ethernet/socionext/netsec.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/socionext/netsec.c b/drivers/net/ethernet/socionext/netsec.c index dbf71e1fa701..d9d0d03e4ce7 100644 --- a/drivers/net/ethernet/socionext/netsec.c +++ b/drivers/net/ethernet/socionext/netsec.c @@ -955,6 +955,9 @@ static void netsec_uninit_pkt_dring(struct netsec_priv *priv, int id) dring->head = 0; dring->tail = 0; dring->pkt_cnt = 0; + + if (id == NETSEC_RING_TX) + netdev_reset_queue(priv->ndev); } static void netsec_free_dring(struct netsec_priv *priv, int id) |