Skip to content

per-queue statistics changes

Stephen Hemminger dpdk-dev 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest16 patches 3 repliesIn review
  2. v316 patches 0 repliesSuperseded
  3. v29 patches 8 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v1 RFC7 patches2 repliesSuperseded

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/16net/virtio: remove unused queue stats mappingdrivers/net/virtio/virtio_ethdev.c+0 -210 replies
2/16app/testpmd: remove leftover set qmapapp/test-pmd/cmdline.c app/test-pmd/testpmd.h doc/guides/testpmd_app_ug/testpmd_funcs.rst+0 -190 replies
3/16net/enic: remove unneeded ops initializationdrivers/net/enic/enic_ethdev.c+0 -110 replies
4/16net/cnxk: fix Tx drops added to Rx queue errorsdrivers/net/cnxk/cnxk_stats.c+1 -20 replies
5/16net/cnxk: remove queue stats mappingdrivers/net/cnxk/cnxk_ethdev.c drivers/net/cnxk/cnxk_ethdev.h drivers/net/cnxk/cnxk_stats.c+29 -510 replies
6/16net/e1000: remove queue stats mappingdrivers/net/intel/e1000/igc_ethdev.c drivers/net/intel/e1000/igc_ethdev.h+8 -501 reply
7/16net/ixgbe: remove queue stats mappingdrivers/net/intel/ixgbe/ixgbe_ethdev.c drivers/net/intel/ixgbe/ixgbe_ethdev.h+2 -1051 reply
8/16net/txgbe: remove queue stats mappingdrivers/net/txgbe/txgbe_ethdev.c drivers/net/txgbe/txgbe_ethdev.h+7 -930 replies
9/16net/sxe2: fix null dereference in stats getdrivers/net/sxe2/sxe2_mp.c drivers/net/sxe2/sxe2_stats.c+7 -40 replies
10/16net/sxe2: remove queue stats mappingdrivers/net/sxe2/sxe2_cmd_chnl.c drivers/net/sxe2/sxe2_cmd_chnl.h drivers/net/sxe2/sxe2_ethdev.c +4 more+24 -1960 replies
11/16ethdev: remove support for queue stats mappingdoc/guides/nics/features.rst doc/guides/rel_notes/deprecation.rst doc/guides/rel_notes/release_26_11.rst +5 more+5 -1570 replies
12/16net/mvpp2: fix out of range Tx queue stats writedrivers/net/mvpp2/mrvl_ethdev.c+1 -00 replies
13/16net/ntnic: fix Tx errors reported as Rx queue errorsdrivers/net/ntnic/ntnic_ethdev.c+0 -10 replies
14/16net/xsc: fix Tx errors added to Rx queue errorsdrivers/net/xsc/xsc_ethdev.c+0 -10 replies
15/16ethdev: remove queue stats counter limitdoc/guides/howto/debug_troubleshoot.rst doc/guides/nics/bnxt.rst doc/guides/nics/features.rst +62 more+445 -5221 reply
16/16test/pmd_ring: test per-queue xstatsapp/test/test_pmd_ring.c+145 -00 replies

Reviews trailers per patch

5 of 16 patches have a Reviewed-by or Acked-by.

PatchHyong Youb KimChengwen FengAndrew RybchenkoLong LiBruce Richardson
1/16
2/16
3/16A-b
4/16
5/16
6/16A-b
7/16A-b
8/16
9/16
10/16
11/16A-b A-b
12/16
13/16
14/16
15/16R-b
16/16

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 5 reviewers.

Read the v4 thread

Cover letter [PATCH v4 00/16] per-queue statistics changes

This series completes the removal of the per-queue stats mapping and the RTE_ETHDEV_QUEUE_STAT_CNTRS definition.

The mapping mechanism (rte_eth_dev_set_{rx,tx}_queue_stats_mapping and the queue_stats_mapping_set ethdev op) was a workaround for hardware that could only expose a limited number of queue stat registers. It let an application fold many queues onto a small set of counters. Since 25.11 queue statistics are filled in directly by the ethdev layer indexed by queue id, so the mapping is no longer needed; the functions were deprecated then by commit 2863cbd9ee6d.

The large patch is the tree wide removal of RTE_ETHDEV_QUEUE_STAT_CNTRS. Instead ethdev allocates the temporary qstats array from the number of queues the device reports, before querying the driver. Error counters are no longer per-queue since that wasn't that helpful; they are global now. The mapping of per-queue stats into xstats is unchanged and the user visible xstats stay the same, so the impact is limited to the driver API.

Several bugs turned up along the way and are split out as their own fixes with Fixes: and Cc: stable tags where they apply to released code.

A test for per-queue statistics is added to the pmd_ring test so this path has coverage.

v4
- work around RTE_MIN() not being treated as a constant expression by gcc, which turned an array declaration into a VLA
- drop RTE_MIN4() and open code the comparison in bnxt instead
- fix a couple of other bugs found in bnxt and zxdh
- keep the ixgbe queue stats mapping registers programmed the same way as before this series, rather than changing what the hardware counters measure

v3
- split the sxe2 null dereference into its own fix ahead of the rework
- size the sxe2 multi-process shared qstats array for every queue the primary may write
- reorder the cnxk fix ahead of the cnxk rework so it backports

Stephen Hemminger (16):
net/virtio: remove unused queue stats mapping app/testpmd: remove leftover set qmap net/enic: remove unneeded ops initialization net/cnxk: fix Tx drops added to Rx queue errors net/cnxk: remove queue stats mapping net/e1000: remove queue stats mapping net/ixgbe: remove queue stats mapping net/txgbe: remove queue stats mapping net/sxe2: fix null dereference in stats get net/sxe2: remove queue stats mapping
ethdev: remove support for queue stats mapping net/mvpp2: fix out of range Tx queue stats write net/ntnic: fix Tx errors reported as Rx queue errors net/xsc: fix Tx errors added to Rx queue errors
ethdev: remove queue stats counter limit test/pmd_ring: test per-queue xstats

 app/test-pmd/cmdline.c                        |   6 -
 app/test-pmd/testpmd.h                        |   2 -
 app/test/test_pmd_ring.c                      | 145 ++++++++++++++++++
 doc/guides/howto/debug_troubleshoot.rst       |   5 +-
 doc/guides/nics/bnxt.rst                      |   4 +-
 doc/guides/nics/features.rst                  |  12 +-
 doc/guides/rel_notes/deprecation.rst          |   6 -
 doc/guides/rel_notes/release_26_11.rst        |   9 ++
 doc/guides/testpmd_app_ug/testpmd_funcs.rst   |  11 --
 drivers/net/af_packet/rte_eth_af_packet.c     |  15 +-
 drivers/net/af_xdp/rte_eth_af_xdp.c           |  13 +-
 drivers/net/ark/ark_ethdev_rx.c               |   7 +-
 drivers/net/ark/ark_ethdev_tx.c               |   6 +-
 drivers/net/atlantic/atl_ethdev.c             |  13 +-
 drivers/net/atlantic/atl_rxtx.c               |   8 +-
 drivers/net/atlantic/atl_types.h              |  15 +-
 drivers/net/avp/avp_ethdev.c                  |  13 +-
 drivers/net/axgbe/axgbe_ethdev.c              |  13 +-
 drivers/net/bnxt/bnxt_ethdev.c                |   5 -
 drivers/net/bnxt/bnxt_reps.c                  |   9 +-
 drivers/net/bnxt/bnxt_stats.c                 |  40 ++---
 drivers/net/cnxk/cnxk_ethdev.c                |   1 -
 drivers/net/cnxk/cnxk_ethdev.h                |   6 -
 drivers/net/cnxk/cnxk_rep_ops.c               |   8 +-
 drivers/net/cnxk/cnxk_stats.c                 |  67 +++-----
 drivers/net/dpaa2/dpaa2_ethdev.c              |  17 +-
 drivers/net/ena/ena_ethdev.c                  |  21 +--
 drivers/net/enic/enic_ethdev.c                |  11 --
 drivers/net/hinic/hinic_pmd_ethdev.c          |  17 +-
 drivers/net/hinic3/hinic3_ethdev.c            |  13 +-
 drivers/net/intel/e1000/igc_ethdev.c          |  57 ++-----
 drivers/net/intel/e1000/igc_ethdev.h          |   2 -
 drivers/net/intel/fm10k/fm10k_ethdev.c        |  16 +-
 drivers/net/intel/ixgbe/ixgbe_ethdev.c        | 112 ++------------
 drivers/net/intel/ixgbe/ixgbe_ethdev.h        |   9 --
 drivers/net/ionic/ionic_lif.c                 |  24 +--
 drivers/net/mana/mana.c                       |  12 +-
 drivers/net/memif/rte_eth_memif.c             |  16 +-
 drivers/net/mlx4/mlx4_ethdev.c                |  14 +-
 drivers/net/mlx5/mlx5_rx.h                    |   3 +-
 drivers/net/mlx5/mlx5_stats.c                 |  22 ++-
 drivers/net/mvpp2/mrvl_ethdev.c               |  21 ++-
 drivers/net/nbl/nbl_dev/nbl_dev.c             |   2 -
 drivers/net/nbl/nbl_hw/nbl_txrx.c             |  12 +-
 drivers/net/netvsc/hn_ethdev.c                |  12 +-
 drivers/net/netvsc/hn_vf.c                    |   3 +-
 drivers/net/nfb/nfb_stats.c                   |  12 +-
 drivers/net/nfp/flower/nfp_flower.c           |   8 +-
 .../net/nfp/flower/nfp_flower_representor.c   |  32 ++--
 .../net/nfp/flower/nfp_flower_representor.h   |   4 +-
 drivers/net/nfp/nfp_ethdev.c                  |  13 ++
 drivers/net/nfp/nfp_ethdev_vf.c               |  13 ++
 drivers/net/nfp/nfp_net_common.c              |  36 ++---
 drivers/net/nfp/nfp_net_common.h              |   3 +-
 drivers/net/ngbe/ngbe_ethdev.c                |  34 +---
 drivers/net/ngbe/ngbe_ethdev.h                |  12 --
 drivers/net/ntnic/ntnic_ethdev.c              |  13 +-
 drivers/net/null/rte_eth_null.c               |  12 +-
 drivers/net/octeon_ep/otx_ep_ethdev.c         |  13 +-
 drivers/net/pcap/pcap_ethdev.c                |  14 +-
 drivers/net/qede/qede_ethdev.c                |  36 +----
 drivers/net/ring/rte_eth_ring.c               |  10 +-
 drivers/net/rnp/rnp_ethdev.c                  |  12 +-
 drivers/net/sxe2/sxe2_cmd_chnl.c              | 119 ++------------
 drivers/net/sxe2/sxe2_cmd_chnl.h              |  10 --
 drivers/net/sxe2/sxe2_ethdev.c                |   5 -
 drivers/net/sxe2/sxe2_mp.c                    |  17 +-
 drivers/net/sxe2/sxe2_mp.h                    |   7 +-
 drivers/net/sxe2/sxe2_stats.c                 |  84 +---------
 drivers/net/sxe2/sxe2_stats.h                 |   5 -
 drivers/net/tap/rte_eth_tap.c                 |  12 +-
 drivers/net/thunderx/nicvf_ethdev.c           |  24 +--
 drivers/net/txgbe/txgbe_ethdev.c              |  89 +----------
 drivers/net/txgbe/txgbe_ethdev.h              |  13 --
 drivers/net/vhost/rte_eth_vhost.c             |  14 +-
 drivers/net/virtio/virtio_ethdev.c            |  33 +---
 drivers/net/vmxnet3/vmxnet3_ethdev.c          |  13 +-
 drivers/net/xsc/xsc_ethdev.c                  |  15 +-
 drivers/net/zxdh/zxdh_ethdev_ops.c            |  24 +--
 lib/ethdev/ethdev_driver.h                    |  38 ++---
 lib/ethdev/ethdev_private.c                   |   2 -
 lib/ethdev/ethdev_trace.h                     |  20 ---
 lib/ethdev/ethdev_trace_points.c              |   6 -
 lib/ethdev/rte_ethdev.c                       | 128 +++++-----------
 lib/ethdev/rte_ethdev.h                       |  45 ------
 85 files changed, 648 insertions(+), 1207 deletions(-)
Signature · 1 line
2.53.0