pimd: When the RPF is changed remove the group

When changing the RPF cleanup the old entry
in the J/P Agg neighbor list.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
Donald Sharp 2017-03-16 08:38:03 -04:00
parent ce2b6ce098
commit cb35003fdc
3 changed files with 13 additions and 7 deletions

View File

@ -370,6 +370,12 @@ pim_update_upstream_nh (struct pim_nexthop_cache *pnc)
if (rpf_result == PIM_RPF_CHANGED)
{
struct pim_neighbor *nbr;
nbr = pim_neighbor_find (old.source_nexthop.interface,
old.rpf_addr.u.prefix4);
if (nbr)
pim_jp_agg_remove_group (nbr->upstream_jp_agg, up);
/*
* We have detected a case where we might need to rescan

View File

@ -337,13 +337,6 @@ join_timer_start(struct pim_upstream *up)
*/
void pim_upstream_join_timer_restart(struct pim_upstream *up, struct pim_rpf *old)
{
struct pim_neighbor *nbr;
nbr = pim_neighbor_find (old->source_nexthop.interface,
old->rpf_addr.u.prefix4);
if (nbr)
pim_jp_agg_remove_group (nbr->upstream_jp_agg, up);
//THREAD_OFF(up->t_join_timer);
join_timer_start(up);
}

View File

@ -382,6 +382,13 @@ static void scan_upstream_rpf_cache()
continue;
if (rpf_result == PIM_RPF_CHANGED) {
struct pim_neighbor *nbr;
nbr = pim_neighbor_find (old.source_nexthop.interface,
old.rpf_addr.u.prefix4);
if (nbr)
pim_jp_agg_remove_group (nbr->upstream_jp_agg, up);
/*
* We have detected a case where we might need to rescan
* the inherited o_list so do it.