diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c index cded8e8039bd838cdc06aaee030f28a4cf8c3416..45cf32ca4126091656045b586a0a7ad9200212cf 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c @@ -3528,6 +3528,9 @@ static int mlxsw_sp_router_fib6_add(struct mlxsw_sp *mlxsw_sp, if (mlxsw_sp->router->aborted) return 0; + if (rt->rt6i_src.plen) + return -EINVAL; + if (mlxsw_sp_fib6_rt_should_ignore(rt)) return 0;