[RFC PATCH v2 0/5] Split driver specific commands out of testpmd

David Marchand david.marchand at redhat.com
Wed May 18 21:46:44 CEST 2022


Hello,

Following TB decision and recent discussions on the driver specific
commands in testpmd, here is a proposal on how the split could be done.

For now, this series simply moves the testpmd code in the driver
directory. The driver specific testpmd code is still compiled as part of
testpmd compilation via a global meson testpmd_driver_sources list.

TODO:
- ixgbe bypass commands in testpmd are "dead" code since switch to meson,
  as the RTE_LIBRTE_IXGBE_BYPASS define is not set while compiling testpmd.
  I am tempted to simply drop those, since no one complained about issue
  for the last two years. For now, this series reinstates them.

- this series keeps the command names as is. We could consolidate with a
  clear prefix so that users directly know they are exerting a special
  feature that makes no sense on other hw.
  For this, I had in mind introducing a "driver" top level prefix,
  where drivers would hook their specific stuff. For example:
  testpmd> driver ixgbe set vf split drop (port_id) (vf_id) (on|off)

- the documentation of those commands is left untouched, we should
  probably move any existing doc into the driver documentation itself.
  testpmd documentation could then have a generic
  "Driver specific commands" section pointing at all other driver docs.

Opinions?


-- 
David Marchand

Changes since RFC v1:
- added a cleanup as patch 1, to make all parser symbols static,
- fixed registering issue in patch 1,
- moved more i40e specific commands, fixed checkpatch warnings,

David Marchand (5):
  app/testpmd: mark cmdline symbols as static
  app/testpmd: register driver specific commands
  net/bonding: move testpmd commands
  net/i40e: move testpmd commands
  net/ixgbe: move testpmd commands

 app/test-pmd/cmdline.c                     | 15402 +++++++------------
 app/test-pmd/config.c                      |    43 -
 app/test-pmd/meson.build                   |     8 +-
 app/test-pmd/testpmd.c                     |    18 +-
 app/test-pmd/testpmd.h                     |    23 +-
 drivers/meson.build                        |     5 +
 drivers/net/bonding/meson.build            |     1 +
 drivers/net/bonding/rte_eth_bond_testpmd.c |  1037 ++
 drivers/net/i40e/i40e_testpmd.c            |  2718 ++++
 drivers/net/i40e/meson.build               |     2 +
 drivers/net/ixgbe/ixgbe_testpmd.c          |  1147 ++
 drivers/net/ixgbe/meson.build              |     2 +
 meson.build                                |     2 +
 13 files changed, 10272 insertions(+), 10136 deletions(-)
 create mode 100644 drivers/net/bonding/rte_eth_bond_testpmd.c
 create mode 100644 drivers/net/i40e/i40e_testpmd.c
 create mode 100644 drivers/net/ixgbe/ixgbe_testpmd.c

-- 
2.36.1



More information about the dev mailing list