lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20181019010843.3605-4-masahisa.kojima@linaro.org>
Date:   Fri, 19 Oct 2018 10:08:43 +0900
From:   masahisa.kojima@...aro.org
To:     netdev@...r.kernel.org
Cc:     ilias.apalodimas@...aro.org, jaswinder.singh@...aro.org,
        ard.biesheuvel@...aro.org, osaki.yoshitoyo@...ionext.com,
        Masahisa Kojima <masahisa.kojima@...aro.org>
Subject: [PATCH 3/3] net: socionext: Reset tx queue in ndo_stop

From: Masahisa Kojima <masahisa.kojima@...aro.org>

Without resetting tx queue in ndo_stop, packets and bytes count
are not reset when the interface is down.
Eventually, tx queue is exhausted and packets will not be
sent out.

Signed-off-by: Masahisa Kojima <masahisa.kojima@...aro.org>
Signed-off-by: Yoshitoyo Osaki <osaki.yoshitoyo@...ionext.com>
---
 drivers/net/ethernet/socionext/netsec.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/ethernet/socionext/netsec.c b/drivers/net/ethernet/socionext/netsec.c
index e7faaf8be99e..4b32da76d577 100644
--- a/drivers/net/ethernet/socionext/netsec.c
+++ b/drivers/net/ethernet/socionext/netsec.c
@@ -954,6 +954,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)
-- 
2.14.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ