• P
    mlxsw: spectrum_router: Demote tunnels on VRF migration · cab43d9c
    Petr Machata 提交于
    The mlxsw driver currently doesn't offload GRE tunnels if they have the
    same local address and use the same underlay VRF. When such a situation
    arises, the tunnels in conflict are demoted to slow path.
    
    However, the current code only verifies this condition on tunnel
    creation and tunnel change, not when a tunnel is moved to a different
    VRF. When the tunnel has no bound device, underlay and overlay are the
    same. Thus moving a tunnel moves the underlay as well, and that can
    cause local address conflict.
    
    So modify mlxsw_sp_netdevice_ipip_ol_vrf_event() to check if there are
    any conflicting tunnels, and demote them if yes.
    
    Fixes: af641713 ("mlxsw: spectrum_router: Onload conflicting tunnels")
    Signed-off-by: NPetr Machata <petrm@mellanox.com>
    Reviewed-by: NIdo Schimmel <idosch@mellanox.com>
    Signed-off-by: NJiri Pirko <jiri@mellanox.com>
    Signed-off-by: NDavid S. Miller <davem@davemloft.net>
    cab43d9c
spectrum_router.c 188.7 KB