The DPDK framework reports the queue status, which is stored in
'dev->data->tx_queue_state' and 'dev->data->rx_queue_state' . The state
is currently maintained by the drivers. Users may determine whether
a queue participates in packet forwarding based on the state,
For example,

[1] 5028f207a4fa ("app/testpmd: fix secondary process packet forwarding"
[2] 141a520b35f7 ("app/testpmd: fix primary process not polling all queues")

However, not all drivers correctly report the queue status. This may cause
forwarding problems.

Since it is difficult to modify the queue status of all drivers, we consider
updating the queue status at the framework level. Some drivers support queues
for hairpin, leaving status updating for such queues to the drivers. Some
drivers support deferred_start. Assume that all drivers that support
'deferred_start' can obtain the configuration through 
'rte_eth_tx_queue_info_get'
and 'rte_eth_rx_queue_info_get'. So we can directly update the queue status in
'rte_eth_dev_start' and 'rte_eth_dev_stop'.

This patchset does the follow things:
1. update Rx and Tx queue status in dev_start and dev_stop.
2. implement rxq|txq_info_get ops for drivers supporting deferred start.
3. resubmit the patch [2] and makes some fixes on the patch.

Jie Hai (8):
  lib/ethdev: update Rx and Tx queue status
  net/cpfl: support getting queue information
  net/enetc: save deferred start configuratin for queues
  net/enetc: support getting queue information
  net/failsafe: support getting queue information
  net/fm10k: support getting queue information
  net/idpf: support getting queue information
  app/testpmd: fix primary process not polling all queues

 app/test-pmd/testpmd.c              | 25 ++++++++++++++----
 drivers/net/cpfl/cpfl_ethdev.c      |  2 ++
 drivers/net/cpfl/cpfl_rxtx.c        | 26 +++++++++++++++++++
 drivers/net/cpfl/cpfl_rxtx.h        |  4 +++
 drivers/net/enetc/enetc.h           |  2 ++
 drivers/net/enetc/enetc_ethdev.c    | 26 +++++++++++++++++++
 drivers/net/failsafe/failsafe_ops.c | 24 +++++++++++++++++
 drivers/net/fm10k/fm10k_ethdev.c    | 28 ++++++++++++++++++++
 drivers/net/idpf/idpf_ethdev.c      | 22 ++++++++++++++++
 lib/ethdev/rte_ethdev.c             | 40 +++++++++++++++++++++++++++++
 10 files changed, 194 insertions(+), 5 deletions(-)

-- 
2.30.0

Reply via email to