aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/route.c
diff options
context:
space:
mode:
authorIdo Schimmel <idosch@mellanox.com>2019-12-23 15:28:20 +0200
committerDavid S. Miller <davem@davemloft.net>2019-12-24 22:37:30 -0800
commitcaafb2509fac1432849650826953dd88b7cbe374 (patch)
treed788e210dc390a32965ccca4fa73fa68d6c00177 /net/ipv6/route.c
parentmlxsw: spectrum_router: Start using new IPv6 route notifications (diff)
downloadlinux-dev-caafb2509fac1432849650826953dd88b7cbe374.tar.xz
linux-dev-caafb2509fac1432849650826953dd88b7cbe374.zip
ipv6: Remove old route notifications and convert listeners
Now that mlxsw is converted to use the new FIB notifications it is possible to delete the old ones and use the new replace / append / delete notifications. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Reviewed-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to '')
-rw-r--r--net/ipv6/route.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 646716a47cc9..4b8659e077d3 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -3787,15 +3787,10 @@ static int __ip6_del_rt_siblings(struct fib6_info *rt, struct fib6_config *cfg)
replace_rt);
else
call_fib6_multipath_entry_notifiers(net,
- FIB_EVENT_ENTRY_DEL_TMP,
+ FIB_EVENT_ENTRY_DEL,
rt, rt->fib6_nsiblings,
NULL);
}
- call_fib6_multipath_entry_notifiers(net,
- FIB_EVENT_ENTRY_DEL,
- rt,
- rt->fib6_nsiblings,
- NULL);
list_for_each_entry_safe(sibling, next_sibling,
&rt->fib6_siblings,
fib6_siblings) {
@@ -5074,7 +5069,6 @@ static int ip6_route_multipath_add(struct fib6_config *cfg,
{
struct fib6_info *rt_notif = NULL, *rt_last = NULL;
struct nl_info *info = &cfg->fc_nlinfo;
- enum fib_event_type event_type;
struct fib6_config r_cfg;
struct rtnexthop *rtnh;
struct fib6_info *rt;
@@ -5210,7 +5204,7 @@ static int ip6_route_multipath_add(struct fib6_config *cfg,
if (rt_notif->fib6_nsiblings != nhn - 1)
fib_event = FIB_EVENT_ENTRY_APPEND;
else
- fib_event = FIB_EVENT_ENTRY_REPLACE_TMP;
+ fib_event = FIB_EVENT_ENTRY_REPLACE;
err = call_fib6_multipath_entry_notifiers(info->nl_net,
fib_event, rt_notif,
@@ -5221,14 +5215,6 @@ static int ip6_route_multipath_add(struct fib6_config *cfg,
goto add_errout;
}
}
- event_type = replace ? FIB_EVENT_ENTRY_REPLACE : FIB_EVENT_ENTRY_ADD;
- err = call_fib6_multipath_entry_notifiers(info->nl_net, event_type,
- rt_notif, nhn - 1, extack);
- if (err) {
- /* Delete all the siblings that were just added */
- err_nh = NULL;
- goto add_errout;
- }
/* success ... tell user about new route */
ip6_route_mpath_notify(rt_notif, rt_last, info, nlflags);