Skip to content

Commit

Permalink
zebra: add support for 'mpls uninstall' of nexthop group dependencies
Browse files Browse the repository at this point in the history
The nexthop group dependencies may also have an NHLFE entry.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
  • Loading branch information
pguibert6WIND committed Jan 4, 2024
1 parent b53f8e8 commit c0d078c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions zebra/zebra_mpls.c
Original file line number Diff line number Diff line change
Expand Up @@ -3362,7 +3362,16 @@ static void mpls_ftn_uninstall_nhg(struct route_entry *re,
enum lsp_types_t lsp_type, bool *update)
{
struct nexthop *nexthop;
struct nexthop_group_id *nhgid;

if (CHECK_FLAG(nhg->flags, NEXTHOP_GROUP_TYPE_GROUP)) {
for (nhgid = nhg->group; nhgid; nhgid = nhgid->next) {
if (nhgid->nhg)
mpls_ftn_uninstall_nhg(re, nhgid->nhg, lsp_type,
update);
}
return;
}
for (nexthop = nhg->nexthop; nexthop; nexthop = nexthop->next) {
if (nexthop->nh_label_type != lsp_type)
continue;
Expand Down

0 comments on commit c0d078c

Please sign in to comment.