[dpdk-stable] [PATCH v2] test: avoid hang if queues are full and Tx fails

Thomas Monjalon thomas at monjalon.net
Fri Nov 12 12:32:00 CET 2021


20/07/2021 18:50, Rakesh Kudurumalla:
> Current pmd_perf_autotest() in continuous mode tries
> to enqueue MAX_TRAFFIC_BURST completely before starting
> the test. Some drivers cannot accept complete
> MAX_TRAFFIC_BURST even though rx+tx desc count can fit it.

Which driver is failing to do so?
Why it cannot enqueue 32 packets?

> This patch changes behaviour to stop enqueuing after few
> retries.

If there is a real limitation, there will be issues in more places
than this test program.
I feel it should be addressed either in the driver or at ethdev level.

[...]
> @@ -480,10 +483,19 @@ main_loop(__rte_unused void *args)
>  			nb_tx = RTE_MIN(MAX_PKT_BURST, num);
>  			nb_tx = rte_eth_tx_burst(portid, 0,
>  						&tx_burst[idx], nb_tx);
> +			if (nb_tx == 0)
> +				retry_cnt++;
>  			num -= nb_tx;
>  			idx += nb_tx;
> +			if (retry_cnt == MAX_RETRY_COUNT) {
> +				retry_cnt = 0;
> +				break;
> +			}





More information about the stable mailing list