From: Andrew Rybchenko Date: Wed, 16 Jan 2019 09:43:23 +0000 (+0000) Subject: net/sfc: fix VF error/missed stats mapping X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=24f8a95917b36b313a49bd604c3958f992893efd;p=dpdk.git net/sfc: fix VF error/missed stats mapping VADAPTER_RX_OVERFLOW means Rx statistics overflow, not a missed packet because of overflow. VADAPTER_RX_BAD_PACKETS accumulates a number of error conditions, but mainly impossibility to deliver because of no descriptors available, so it is better to classify it as imissed. Fixes: 1caab2f1e684 ("net/sfc: add basic statistics") Cc: stable@dpdk.org Signed-off-by: Andrew Rybchenko --- diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c index 3886daf7ad..9f59c8db9e 100644 --- a/drivers/net/sfc/sfc_ethdev.c +++ b/drivers/net/sfc/sfc_ethdev.c @@ -537,8 +537,7 @@ sfc_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats) mac_stats[EFX_MAC_VADAPTER_TX_UNICAST_BYTES] + mac_stats[EFX_MAC_VADAPTER_TX_MULTICAST_BYTES] + mac_stats[EFX_MAC_VADAPTER_TX_BROADCAST_BYTES]; - stats->imissed = mac_stats[EFX_MAC_VADAPTER_RX_OVERFLOW]; - stats->ierrors = mac_stats[EFX_MAC_VADAPTER_RX_BAD_PACKETS]; + stats->imissed = mac_stats[EFX_MAC_VADAPTER_RX_BAD_PACKETS]; stats->oerrors = mac_stats[EFX_MAC_VADAPTER_TX_BAD_PACKETS]; } else { stats->ipackets = mac_stats[EFX_MAC_RX_PKTS];