mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-15 11:11:36 +00:00
Merge pull request #15184 from donaldsharp/zebra_touchups
Zebra touchups
This commit is contained in:
commit
f6178ee2e1
@ -171,18 +171,13 @@ static int if_zebra_new_hook(struct interface *ifp)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void if_nhg_dependents_check_valid(struct nhg_hash_entry *nhe)
|
||||
{
|
||||
zebra_nhg_check_valid(nhe);
|
||||
}
|
||||
|
||||
static void if_down_nhg_dependents(const struct interface *ifp)
|
||||
{
|
||||
struct nhg_connected *rb_node_dep = NULL;
|
||||
struct zebra_if *zif = (struct zebra_if *)ifp->info;
|
||||
|
||||
frr_each(nhg_connected_tree, &zif->nhg_dependents, rb_node_dep)
|
||||
if_nhg_dependents_check_valid(rb_node_dep->nhe);
|
||||
zebra_nhg_check_valid(rb_node_dep->nhe);
|
||||
}
|
||||
|
||||
static void if_nhg_dependents_release(const struct interface *ifp)
|
||||
@ -192,7 +187,7 @@ static void if_nhg_dependents_release(const struct interface *ifp)
|
||||
|
||||
frr_each(nhg_connected_tree, &zif->nhg_dependents, rb_node_dep) {
|
||||
rb_node_dep->nhe->ifp = NULL; /* Null it out */
|
||||
if_nhg_dependents_check_valid(rb_node_dep->nhe);
|
||||
zebra_nhg_check_valid(rb_node_dep->nhe);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1082,11 +1082,10 @@ void zebra_nhg_check_valid(struct nhg_hash_entry *nhe)
|
||||
frr_each(nhg_connected_tree, &nhe->nhg_depends, rb_node_dep) {
|
||||
if (CHECK_FLAG(rb_node_dep->nhe->flags, NEXTHOP_GROUP_VALID)) {
|
||||
valid = true;
|
||||
goto done;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
done:
|
||||
if (valid)
|
||||
zebra_nhg_set_valid(nhe);
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user