Skip to content

mlxsw: Add support for blackhole nexthops

Ido Schimmel netdev 1 version Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest10 patches 1 replyApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/10mlxsw: spectrum_router: Create loopback RIF during initializationdrivers/net/ethernet/mellanox/mlxsw/spectrum_router.c drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h+32 -00 replies
2/10mlxsw: spectrum_router: Use different trap identifier for unresolved nexthopsdrivers/net/ethernet/mellanox/mlxsw/spectrum_router.c drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c drivers/net/ethernet/mellanox/mlxsw/trap.h+4 -20 replies
3/10mlxsw: spectrum_router: Use loopback RIF for unresolved nexthopsdrivers/net/ethernet/mellanox/mlxsw/spectrum_router.c+4 -40 replies
4/10mlxsw: spectrum_router: Resolve RIF from nexthop struct instead of neighbourdrivers/net/ethernet/mellanox/mlxsw/spectrum_router.c+1 -10 replies
5/10mlxsw: spectrum_router: Add support for blackhole nexthopsdrivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h+48 -100 replies
6/10selftests: mlxsw: Add blackhole nexthop configuration teststools/testing/selftests/drivers/net/mlxsw/rtnetlink.sh+22 -30 replies
7/10selftests: forwarding: Add blackhole nexthops teststools/testing/selftests/net/forwarding/router_mpath_nh.sh+57 -10 replies
8/10devlink: Add blackhole_nexthop trapDocumentation/networking/devlink/devlink-trap.rst include/net/devlink.h net/core/devlink.c+8 -10 replies
9/10mlxsw: spectrum_trap: Add blackhole_nexthop trapdrivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c+6 -00 replies
10/10selftests: mlxsw: Add blackhole_nexthop trap testtools/testing/selftests/drivers/net/mlxsw/devlink_trap_l3_drops.sh+36 -00 replies

Reviews trailers per patch

7 of 10 patches have a Reviewed-by or Acked-by.

PatchJiri Pirko
1/10R-b
2/10R-b
3/10R-b
4/10R-b
5/10R-b
6/10
7/10
8/10R-b
9/10R-b
10/10

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 00/10] mlxsw: Add support for blackhole nexthops

From: Ido Schimmel <[email protected]>

This patch set adds support for blackhole nexthops in mlxsw. These nexthops are exactly the same as other nexthops, but instead of forwarding packets to an egress router interface (RIF), they are programmed to silently drop them.

Patches #1-#4 are preparations.

Patch #5 adds support for blackhole nexthops and removes the check that prevented them from being programmed.

Patch #6 adds a selftests over mlxsw which tests that blackhole nexthops can be programmed and are marked as offloaded.

Patch #7 extends the existing nexthop forwarding test to also test blackhole functionality.

Patches #8-#10 add support for a new packet trap ('blackhole_nexthop') which should be triggered whenever packets are dropped by a blackhole nexthop. Obviously, by default, the trap action is set to 'drop' so that dropped packets will not be reported.

Ido Schimmel (10):
mlxsw: spectrum_router: Create loopback RIF during initialization
mlxsw: spectrum_router: Use different trap identifier for unresolved
nexthops
mlxsw: spectrum_router: Use loopback RIF for unresolved nexthops
mlxsw: spectrum_router: Resolve RIF from nexthop struct instead of
neighbour
mlxsw: spectrum_router: Add support for blackhole nexthops
selftests: mlxsw: Add blackhole nexthop configuration tests
selftests: forwarding: Add blackhole nexthops tests
devlink: Add blackhole_nexthop trap
mlxsw: spectrum_trap: Add blackhole_nexthop trap
selftests: mlxsw: Add blackhole_nexthop trap test

 .../networking/devlink/devlink-trap.rst       |  4 +
 .../ethernet/mellanox/mlxsw/spectrum_dpipe.c  |  9 +-
 .../ethernet/mellanox/mlxsw/spectrum_router.c | 92 ++++++++++++++++---
 .../ethernet/mellanox/mlxsw/spectrum_router.h |  2 +
 .../ethernet/mellanox/mlxsw/spectrum_trap.c   |  8 +-
 drivers/net/ethernet/mellanox/mlxsw/trap.h    |  1 +
 include/net/devlink.h                         |  4 +-
 net/core/devlink.c                            |  1 +
 .../net/mlxsw/devlink_trap_l3_drops.sh        | 36 ++++++++
 .../selftests/drivers/net/mlxsw/rtnetlink.sh  | 25 ++++-
 .../net/forwarding/router_mpath_nh.sh         | 58 +++++++++++-
 11 files changed, 218 insertions(+), 22 deletions(-)
Signature · 1 line
2.28.0