[PATCH] app/testpmd: add padding mode to txonly engine

Stephen Hemminger stephen at networkplumber.org
Fri Jun 12 17:20:05 CEST 2026


On Fri, 12 Jun 2026 15:37:15 +0800
Xingui Yang <yangxingui at huawei.com> wrote:

> Add a new padding mode to the txonly forwarding engine, which allows
> sending packets with configurable small sizes without standard L2/L3
> headers. This is useful for testing NIC padding logic.
> 
> When padding mode is enabled via --tx-pkt-pad-mode flag:
> - l2_len and l3_len are set to 0 instead of standard header lengths
> - Packet data is filled with a static pattern instead of
>   Ethernet/IP/UDP headers
> - Minimum packet length validation is bypassed to allow small
>   packet sizes (e.g., set txpkts 14)
> 
> Signed-off-by: Xingui Yang <yangxingui at huawei.com>
> Signed-off-by: Huisong Li <lihuisong at huawei.com>
> ---

Why add yet another setting to already bloated testpmd command?
Instead I would suggest allowing user to specify any length from
14 up to UINT32_MAX.  The code to format packet would need to
handle it there.


More information about the dev mailing list