ipv6: Only emit append events for appended routes
authorIdo Schimmel <idosch@mellanox.com>
Fri, 15 Jun 2018 13:23:35 +0000 (16:23 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 Jun 2018 16:11:16 +0000 (09:11 -0700)
commit6eba08c3626bca42b3cb0c9d43ac37ab11b4be1a
tree4bd2a3b3a28fa06b8b7af108170e8210c13d2417
parent41f9ba67f087756efd8c4aa490c097035c1969af
ipv6: Only emit append events for appended routes

Current code will emit an append event in the FIB notification chain for
any route added with NLM_F_APPEND set, even if the route was not
appended to any existing route.

This is inconsistent with IPv4 where such an event is only emitted when
the new route is appended after an existing one.

Align IPv6 behavior with IPv4, thereby allowing listeners to more easily
handle these events.

Fixes: f34436a43092 ("net/ipv6: Simplify route replace and appending into multipath route")
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Acked-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/ip6_fib.c