mlxsw: spectrum_router: Adjust IPv6 replace logic to new notifications
authorIdo Schimmel <idosch@mellanox.com>
Tue, 18 Jun 2019 15:12:53 +0000 (18:12 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 18 Jun 2019 16:45:37 +0000 (09:45 -0700)
commit94d628d1f97b88749caee797ff78d41eb95e26e5
treeca22605819cf6a59d3bcf001a678f644a1d047a4
parent928c0b534f2977a3c20c6237282fb8f685775373
mlxsw: spectrum_router: Adjust IPv6 replace logic to new notifications

Previously, IPv6 replace notifications were only sent from
fib6_add_rt2node(). The function only emitted such notifications if a
route actually replaced another route.

A previous patch added another call site in ip6_route_multipath_add()
from which such notification can be emitted even if a route was merely
added and did not replace another route.

Adjust the driver to take this into account and potentially set the
'replace' flag to 'false' if the notified route did not replace an
existing route.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c