dpdk/0474-net-af_xdp-remove-unused-local-statistic.patch

44 lines
1.4 KiB
Diff

From abdabad636a54660f4a260e1e9dc573900582bd4 Mon Sep 17 00:00:00 2001
From: Ciara Loftus <ciara.loftus@intel.com>
Date: Tue, 14 May 2024 08:41:55 +0000
Subject: [PATCH] net/af_xdp: remove unused local statistic
[ upstream commit abdabad636a54660f4a260e1e9dc573900582bd4 ]
The rx_dropped statistic is never incremented so its existence
is pointless. Remove it.
Fixes: f1debd77efaf ("net/af_xdp: introduce AF_XDP PMD")
Cc: stable@dpdk.org
Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/af_xdp/rte_eth_af_xdp.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index 25e67851f6..4b282adb03 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -125,7 +125,6 @@ struct xsk_umem_info {
struct rx_stats {
uint64_t rx_pkts;
uint64_t rx_bytes;
- uint64_t rx_dropped;
uint64_t imissed_offset;
};
@@ -884,7 +883,6 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
stats->ipackets += stats->q_ipackets[i];
stats->ibytes += stats->q_ibytes[i];
- stats->imissed += rxq->stats.rx_dropped;
stats->oerrors += txq->stats.tx_dropped;
fd = process_private->rxq_xsk_fds[i];
ret = fd >= 0 ? getsockopt(fd, SOL_XDP, XDP_STATISTICS,
--
2.33.0