mlxsw: Introduce initial XM router support
Status from this message: This series was applied to netdev/net-next.git (refs/heads/master):
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest15 patches 0 repliesApplied 15/15
- v115 patches 3 repliesSuperseded
Changes in v2 from the cover letter
* Patch #13: Fix GENMASK() high bit to build correctly on 32 bits (Jakub)
Patches in v2 All 15 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/15 | mlxsw: reg: Add XM Direct Registerdrivers/ | +271 | 0 replies | Applied |
| 2/15 | mlxsw: reg: Add Router XLT Enable Registerdrivers/ | +44 | 0 replies | Applied |
| 3/15 | mlxsw: spectrum_router: Introduce XM implementation of router low-level opsdrivers/ drivers/ drivers/ +1 more | +250 | 0 replies | Applied |
| 4/15 | mlxsw: pci: Obtain info about ports used by eXtended mezaninedrivers/ drivers/ drivers/ | +49 | 0 replies | Applied |
| 5/15 | mlxsw: Ignore ports that are connected to eXtended mezaninedrivers/ drivers/ drivers/ +1 more | +18 | 0 replies | Applied |
| 6/15 | mlxsw: reg: Add Router XLT M select Registerdrivers/ | +32 | 0 replies | Applied |
| 7/15 | mlxsw: reg: Add XM Lookup Table Query Registerdrivers/ | +63 | 0 replies | Applied |
| 8/15 | mlxsw: spectrum_router: Introduce per-ASIC XM initializationdrivers/ drivers/ drivers/ | +88 | 0 replies | Applied |
| 9/15 | mlxsw: reg: Add XM Router M Table Registerdrivers/ | +31 | 0 replies | Applied |
| 10/15 | mlxsw: spectrum_router_xm: Implement L-value tracking for M-indexdrivers/ drivers/ drivers/ | +205 | 0 replies | Applied |
| 11/15 | mlxsw: reg: Add Router LPM Cache ML Delete Registerdrivers/ | +111 | 0 replies | Applied |
| 12/15 | mlxsw: reg: Add Router LPM Cache Enable Registerdrivers/ | +35 | 0 replies | Applied |
| 13/15 | mlxsw: spectrum_router_xm: Introduce basic XM cache flushingdrivers/ | +291 | 0 replies | Applied |
| 14/15 | mlxsw: spectrum: Set KVH XLT cache mode for Spectrum2/3drivers/ drivers/ drivers/ +1 more | +24 | 0 replies | Applied |
| 15/15 | mlxsw: spectrum_router: Use eXtended mezzanine to offload IPv4 routerdrivers/ drivers/ drivers/ | +11 | 0 replies | Applied |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH net-next v2 00/15] mlxsw: Introduce initial XM router support
From: Ido Schimmel <[email protected]>
This patch set implements initial eXtended Mezzanine (XM) router support.
The XM is an external device connected to the Spectrum-{2,3} ASICs using dedicated Ethernet ports. Its purpose is to increase the number of routes that can be offloaded to hardware. This is achieved by having the ASIC act as a cache that refers cache misses to the XM where the FIB is stored and LPM lookup is performed.
Future patch sets will add more sophisticated cache flushing and selftests that utilize cache counters on the ASIC, which we plan to expose via devlink-metric [1].
Patch set overview:
Patches #1-#2 add registers to insert/remove routes to/from the XM and to enable/disable it. Patch #3 utilizes these registers in order to implement XM-specific router low-level operations.
Patches #4-#5 query from firmware the availability of the XM and the local ports that are used to connect the ASIC to the XM, so that netdevs will not be created for them.
Patches #6-#8 initialize the XM by configuring its cache parameters.
Patch #9-#10 implement cache management, so that LPM lookup will be correctly cached in the ASIC.
Patches #11-#13 implement cache flushing, so that routes insertions/removals to/from the XM will flush the affected entries in the cache.
Patch #14 configures the ASIC to allocate half of its memory for the cache, so that room will be left for other entries (e.g., FDBs, neighbours).
Patch #15 starts using the XM for IPv4 route offload, when available.
v2:
* Patch #13: Fix GENMASK() high bit to build correctly on 32 bits (Jakub)
[1] https://lore.kernel.org/netdev/[email protected]/
Jiri Pirko (15):
mlxsw: reg: Add XM Direct Register
mlxsw: reg: Add Router XLT Enable Register
mlxsw: spectrum_router: Introduce XM implementation of router
low-level ops
mlxsw: pci: Obtain info about ports used by eXtended mezanine
mlxsw: Ignore ports that are connected to eXtended mezanine
mlxsw: reg: Add Router XLT M select Register
mlxsw: reg: Add XM Lookup Table Query Register
mlxsw: spectrum_router: Introduce per-ASIC XM initialization
mlxsw: reg: Add XM Router M Table Register
mlxsw: spectrum_router_xm: Implement L-value tracking for M-index
mlxsw: reg: Add Router LPM Cache ML Delete Register
mlxsw: reg: Add Router LPM Cache Enable Register
mlxsw: spectrum_router_xm: Introduce basic XM cache flushing
mlxsw: spectrum: Set KVH XLT cache mode for Spectrum2/3
mlxsw: spectrum_router: Use eXtended mezzanine to offload IPv4 router
drivers/net/ethernet/mellanox/mlxsw/Makefile | 1 + drivers/net/ethernet/mellanox/mlxsw/cmd.h | 30 + drivers/net/ethernet/mellanox/mlxsw/core.c | 12 + drivers/net/ethernet/mellanox/mlxsw/core.h | 12 +- drivers/net/ethernet/mellanox/mlxsw/minimal.c | 3 +- drivers/net/ethernet/mellanox/mlxsw/pci.c | 33 +- drivers/net/ethernet/mellanox/mlxsw/reg.h | 585 ++++++++++++- .../net/ethernet/mellanox/mlxsw/spectrum.c | 5 + .../ethernet/mellanox/mlxsw/spectrum_router.c | 23 +- .../ethernet/mellanox/mlxsw/spectrum_router.h | 10 + .../mellanox/mlxsw/spectrum_router_xm.c | 812 ++++++++++++++++++ 11 files changed, 1518 insertions(+), 8 deletions(-) create mode 100644 drivers/net/ethernet/mellanox/mlxsw/spectrum_router_xm.c
Signature · 1 line
2.29.2