DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/iavf: fix Rx total stats
@ 2019-12-12 13:49 Jiaqi Min
  2019-12-13  1:23 ` [dpdk-dev] [PATCH v2] " Jiaqi Min
  0 siblings, 1 reply; 4+ messages in thread
From: Jiaqi Min @ 2019-12-12 13:49 UTC (permalink / raw)
  To: dev; +Cc: Jingjing Wu, Wenzhuo Lu, Qiming Yang, Jiaqi Min, stable

Rx total statistics error when packets above
the jumbo frame. The patch fixed the issue.

Fixes: f4a41a6953af ("net/avf: support stats")
Cc: stable@dpdk.org

Signed-off-by: Jiaqi Min <jiaqix.min@intel.com>
---
 drivers/net/iavf/iavf_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c
index a39ba1466..867843205 100644
--- a/drivers/net/iavf/iavf_ethdev.c
+++ b/drivers/net/iavf/iavf_ethdev.c
@@ -1068,7 +1068,7 @@ iavf_dev_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
 	if (ret == 0) {
 		iavf_update_stats(vsi, pstats);
 		stats->ipackets = pstats->rx_unicast + pstats->rx_multicast +
-						pstats->rx_broadcast;
+			pstats->rx_broadcast - pstats->rx_discards;
 		stats->opackets = pstats->tx_broadcast + pstats->tx_multicast +
 						pstats->tx_unicast;
 		stats->imissed = pstats->rx_discards;
-- 
2.17.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-12-13  8:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-12 13:49 [dpdk-dev] [PATCH] net/iavf: fix Rx total stats Jiaqi Min
2019-12-13  1:23 ` [dpdk-dev] [PATCH v2] " Jiaqi Min
2019-12-13  7:16   ` Wu, Jingjing
2019-12-13  7:57     ` Ye Xiaolong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).