Skip to content

Commit e8024cb

Browse files
jahurleydavem330
authored andcommitted
nfp: flower: handle neighbour events on internal ports
Recent code changes to NFP allowed the offload of neighbour entries to FW when the next hop device was an internal port. This allows for offload of tunnel encap when the end-point IP address is applied to such a port. Unfortunately, the neighbour event handler still rejects events that are not associated with a repr dev and so the firmware neighbour table may get out of sync for internal ports. Fix this by allowing internal port neighbour events to be correctly processed. Fixes: 45756df ("nfp: flower: allow tunnels to output to internal port") Signed-off-by: John Hurley <[email protected]> Reviewed-by: Simon Horman <[email protected]> Reviewed-by: Jakub Kicinski <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 739d7c5 commit e8024cb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

drivers/net/ethernet/netronome/nfp/flower/tunnel_conf.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -328,13 +328,13 @@ nfp_tun_neigh_event_handler(struct notifier_block *nb, unsigned long event,
328328

329329
flow.daddr = *(__be32 *)n->primary_key;
330330

331-
/* Only concerned with route changes for representors. */
332-
if (!nfp_netdev_is_nfp_repr(n->dev))
333-
return NOTIFY_DONE;
334-
335331
app_priv = container_of(nb, struct nfp_flower_priv, tun.neigh_nb);
336332
app = app_priv->app;
337333

334+
if (!nfp_netdev_is_nfp_repr(n->dev) &&
335+
!nfp_flower_internal_port_can_offload(app, n->dev))
336+
return NOTIFY_DONE;
337+
338338
/* Only concerned with changes to routes already added to NFP. */
339339
if (!nfp_tun_has_route(app, flow.daddr))
340340
return NOTIFY_DONE;

0 commit comments

Comments
 (0)