提交 cf5819b2 编写于 作者: M Masahisa Kojima 提交者: Greg Kroah-Hartman

net: socionext: Reset tx queue in ndo_stop

[ Upstream commit 8d5b0bf611ec5b7618d5b772dddc93b8afa78cb8 ]

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: 533dd11a ("net: socionext: Add Synquacer NetSec driver")
Signed-off-by: NMasahisa Kojima <masahisa.kojima@linaro.org>
Signed-off-by: NYoshitoyo Osaki <osaki.yoshitoyo@socionext.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
Signed-off-by: NSasha Levin <sashal@kernel.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 3f8141b1
...@@ -940,6 +940,9 @@ static void netsec_uninit_pkt_dring(struct netsec_priv *priv, int id) ...@@ -940,6 +940,9 @@ static void netsec_uninit_pkt_dring(struct netsec_priv *priv, int id)
dring->head = 0; dring->head = 0;
dring->tail = 0; dring->tail = 0;
dring->pkt_cnt = 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) static void netsec_free_dring(struct netsec_priv *priv, int id)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册