forked from Mirror/frr
pimd: on some triggers use_rpt re-evaluated for all groups
RP config change is a big hammer and use_rpt/spt needs to be re-evaluated on all existing (S,G) entries. Signed-off-by: Anuradha Karuppiah <anuradhak@cumulusnetworks.com>
This commit is contained in:
parent
9929a2a9af
commit
a749b90041
|
@ -274,6 +274,7 @@ struct rp_info *pim_rp_find_match_group(struct pim_instance *pim,
|
||||||
static void pim_rp_refresh_group_to_rp_mapping(struct pim_instance *pim)
|
static void pim_rp_refresh_group_to_rp_mapping(struct pim_instance *pim)
|
||||||
{
|
{
|
||||||
pim_msdp_i_am_rp_changed(pim);
|
pim_msdp_i_am_rp_changed(pim);
|
||||||
|
pim_upstream_reeval_use_rpt(pim);
|
||||||
}
|
}
|
||||||
|
|
||||||
void pim_rp_prefix_list_update(struct pim_instance *pim,
|
void pim_rp_prefix_list_update(struct pim_instance *pim,
|
||||||
|
@ -1041,6 +1042,7 @@ void pim_rp_check_on_if_add(struct pim_interface *pim_ifp)
|
||||||
|
|
||||||
if (i_am_rp_changed) {
|
if (i_am_rp_changed) {
|
||||||
pim_msdp_i_am_rp_changed(pim);
|
pim_msdp_i_am_rp_changed(pim);
|
||||||
|
pim_upstream_reeval_use_rpt(pim);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1083,6 +1085,7 @@ void pim_i_am_rp_re_evaluate(struct pim_instance *pim)
|
||||||
|
|
||||||
if (i_am_rp_changed) {
|
if (i_am_rp_changed) {
|
||||||
pim_msdp_i_am_rp_changed(pim);
|
pim_msdp_i_am_rp_changed(pim);
|
||||||
|
pim_upstream_reeval_use_rpt(pim);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -627,6 +627,22 @@ void pim_upstream_update_use_rpt(struct pim_upstream *up,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* some events like RP change require re-evaluation of SGrpt across
|
||||||
|
* all groups
|
||||||
|
*/
|
||||||
|
void pim_upstream_reeval_use_rpt(struct pim_instance *pim)
|
||||||
|
{
|
||||||
|
struct pim_upstream *up;
|
||||||
|
struct listnode *node;
|
||||||
|
|
||||||
|
for (ALL_LIST_ELEMENTS_RO(pim->upstream_list, node, up)) {
|
||||||
|
if (up->sg.src.s_addr == INADDR_ANY)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
pim_upstream_update_use_rpt(up, true /*update_mroute*/);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void pim_upstream_switch(struct pim_instance *pim, struct pim_upstream *up,
|
void pim_upstream_switch(struct pim_instance *pim, struct pim_upstream *up,
|
||||||
enum pim_upstream_state new_state)
|
enum pim_upstream_state new_state)
|
||||||
{
|
{
|
||||||
|
|
|
@ -336,4 +336,5 @@ void pim_upstream_fill_static_iif(struct pim_upstream *up,
|
||||||
struct interface *incoming);
|
struct interface *incoming);
|
||||||
void pim_upstream_update_use_rpt(struct pim_upstream *up,
|
void pim_upstream_update_use_rpt(struct pim_upstream *up,
|
||||||
bool update_mroute);
|
bool update_mroute);
|
||||||
|
void pim_upstream_reeval_use_rpt(struct pim_instance *pim);
|
||||||
#endif /* PIM_UPSTREAM_H */
|
#endif /* PIM_UPSTREAM_H */
|
||||||
|
|
Loading…
Reference in a new issue