]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
nfp: flower: ensure deletion of old offloaded MACs
authorJohn Hurley <john.hurley@netronome.com>
Wed, 16 Jan 2019 03:06:56 +0000 (19:06 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 16 Jan 2019 23:23:15 +0000 (15:23 -0800)
commit49402b0b7ff706eba22cb67fe7e2dff9f04ce255
treecede19660d7822b6f6f87efd87f2f4a216520699
parent0115dcc31446adfdce6b37197e988bd4c2b8c6d3
nfp: flower: ensure deletion of old offloaded MACs

When a potential tunnel end point goes down then its MAC address should
not be matchable on the NFP.

Implement a delete message for offloaded MACs and call this on net device
down. While at it, remove the actions on register and unregister netdev
events. A MAC should only be offloaded if the device is up. Note that the
netdev notifier will replay any notifications for UP devices on
registration so NFP can still offload ports that exist before the driver
is loaded. Similarly, devices need to go down before they can be
unregistered so removal of offloaded MACs is only required on down events.

Signed-off-by: John Hurley <john.hurley@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/netronome/nfp/flower/tunnel_conf.c