summaryrefslogtreecommitdiff
path: root/drivers/net/can/sun4i_can.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/can/sun4i_can.c')
-rw-r--r--drivers/net/can/sun4i_can.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/net/can/sun4i_can.c b/drivers/net/can/sun4i_can.c
index 37862e7f6840..a2d8d77d11ef 100644
--- a/drivers/net/can/sun4i_can.c
+++ b/drivers/net/can/sun4i_can.c
@@ -633,13 +633,10 @@ static int sun4i_can_err(struct net_device *dev, u8 isrc, u8 status)
can_bus_off(dev);
}
- if (likely(skb)) {
- stats->rx_packets++;
- stats->rx_bytes += cf->len;
+ if (likely(skb))
netif_rx(skb);
- } else {
+ else
return -ENOMEM;
- }
return 0;
}