Do not increase net_device_stats rx_{packets,bytes} when receiving error frames. Signed-off-by: Jimmy Assarsson <extja@xxxxxxxxxx> --- drivers/net/can/kvaser_pciefd.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/can/kvaser_pciefd.c b/drivers/net/can/kvaser_pciefd.c index 74d9899fc904..2c98befcf2a0 100644 --- a/drivers/net/can/kvaser_pciefd.c +++ b/drivers/net/can/kvaser_pciefd.c @@ -1304,9 +1304,6 @@ static int kvaser_pciefd_rx_error_frame(struct kvaser_pciefd_can *can, cf->data[6] = bec.txerr; cf->data[7] = bec.rxerr; - stats->rx_packets++; - stats->rx_bytes += cf->len; - netif_rx(skb); return 0; } -- 2.31.1