Thread (8 messages) flat view 8 messages, 2 authors, 1d ago
WARM1d

Revision v2 of 2 in this series.

Revisions (2)
  1. v1 [diff vs current]
  2. v2 current

[PATCH net-next v2 0/4] net: macb: Add TSN MQPRIO and CBS traffic-class offload

From: Vineeth Karumanchi <hidden>
Date: 2026-09-09 14:21:21
Also in: lkml

This series adds TSN traffic-class hardware offload support to the
Cadence macb/GEM driver, building on the existing TAPRIO/Qbv
infrastructure.

GEM IP versions that implement Qbv (e.g. Versal GEM) also support
additional TSN clauses. The series first generalises the existing Qbv
capability flag into a traffic-class offload flag and centralises the
common ndo_setup_tc() preconditions, then adds two new offloads:

 - MQPRIO: traffic-class to hardware-queue mapping, delegating queue
   count and overlap validation to the mqprio core.

 - CBS (Credit-Based Shaper, IEEE 802.1Qav): per-queue idleslope
   programming on the two highest-priority queues, with the idleslope
   register value derived from the current link speed (full 32-bit
   range for high-speed GEM, port-rate factor for standard GEM).

Patches 1 and 2 are preparatory refactors with no functional change.
Patches 3 and 4 add the MQPRIO and CBS offloads respectively.

Changes in v2:
- CBS: macb_cbs_get_queue_params() now returns the idleslope register
  offset instead of a bool flag, and the idleslope is programmed via
  bp->macb_reg_writel(), dropping the per-queue if/else (patch 4).
- CBS: zero-initialize kset and expand the idleslope conversion
  comment (patch 4).
- Rebased on net-next, which renamed the struct net_device pointer to
  "netdev" (was "dev"/"ndev"); no functional change in patches 1-3.

v1: https://lore.kernel.org/netdev/20260807095012.640223-1-vineeth.karumanchi@amd.com/ (local)

Vineeth Karumanchi (4):
  net: macb: Rename MACB_CAPS_QBV to MACB_CAPS_TC
  net: macb: Move TC capability and PM checks to macb_setup_tc()
  net: macb: Add MQPRIO qdisc hardware offload support
  net: macb: Add TSN CBS TC offload support

 drivers/net/ethernet/cadence/macb.h      |  11 +-
 drivers/net/ethernet/cadence/macb_main.c | 204 +++++++++++++++++++++--
 2 files changed, 201 insertions(+), 14 deletions(-)


base-commit: 548b86839f7fb819a4d6c83b71c73ec378d24275
-- 
2.43.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help