mbox series

[00/10] port: implement output port non-blocking behavior

Message ID 20220805220029.1096212-1-cristian.dumitrescu@intel.com (mailing list archive)
Headers show
Series port: implement output port non-blocking behavior | expand

Message

Dumitrescu, Cristian Aug. 5, 2022, 10 p.m. UTC
In case of blocking behavior, the output port retries sending the
packets that could not be sent successfully. The retry can take place
potentially forever in case the Ethernet device or the ring consumer
are down, which leads to deadlock.

In case of the non-blocking behavior introduced by this series, the
packets that could not be sent successfully are dropped and the
associated drop statistics counters are incremented.

Depends-on: series-24205 ("net/softnic: replace the legacy pipeline with SWX pipeline")

Cristian Dumitrescu (10):
  port: add output port packet drop statistics couters
  port: adjust the sink port counters
  port: rework the Ethernet device output port behavior to non-blocking
  port: free buffered packets on Ethernet device output port free
  port: prevent unnecessary flush for the Ethernet device output port
  port: rework the ring output port behavior to non-blocking
  port: free buffered packets on ring output port free
  port: prevent unnecessary flush for the ring output port
  examples/pipeline: print the output port packet drop counters
  net/softnic: print the output port packet drop counters

 drivers/net/softnic/rte_eth_softnic_cli.c |   4 +
 examples/pipeline/cli.c                   |   4 +
 lib/port/rte_swx_port.h                   |  10 +-
 lib/port/rte_swx_port_ethdev.c            | 117 +++++++++++++++-------
 lib/port/rte_swx_port_ring.c              | 113 ++++++++++++++-------
 lib/port/rte_swx_port_source_sink.c       |   8 +-
 6 files changed, 177 insertions(+), 79 deletions(-)

Comments

Thomas Monjalon Sept. 22, 2022, 2:58 p.m. UTC | #1
06/08/2022 00:00, Cristian Dumitrescu:
> In case of blocking behavior, the output port retries sending the
> packets that could not be sent successfully. The retry can take place
> potentially forever in case the Ethernet device or the ring consumer
> are down, which leads to deadlock.
> 
> In case of the non-blocking behavior introduced by this series, the
> packets that could not be sent successfully are dropped and the
> associated drop statistics counters are incremented.
> 
> Depends-on: series-24205 ("net/softnic: replace the legacy pipeline with SWX pipeline")
> 
> Cristian Dumitrescu (10):
>   port: add output port packet drop statistics couters
>   port: adjust the sink port counters
>   port: rework the Ethernet device output port behavior to non-blocking
>   port: free buffered packets on Ethernet device output port free
>   port: prevent unnecessary flush for the Ethernet device output port
>   port: rework the ring output port behavior to non-blocking
>   port: free buffered packets on ring output port free
>   port: prevent unnecessary flush for the ring output port
>   examples/pipeline: print the output port packet drop counters
>   net/softnic: print the output port packet drop counters

Applied, thanks.