On 11/24/2026 4:09 PM, netd…@kernel.org wrote:
> Thank you for your contribution! Sashiko AI review found 3 potential
> issue(s) to consider.
>
> Critical: 0 · High: 2 · Medium: 1 · Low: 0
>
> If you believe none of the issues are legitimate, please reply to each
> issue of Medium severity or higher and explain why the AI is wrong.
> If any of them are legitimate and you plan to respin, please let patchwork
> know by including "pw-bot: cr" as a separate line at the end of your reply
> (one such reply per series is enough).
>
> - [High] The patch limits the CBS replay in stmmac_configure_cbs()
> (stmmac_main.c:3560) to stmmac_num_tc().
> - [High] The patch limits stmmac_mac_config_tx_queues_prio()
> (stmmac_main.c:3622) to stmmac_num_tc() because TC_PRTY (PSTC) is per…
> - [Medium] The patch is meant to stop the driver assuming one TC per
> queue on XGMAC, but the register that actually assigns a queue to a TC…
>
Hi,
Thanks for the reviews of all three patches. I went through the Medium
and High findings against the code and agree with them. This one reply
covers the reviews of 1/3, 2/3 and 3/3.
They share a single root cause: on this hardware there can be more
queues than traffic classes (for example 12 queues and 8 TCs), while the
driver assumes that queue N is TC N. Raising the queue macros in 3/3
exposes that assumption in the CBS, mqprio, TC priority and queue to TC
map code.
CBS shows it most clearly. The shaper parameters (send and idle slope,
high and low credit) are written to per-TC registers, while the queue
mode (AVB or DCB) is a per-queue setting. With more queues than TCs,
several queues can end up on the same TC. The user names a queue in the
cbs qdisc, so the driver has to work out from that which TC owns the
shaper registers to program, and which of the queues that share the TC
have to be switched to AVB mode. Today the driver only has the
identity mapping (queue N is TC N), so it can program a queue's TC
correctly only when the queue number is below the TC count. Beyond that
it would write TC registers that do not exist.
Fixing this properly needs a defined mapping from queues to TCs. On
Hyper-DMA (DW25GMAC) parts, virtual DMA channels, physical DMA channels
and traffic classes are separate objects that are mapped by the
platform, and several channels can share one TC. The Hyper-DMA support
in the BCM8958x series from Broadcom (v9) uses a 1:1 mapping, so it does
not cover that case:
https://lore.kernel.org/netdev/2026…@broadcom.com/
Rejecting only what does not fit would add checks that get replaced once
a mapping exists, and the series would stay half done. So I am not
going to respin it as it stands. I will rework the series with the
queue to TC mapping designed in, fold in the smaller items from the
reviews and repost.
pw-bot: cr
Regards,
Sagar