cxgb4: Update proper netdev stats for rx drops
authorGanesh Goudar <ganeshgr@chelsio.com>
Wed, 15 Feb 2017 06:15:25 +0000 (11:45 +0530)
committerDavid S. Miller <davem@davemloft.net>
Wed, 15 Feb 2017 17:41:04 +0000 (12:41 -0500)
Count buffer group drops or truncates as rx drops rather than
rx errors in netdev stats.

Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com>
Signed-off-by: Arjun V <arjun@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c

index 70590144be03c531af009283be19caebc1676180..8ba3dc2e236cc05d2867f78603ec007fec22d05a 100644 (file)
@@ -2400,7 +2400,7 @@ static void cxgb_get_stats(struct net_device *dev,
        ns->rx_over_errors   = 0;
        ns->rx_crc_errors    = stats.rx_fcs_err;
        ns->rx_frame_errors  = stats.rx_symbol_err;
-       ns->rx_fifo_errors   = stats.rx_ovflow0 + stats.rx_ovflow1 +
+       ns->rx_dropped       = stats.rx_ovflow0 + stats.rx_ovflow1 +
                               stats.rx_ovflow2 + stats.rx_ovflow3 +
                               stats.rx_trunc0 + stats.rx_trunc1 +
                               stats.rx_trunc2 + stats.rx_trunc3;