diff options
author | Petr Machata <petrm@mellanox.com> | 2017-11-28 13:17:14 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-11-28 09:55:48 -0500 |
commit | 09dbf6297fa8bb4433d9293623b464750d874685 (patch) | |
tree | 848a091847fade7c9a03b3c93caf30274343f57d /drivers/net/ethernet/marvell | |
parent | d97cda5f465bacc82659263a885703d73759ea04 (diff) | |
download | linux-09dbf6297fa8bb4433d9293623b464750d874685.tar.bz2 |
mlxsw: spectrum_router: Update nexthop RIF on update
The function mlxsw_sp_nexthop_rif_update() walks the list of nexthops
associated with a RIF, and updates the corresponding entries in the
switch. It is used in particular when a tunnel underlay netdevice moves
to a different VRF, and all the nexthops are migrated over to a new RIF.
The problem is that each nexthop holds a reference to its RIF, and that
is not updated. So after the old RIF is gone, further activity on these
nexthops (such as downing the underlay netdevice) dereferences a
dangling pointer.
Fix the issue by updating rif of impacted nexthops before calling
mlxsw_sp_nexthop_rif_update().
Fixes: 0c5f1cd5ba8c ("mlxsw: spectrum_router: Generalize __mlxsw_sp_ipip_entry_update_tunnel()")
Signed-off-by: Petr Machata <petrm@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/marvell')
0 files changed, 0 insertions, 0 deletions