> From: Kozak, KubaX > Sent: Thursday, April 13, 2017 3:59 PM > To: [email protected] > Cc: Van Haaren, Harry <[email protected]>; Jain, Deepak K > <[email protected]>; > Piasecki, JacekX <[email protected]>; Kozak, KubaX > <[email protected]>; Kulasek, > TomaszX <[email protected]> > Subject: [PATCH v6 1/5] ethdev: new xstats API add retrieving by ID > > From: Jacek Piasecki <[email protected]> > > Extended xstats API in ethdev library to allow grouping of stats > logically so they can be retrieved per logical grouping managed > by the application. > Changed existing functions rte_eth_xstats_get_names and > rte_eth_xstats_get to use a new list of arguments: array of ids > and array of values. ABI versioning mechanism was used to > support backward compatibility. > Introduced two new functions rte_eth_xstats_get_all and > rte_eth_xstats_get_names_all which keeps functionality of the > previous ones (respectively rte_eth_xstats_get and > rte_eth_xstats_get_names) but use new API inside. > > test-pmd: add support for new xstats API retrieving by id in > testpmd application: xstats_get() and > xstats_get_names() call with modified parameters. > > doc: add description for modified xstats API > Documentation change for modified extended statistics API functions. > The old API only allows retrieval of *all* of the NIC statistics > at once. Given this requires a MMIO read PCI transaction per statistic > it is an inefficient way of retrieving just a few key statistics. > Often a monitoring agent only has an interest in a few key statistics, > and the old API forces wasting CPU time and PCIe bandwidth in retrieving > *all* statistics; even those that the application didn't explicitly > show an interest in. > The new, more flexible API allow retrieval of statistics per ID. > If a PMD wishes, it can be implemented to read just the required > NIC registers. As a result, the monitoring application no longer wastes > PCIe bandwidth and CPU time. > > Signed-off-by: Jacek Piasecki <[email protected]> > Signed-off-by: Kuba Kozak <[email protected]> > Signed-off-by: Tomasz Kulasek <[email protected]>
Acked-by: Harry van Haaren <[email protected]>

