netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] net: sundance: remove unused variable cnt
@ 2022-11-14 17:03 Colin Ian King
  2022-11-15  2:33 ` Jakub Kicinski
  0 siblings, 1 reply; 2+ messages in thread
From: Colin Ian King @ 2022-11-14 17:03 UTC (permalink / raw)
  To: Denis Kirjanov, David S . Miller, Eric Dumazet, Jakub Kicinski,
	netdev
  Cc: kernel-janitors, linux-kernel

Variable cnt is just being incremented and it's never used
anywhere else. The variable and the increment are redundant so
remove it.

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
 drivers/net/ethernet/dlink/sundance.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/ethernet/dlink/sundance.c b/drivers/net/ethernet/dlink/sundance.c
index 43def191f26f..aaf0eda96292 100644
--- a/drivers/net/ethernet/dlink/sundance.c
+++ b/drivers/net/ethernet/dlink/sundance.c
@@ -1414,7 +1414,6 @@ static void refill_rx (struct net_device *dev)
 {
 	struct netdev_private *np = netdev_priv(dev);
 	int entry;
-	int cnt = 0;
 
 	/* Refill the Rx ring buffers. */
 	for (;(np->cur_rx - np->dirty_rx + RX_RING_SIZE) % RX_RING_SIZE > 0;
@@ -1441,7 +1440,6 @@ static void refill_rx (struct net_device *dev)
 		np->rx_ring[entry].frag.length =
 			cpu_to_le32(np->rx_buf_sz | LastFrag);
 		np->rx_ring[entry].status = 0;
-		cnt++;
 	}
 }
 static void netdev_error(struct net_device *dev, int intr_status)
-- 
2.38.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] net: sundance: remove unused variable cnt
  2022-11-14 17:03 [PATCH] net: sundance: remove unused variable cnt Colin Ian King
@ 2022-11-15  2:33 ` Jakub Kicinski
  0 siblings, 0 replies; 2+ messages in thread
From: Jakub Kicinski @ 2022-11-15  2:33 UTC (permalink / raw)
  To: Colin Ian King
  Cc: Denis Kirjanov, David S . Miller, Eric Dumazet, netdev,
	kernel-janitors, linux-kernel

On Mon, 14 Nov 2022 17:03:17 +0000 Colin Ian King wrote:
> Variable cnt is just being incremented and it's never used
> anywhere else. The variable and the increment are redundant so
> remove it.
> 
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>

Once you've noticed that I'm tossing all your networking changes from
patchwork - the reason is that you seem to have ignored completely 
one of my replies and also recent review comments from Leon. 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-11-15  2:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-14 17:03 [PATCH] net: sundance: remove unused variable cnt Colin Ian King
2022-11-15  2:33 ` Jakub Kicinski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).