Thread (114 messages) 114 messages, 9 authors, 2023-06-09

[dpdk-dev] [PATCH v8 2/5] ethdev: do not use get xstats names by IDs to obtain count

From: Andrew Rybchenko <hidden>
Date: 2021-09-30 16:05:46
Subsystem: library code, the rest · Maintainers: Andrew Morton, Linus Torvalds

Relax requirements on get xstats names by IDs. After the patch
corresponding the driver operation is called with non-NULL ids
and xstats_names parameters only.

Signed-off-by: Andrew Rybchenko <redacted>
---
 lib/ethdev/rte_ethdev.c | 6 ------
 1 file changed, 6 deletions(-)
diff --git a/lib/ethdev/rte_ethdev.c b/lib/ethdev/rte_ethdev.c
index daf5ca9242..e5ddc1b81f 100644
--- a/lib/ethdev/rte_ethdev.c
+++ b/lib/ethdev/rte_ethdev.c
@@ -2866,12 +2866,6 @@ eth_dev_get_xstats_count(uint16_t port_id)
 
 	RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
 	dev = &rte_eth_devices[port_id];
-	if (dev->dev_ops->xstats_get_names_by_id != NULL) {
-		count = (*dev->dev_ops->xstats_get_names_by_id)(dev, NULL,
-				NULL, 0);
-		if (count < 0)
-			return eth_err(port_id, count);
-	}
 	if (dev->dev_ops->xstats_get_names != NULL) {
 		count = (*dev->dev_ops->xstats_get_names)(dev, NULL, 0);
 		if (count < 0)
-- 
2.30.2
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help