]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mlxsw: Trap ARP packets at layer 2 instead of layer 3
authorAmit Cohen <amcohen@nvidia.com>
Mon, 17 Mar 2025 17:37:26 +0000 (18:37 +0100)
committerJakub Kicinski <kuba@kernel.org>
Mon, 24 Mar 2025 22:09:30 +0000 (15:09 -0700)
commit6d627a29aab8559858457ada54cc2da4849a4f57
treed8c64258b18a0fed8f6fc986bc4d20875f1886d8
parentc353e8983e0dea5dbba7789033326e1ad34135b7
mlxsw: Trap ARP packets at layer 2 instead of layer 3

Next patch will set the same hardware domain for all bridge ports,
including VXLAN, to prevent packets from being forwarded by software when
they were already forwarded by hardware.

ARP packets are not flooded by hardware to VXLAN, so software should handle
such flooding. When hardware domain of VXLAN device will be changed, ARP
packets which are trapped and marked with offload_fwd_mark will not be
flooded to VXLAN also in software, which will break VXLAN traffic.

To prevent such breaking, trap ARP packets at layer 2 and don't mark them
as L2-forwarded in hardware, then flooding ARP packets will be done only
in software, and VXLAN will send ARP packets.

Remove NVE_ENCAP_ARP which is no longer needed, as now ARP packets are
trapped when they enter the device.

Signed-off-by: Amit Cohen <amcohen@nvidia.com>
Reviewed-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/b2a2cc607a1f4cb96c10bd3b0b0244ba3117fd2e.1742224300.git.petrm@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlxsw/spectrum.c
drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c
drivers/net/ethernet/mellanox/mlxsw/trap.h