Skip to content

Commit caf345a

Browse files
idoschdavem330
authored andcommitted
mlxsw: spectrum_router: Add neighbour offload indication
In a similar fashion to routes and FDB entries, the neighbour table is reflected to the device. Set an offload indication on the neighbour in case it was programmed to the device. Signed-off-by: Ido Schimmel <[email protected]> Acked-by: Jiri Pirko <[email protected]> Reviewed-by: David Ahern <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent a85e84e commit caf345a

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

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

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2444,7 +2444,13 @@ mlxsw_sp_neigh_entry_update(struct mlxsw_sp *mlxsw_sp,
24442444
return;
24452445
} else {
24462446
WARN_ON_ONCE(1);
2447+
return;
24472448
}
2449+
2450+
if (adding)
2451+
neigh_entry->key.n->flags |= NTF_OFFLOADED;
2452+
else
2453+
neigh_entry->key.n->flags &= ~NTF_OFFLOADED;
24482454
}
24492455

24502456
void

0 commit comments

Comments
 (0)