On 11/2/2023 12:16 PM, Huisong Li wrote:
> Add maximum Rx buffer size display.
> 

I think there is a value to show what is the intended usage of this new
field in application level,
that is why what do you think to use testpmd?

Testpmd can be updated to check if mbuf data size is bigger than device
buffer size, and just log, similar to done in ethdev layer, just to
showcase how application should use it.

For many drivers, this won't have anything functional, because of
UINT32_MAX size, but it is still valuable as sample.


> Signed-off-by: Huisong Li <lihuis...@huawei.com>
> Acked-by: Chengwen Feng <fengcheng...@huawei.com>
> ---
>  app/test-pmd/config.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
> index b9fdb7e8f1..2ac6f15773 100644
> --- a/app/test-pmd/config.c
> +++ b/app/test-pmd/config.c
> @@ -881,6 +881,8 @@ port_infos_display(portid_t port_id)
>       }
>  
>       printf("Minimum size of RX buffer: %u\n", dev_info.min_rx_bufsize);
> +     if (dev_info.max_rx_bufsize != UINT32_MAX)
> +             printf("Maximum size of RX buffer: %u\n", 
> dev_info.max_rx_bufsize);
>       printf("Maximum configurable length of RX packet: %u\n",
>               dev_info.max_rx_pktlen);
>       printf("Maximum configurable size of LRO aggregated packet: %u\n",

Reply via email to