Skip to content

Commit 89ab533

Browse files
idoschdavem330
authored andcommitted
mlxsw: spectrum_router: Allow programming link-local host routes
Cited commit added the ability to program link-local prefix routes to the ASIC so that relevant packets are routed and trapped correctly. However, host routes were not included in the change and thus not programmed to the ASIC. This can result in packets being trapped via an external route trap instead of a local route trap as in IPv4. Fix this by programming all the link-local routes to the ASIC. Fixes: 10d3757 ("mlxsw: spectrum_router: Allow programming link-local prefix routes") Reported-by: Alex Veber <[email protected]> Tested-by: Alex Veber <[email protected]> Signed-off-by: Ido Schimmel <[email protected]> Reviewed-by: Jiri Pirko <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 83f3522 commit 89ab533

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5001,15 +5001,6 @@ static void mlxsw_sp_router_fib4_del(struct mlxsw_sp *mlxsw_sp,
50015001

50025002
static bool mlxsw_sp_fib6_rt_should_ignore(const struct fib6_info *rt)
50035003
{
5004-
/* Packets with link-local destination IP arriving to the router
5005-
* are trapped to the CPU, so no need to program specific routes
5006-
* for them. Only allow prefix routes (usually one fe80::/64) so
5007-
* that packets are trapped for the right reason.
5008-
*/
5009-
if ((ipv6_addr_type(&rt->fib6_dst.addr) & IPV6_ADDR_LINKLOCAL) &&
5010-
(rt->fib6_flags & (RTF_LOCAL | RTF_ANYCAST)))
5011-
return true;
5012-
50135004
/* Multicast routes aren't supported, so ignore them. Neighbour
50145005
* Discovery packets are specifically trapped.
50155006
*/

0 commit comments

Comments
 (0)