|SUCCESS| [v4] app/testpmd: fix DCB queue allocation for VMDq devices
dpdklab at iol.unh.edu
dpdklab at iol.unh.edu
Thu Apr 9 15:26:17 CEST 2026
Test-Label: ai-code-review
Test-Status: SUCCESS
https://dpdk.org/patch/162959
_AI Code Review_
=== Patch Review: series.patch (via Claude) ===
Review date: 2026-04-09
sha: <commit sha not provided in patch - reviewing from patch file>
Author: KAVYA AV <kavyax.a.v at intel.com>
Subject: [PATCH v4] app/testpmd: fix DCB queue allocation for VMDq devices
This patch modifies testpmd's DCB queue allocation for VMDq devices
when VT is disabled. It changes the queue count calculation from using
num_tcs to subtracting vmdq_queue_num from max queues.
> diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
> index e2569d9e30..23a27322f8 100644
> --- a/app/test-pmd/testpmd.c
> +++ b/app/test-pmd/testpmd.c
> @@ -4481,8 +4481,11 @@ init_port_dcb_config(portid_t pid,
> nb_rxq = rte_port->dev_info.max_rx_queues;
> nb_txq = rte_port->dev_info.max_tx_queues;
> } else {
> - nb_rxq = (queueid_t)num_tcs;
> - nb_txq = (queueid_t)num_tcs;
> + /* Use PF queue count for DCB-only mode with VMDQ devices */
> + nb_rxq = rte_port->dev_info.max_rx_queues -
> + rte_port->dev_info.vmdq_queue_num;
> + nb_txq = rte_port->dev_info.max_tx_queues -
> + rte_port->dev_info.vmdq_queue_num;
Does this code correctly handle devices where vmdq_queue_num might be
zero? For non-VMDq devices, would this allocation be appropriate, or
should the original num_tcs logic be preserved for that case?
The commit message says "For VMDq devices, use actual VMDq queue layout"
but this code applies the subtraction unconditionally in the else branch.
Should there be a check for whether the device actually has VMDq queues
before changing the allocation strategy?
Does this code handle potential underflow if vmdq_queue_num exceeds
max_rx_queues or max_tx_queues? Should there be validation to ensure the
subtraction results remain positive?
More information about the test-report
mailing list