summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCamelia Groza <camelia.groza@nxp.com>2018-03-14 08:37:31 -0500
committerDavid S. Miller <davem@davemloft.net>2018-03-14 13:16:23 -0400
commite4d1b37c17d000a3da9368a3e260fb9ea4927c25 (patch)
tree45c9fd263f4cb628dac927e46b7ed7fd2cdb0243
parent565186362b73226a288830abe595f05f0cec0bbc (diff)
downloadlinux-stable-e4d1b37c17d000a3da9368a3e260fb9ea4927c25.tar.gz
linux-stable-e4d1b37c17d000a3da9368a3e260fb9ea4927c25.tar.bz2
linux-stable-e4d1b37c17d000a3da9368a3e260fb9ea4927c25.zip
dpaa_eth: increment the RX dropped counter when needed
Signed-off-by: Camelia Groza <camelia.groza@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/freescale/dpaa/dpaa_eth.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
index 627f7f714b18..6c0679fd78b8 100644
--- a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
+++ b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
@@ -2310,8 +2310,10 @@ static enum qman_cb_dqrr_result rx_default_dqrr(struct qman_portal *portal,
skb_len = skb->len;
- if (unlikely(netif_receive_skb(skb) == NET_RX_DROP))
+ if (unlikely(netif_receive_skb(skb) == NET_RX_DROP)) {
+ percpu_stats->rx_dropped++;
return qman_cb_dqrr_consume;
+ }
percpu_stats->rx_packets++;
percpu_stats->rx_bytes += skb_len;