Skip to content

qdisc RED offload

Jiri Pirko netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest9 patches 5 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9net_sch: red: Add offload ability to RED qdiscinclude/linux/netdevice.h include/net/pkt_cls.h include/uapi/linux/pkt_sched.h +1 more+111 -01 reply
2/9net_sch: mqprio: Change TC_SETUP_MQPRIO to TC_SETUP_QDISC_MQPRIOdrivers/net/ethernet/amd/xgbe/xgbe-drv.c drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c drivers/net/ethernet/broadcom/bnxt/bnxt.c +12 more+17 -161 reply
3/9net_sch: cbs: Change TC_SETUP_CBS to TC_SETUP_QDISC_CBSdrivers/net/ethernet/intel/igb/igb_main.c include/linux/netdevice.h net/sched/sch_cbs.c+4 -42 replies
4/9mlxsw: reg: Add cwtp & cwtpm registersdrivers/net/ethernet/mellanox/mlxsw/reg.h+187 -00 replies
5/9mlxsw: spectrum: Support RED qdisc offloaddrivers/net/ethernet/mellanox/mlxsw/Makefile drivers/net/ethernet/mellanox/mlxsw/spectrum.c drivers/net/ethernet/mellanox/mlxsw/spectrum.h +1 more+193 -10 replies
6/9mlxsw: reg: Add ext and tc-cong counter groupsdrivers/net/ethernet/mellanox/mlxsw/reg.h+19 -00 replies
7/9mlxsw: spectrum: Collect tclass related stats periodicallydrivers/net/ethernet/mellanox/mlxsw/spectrum.c drivers/net/ethernet/mellanox/mlxsw/spectrum.h+43 -00 replies
8/9mlxsw: spectrum: Support RED xstatsdrivers/net/ethernet/mellanox/mlxsw/spectrum.h drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c+60 -00 replies
9/9mlxsw: spectrum: Support general qdisc statsdrivers/net/ethernet/mellanox/mlxsw/spectrum.h drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c+56 -00 replies

Reviews trailers per patch

3 of 9 patches have a Reviewed-by or Acked-by.

PatchSimon HormanVinicius Costa Gomes
1/9R-b
2/9R-b
3/9R-b A-b
4/9
5/9
6/9
7/9
8/9
9/9

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [patch net-next 0/9] qdisc RED offload

From: Jiri Pirko <[email protected]>

Nogah says:

Add an offload support for RED qdisc for mlxsw driver.
The first patch adds the ability to offload RED qdisc by using ndo_setup_tc. It gives RED three commands, to offload, change or delete the qdisc, to get the qdisc generic stats and to get it's RED xstats. There is no enforcement on a driver to offload or not offload the qdisc and it is up to the driver to decide.
RED qdisc is first being created and only later graft to a parent (unless it is a root qdisc). For that reason the return value of the offload replace command that is called in the init process doesn't reflect actual offload state. The offload state is determined in the dump function so it can be reflected to the user. This function is also responsible for stats update.

The patchses 2-3 change the name of TC_SETUP_MQPRIO & TC_SETUP_CBS to match with the new convention of QDISC prefix.
The rest of the patchset is driver support for the qdisc. Currently only as root qdisc that is being set on the default traffic class. It supports only the following parameters of RED: min, max, probability and ECN mode. Limit and burst size related params are being ignored at this moment.

---
v7->v8 internal: (external RFC->v1)
- patch 1/9:
- unite the offload and un-offload functions
- clean the OFFLOAD flag when the qdisc in not offloaded
- patch 2/9:
- minor change to avoid a conflict
- patch 5/9:
- check for bad min/max values
- clean the offloaded qdisc after a bad config call

Nogah Frankel (8):
net_sch: red: Add offload ability to RED qdisc
net_sch: mqprio: Change TC_SETUP_MQPRIO to TC_SETUP_QDISC_MQPRIO
net_sch: cbs: Change TC_SETUP_CBS to TC_SETUP_QDISC_CBS
mlxsw: reg: Add cwtp & cwtpm registers
mlxsw: spectrum: Support RED qdisc offload
mlxsw: spectrum: Collect tclass related stats periodically
mlxsw: spectrum: Support RED xstats
mlxsw: spectrum: Support general qdisc stats

Yuval Mintz (1):
mlxsw: reg: Add ext and tc-cong counter groups

 drivers/net/ethernet/amd/xgbe/xgbe-drv.c           |   2 +-
 drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c    |   2 +-
 drivers/net/ethernet/broadcom/bnxt/bnxt.c          |   2 +-
 drivers/net/ethernet/freescale/dpaa/dpaa_eth.c     |   2 +-
 .../net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c |   2 +-
 drivers/net/ethernet/intel/fm10k/fm10k_netdev.c    |   2 +-
 drivers/net/ethernet/intel/i40e/i40e_main.c        |   2 +-
 drivers/net/ethernet/intel/igb/igb_main.c          |   2 +-
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c      |   2 +-
 drivers/net/ethernet/mellanox/mlx4/en_netdev.c     |   2 +-
 drivers/net/ethernet/mellanox/mlx5/core/en_main.c  |   2 +-
 drivers/net/ethernet/mellanox/mlxsw/Makefile       |   3 +-
 drivers/net/ethernet/mellanox/mlxsw/reg.h          | 206 +++++++++++++++
 drivers/net/ethernet/mellanox/mlxsw/spectrum.c     |  36 +++
 drivers/net/ethernet/mellanox/mlxsw/spectrum.h     |  38 +++
 .../net/ethernet/mellanox/mlxsw/spectrum_qdisc.c   | 276 +++++++++++++++++++++
 drivers/net/ethernet/sfc/falcon/tx.c               |   2 +-
 drivers/net/ethernet/sfc/tx.c                      |   2 +-
 drivers/net/ethernet/ti/netcp_core.c               |   2 +-
 include/linux/netdevice.h                          |   5 +-
 include/net/pkt_cls.h                              |  30 +++
 include/uapi/linux/pkt_sched.h                     |   1 +
 net/sched/sch_cbs.c                                |   4 +-
 net/sched/sch_mqprio.c                             |   5 +-
 net/sched/sch_red.c                                |  79 ++++++
 25 files changed, 690 insertions(+), 21 deletions(-)
 create mode 100644 drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c
Signature · 1 line
2.9.5