From 6d84612124417acbe0bbb0b9952cf3270b3b3a0f Mon Sep 17 00:00:00 2001 From: David Marchand Date: Mon, 4 Mar 2019 12:18:35 +0100 Subject: [PATCH] net/tap: fix RxQ errors stat Transmit errors must not be reported in q_errors[] which is for reception. Fixes: 02f96a0a82d1 ("net/tap: add TUN/TAP device PMD") Cc: stable@dpdk.org Signed-off-by: David Marchand Acked-by: Keith Wiles --- drivers/net/tap/rte_eth_tap.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c index 9dd77311b4..3841842f01 100644 --- a/drivers/net/tap/rte_eth_tap.c +++ b/drivers/net/tap/rte_eth_tap.c @@ -970,10 +970,9 @@ tap_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *tap_stats) for (i = 0; i < imax; i++) { tap_stats->q_opackets[i] = pmd->txq[i].stats.opackets; - tap_stats->q_errors[i] = pmd->txq[i].stats.errs; tap_stats->q_obytes[i] = pmd->txq[i].stats.obytes; tx_total += tap_stats->q_opackets[i]; - tx_err_total += tap_stats->q_errors[i]; + tx_err_total += pmd->txq[i].stats.errs; tx_bytes_total += tap_stats->q_obytes[i]; } -- 2.20.1