diff options
author | YueHaibing <yuehaibing@huawei.com> | 2019-07-04 03:37:45 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-07-05 15:26:47 -0700 |
commit | cfe261c24e553d322ef3fc5ae96667767d80142a (patch) | |
tree | b3842c1651f0894f0b17442369a4a37b5583f6b5 /drivers/net/ethernet/socionext | |
parent | 04fc71435fdebff3f4fcde09a208316af502f5c6 (diff) | |
download | lwn-cfe261c24e553d322ef3fc5ae96667767d80142a.tar.gz lwn-cfe261c24e553d322ef3fc5ae96667767d80142a.zip |
net: socionext: remove set but not used variable 'pkts'
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/net/ethernet/socionext/netsec.c: In function 'netsec_clean_tx_dring':
drivers/net/ethernet/socionext/netsec.c:637:15: warning:
variable 'pkts' set but not used [-Wunused-but-set-variable]
It is not used since commit ba2b232108d3 ("net: netsec: add XDP support")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/socionext')
-rw-r--r-- | drivers/net/ethernet/socionext/netsec.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/ethernet/socionext/netsec.c b/drivers/net/ethernet/socionext/netsec.c index 5544a722543f..d8d640b01119 100644 --- a/drivers/net/ethernet/socionext/netsec.c +++ b/drivers/net/ethernet/socionext/netsec.c @@ -634,15 +634,14 @@ static void netsec_set_rx_de(struct netsec_priv *priv, static bool netsec_clean_tx_dring(struct netsec_priv *priv) { struct netsec_desc_ring *dring = &priv->desc_ring[NETSEC_RING_TX]; - unsigned int pkts, bytes; struct netsec_de *entry; int tail = dring->tail; + unsigned int bytes; int cnt = 0; if (dring->is_xdp) spin_lock(&dring->lock); - pkts = 0; bytes = 0; entry = dring->vaddr + DESC_SZ * tail; |