net: gianfar: Extend statistics counters to 64-bit
authorEsben Haabendal <esben@geanix.com>
Thu, 17 Jun 2021 09:49:17 +0000 (11:49 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 17 Jun 2021 18:39:47 +0000 (11:39 -0700)
No reason to wrap counter values at 2^32.  Especially the bytes counters
can wrap pretty fast on Gbit networks.

Signed-off-by: Esben Haabendal <esben@geanix.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/gianfar.h

index 5ea47df..d8ae535 100644 (file)
@@ -913,8 +913,8 @@ enum {
  * Per TX queue stats
  */
 struct tx_q_stats {
-       unsigned long tx_packets;
-       unsigned long tx_bytes;
+       u64 tx_packets;
+       u64 tx_bytes;
 };
 
 /**
@@ -963,9 +963,9 @@ struct gfar_priv_tx_q {
  * Per RX queue stats
  */
 struct rx_q_stats {
-       unsigned long rx_packets;
-       unsigned long rx_bytes;
-       unsigned long rx_dropped;
+       u64 rx_packets;
+       u64 rx_bytes;
+       u64 rx_dropped;
 };
 
 struct gfar_rx_buff {