summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main_dpdk.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main_dpdk.cpp b/src/main_dpdk.cpp
index 1f415958..a70f4d31 100644
--- a/src/main_dpdk.cpp
+++ b/src/main_dpdk.cpp
@@ -5110,11 +5110,12 @@ int CTRexExtendedDriverBase40G::configure_rx_filter_rules(CPhyEthIF * _if) {
int CTRexExtendedDriverBase40G::reset_rx_stats(CPhyEthIF * _if, uint32_t *stats) {
uint32_t diff_stats[MAX_FLOW_STATS];
+ uint32_t diff_bytes[MAX_FLOW_STATS];
// The HW counters start from some random values. The driver give us the diffs from previous,
// each time we do get_rx_stats. We need to make one first call, at system startup,
// and ignore the returned diffs
- return get_rx_stats(_if, diff_stats, stats, NULL, NULL, 0, MAX_FLOW_STATS - 1);
+ return get_rx_stats(_if, diff_stats, stats, diff_bytes, NULL, 0, MAX_FLOW_STATS - 1);
}
// instead of adding this to rte_ethdev.h
@@ -5141,6 +5142,7 @@ int CTRexExtendedDriverBase40G::get_rx_stats(CPhyEthIF * _if, uint32_t *pkts, ui
pkts[i] = (uint64_t)((hw_stats[i - min] + ((uint64_t)1 << 32)) - prev_pkts[i]);
}
prev_pkts[i] = hw_stats[i - min];
+ bytes[i] = 0;
}
return 0;