Hi,

On 3/18/2026 2:17 PM, Talluri Chaitanyababu wrote:
> Fix DCB forwarding issues when RX and TX ports are configured with
> different numbers of traffic classes (TCs).

Suggest: Fix DCB forwarding failed when the number of TCs on ports is 
inconsistent.

And RX/TX -> Rx/Tx

> 
> When ports have asymmetric TC configurations (e.g. 4 TCs on RX and 8 TCs
> on TX), the forwarding logic iterates based only on the RX port TC count.

e.g. 4 TCs on RX and 8 TCs on TX
suggest replaced with: e.g. 2 ports, port0 has 4 TCs and port1 has 8 TCs

And suggest add the testpmd command in commit-log like below so that others 
could reproduce:
x86_64-native-linuxapp-gcc/app/dpdk-testpmd -l 1-20 -n 4 -a 0000:31:00.0 -a 
0000:4b:00.0 --file-prefix=testpmd1 -- -i --rxq=256 --txq=256 --nb-cores=16 
--total-num-mbufs=600000
port stop all
port config 0 dcb vt off 8 pfc on
port config 1 dcb vt off 8 pfc on
port start all
port stop all
port config 0 dcb vt off 4 pfc on

> This can lead to accessing invalid TX TC entries and incorrect queue
> mapping, potentially causing multiple threads to operate on the same
> queues.

Suggest: This can lead to accessing invalid TX TC entries and incorrect queue
 mapping and which will result SIGFPE exception.

> 
> Additionally, the existing VMDq pool guard in dcb_fwd_config_setup()
> only checks RX queue counts and does not consider the case where the TX
> port has no queues for a given pool/TC combination.
> 
> Fix this by:
> 1. Introducing an effective TC count using RTE_MIN() of RX and TX TC
>    values, ensuring forwarding only operates on valid TCs supported by
>    both ports.
> 2. Updating the loop condition to use the effective TC count instead of
>    only the RX TC count.
> 3. Extending validation in dcb_fwd_check_cores_per_tc() to ensure both RX
>    and TX queue counts are divisible by dcb_fwd_tc_cores, preventing
>    invalid configurations.

Suggest 1&2 as one commit, and 3 as another commit.

> 
> This ensures correct queue mapping and avoids issues when switching
> between different DCB configurations across ports.
> 
> Fixes: 945e9be0a803 ("app/testpmd: support multi-cores process one TC")

The SIGFPE error was not introduced by this commit as I pointed out in early 
reply to v2.
I just suggest you split two commit, the second commit could adds this fix tag, 
but as the
first commit please find the real commit which introduce the bug.

> Cc: [email protected]
> 
> Signed-off-by: Talluri Chaitanyababu <[email protected]>
> Signed-off-by: Shaiq Wani <[email protected]>
> ---

...

Reply via email to