Hi

> -----Original Message-----
> From: Xueming Li <[email protected]>
> Sent: Wednesday, October 20, 2021 15:53
> To: [email protected]; Zhang, Yuying <[email protected]>
> Cc: [email protected]; Jerin Jacob <[email protected]>; Yigit, Ferruh
> <[email protected]>; Andrew Rybchenko
> <[email protected]>; Viacheslav Ovsiienko
> <[email protected]>; Thomas Monjalon <[email protected]>; Lior
> Margalit <[email protected]>; Ananyev, Konstantin
> <[email protected]>; Ajit Khaparde
> <[email protected]>; Li, Xiaoyun <[email protected]>
> Subject: [PATCH v11 4/7] app/testpmd: new parameter to enable shared Rx
> queue
> 
> Adds "--rxq-share=X" parameter to enable shared RxQ, share if device supports,
> otherwise fallback to standard RxQ.
> 
> Share group number grows per X ports. X defaults to MAX, implies all ports 
> join

X defaults to number of probed ports.

> share group 1. Queue ID is mapped equally with shared Rx queue ID.
> 
> Forwarding engine "shared-rxq" should be used which Rx only and update
> stream statistics correctly.
> 
> Signed-off-by: Xueming Li <[email protected]>
> ---
>  app/test-pmd/config.c                 |  7 ++++++-
>  app/test-pmd/parameters.c             | 13 +++++++++++++
>  app/test-pmd/testpmd.c                | 20 +++++++++++++++++---
>  app/test-pmd/testpmd.h                |  2 ++
>  doc/guides/testpmd_app_ug/run_app.rst |  7 +++++++
>  5 files changed, 45 insertions(+), 4 deletions(-)
> 
> diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index
> 2c1b06c544d..fa951a86704 100644
> --- a/app/test-pmd/config.c
> +++ b/app/test-pmd/config.c
<snip>
> @@ -1271,6 +1273,17 @@ launch_args_parse(int argc, char** argv)
>                       }
>                       if (!strcmp(lgopts[opt_idx].name, "txonly-multi-flow"))
>                               txonly_multi_flow = 1;
> +                     if (!strcmp(lgopts[opt_idx].name, "rxq-share")) {
> +                             if (optarg == NULL) {
> +                                     rxq_share = UINT32_MAX;

Why not use "nb_ports" here? nb_ports is the number of probed ports.

> +                             } else {
> +                                     n = atoi(optarg);
> +                                     if (n >= 0)
> +                                             rxq_share = (uint32_t)n;
> +                                     else
> +                                             rte_exit(EXIT_FAILURE, "rxq-
> share must be >= 0\n");
> +                             }
> +                     }
>                       if (!strcmp(lgopts[opt_idx].name, "no-flush-rx"))
>                               no_flush_rx = 1;
>                       if (!strcmp(lgopts[opt_idx].name, "eth-link-speed"))
<snip>
> 
> +*   ``--rxq-share=[X]``
> +
> +    Create queues in shared Rx queue mode if device supports.
> +    Group number grows per X ports. X defaults to MAX, implies all ports

X defaults to number of probed ports.
I suppose this is what you mean? Also, I agree with other comments with the 
wording part.

> +    join share group 1. Forwarding engine "shared-rxq" should be used
> +    which Rx only and update stream statistics correctly.
> +
>  *   ``--eth-link-speed``
> 
>      Set a forced link speed to the ethernet port::
> --
> 2.33.0

Reply via email to