summaryrefslogtreecommitdiffstats
path: root/ospfd/ospf_lsdb.c
diff options
context:
space:
mode:
authorMadhuri Kuruganti <maduri111@gmail.com>2022-09-04 14:46:09 +0200
committerMadhuri Kuruganti <maduri111@gmail.com>2022-10-12 10:13:55 +0200
commita3d3a14c09cf212c7d402670247c4d518b99d8b7 (patch)
tree5dad10bdebb5d4bc7fbdfc7dc8da9c910e7c3d51 /ospfd/ospf_lsdb.c
parentbgpd: optimal router reflection cli and fsm changes (diff)
downloadfrr-a3d3a14c09cf212c7d402670247c4d518b99d8b7.tar.xz
frr-a3d3a14c09cf212c7d402670247c4d518b99d8b7.zip
ospfd: rSPF calc and messaging for optimal route reflection
Signed-off-by: Madhuri Kuruganti <maduri111@gmail.com>
Diffstat (limited to 'ospfd/ospf_lsdb.c')
-rw-r--r--ospfd/ospf_lsdb.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/ospfd/ospf_lsdb.c b/ospfd/ospf_lsdb.c
index f4fb858a5..3c65ac388 100644
--- a/ospfd/ospf_lsdb.c
+++ b/ospfd/ospf_lsdb.c
@@ -30,6 +30,7 @@
#include "ospfd/ospf_asbr.h"
#include "ospfd/ospf_lsa.h"
#include "ospfd/ospf_lsdb.h"
+#include "ospfd/ospf_orr.h"
struct ospf_lsdb *ospf_lsdb_new(void)
{
@@ -87,6 +88,10 @@ static void ospf_lsdb_delete_entry(struct ospf_lsdb *lsdb,
assert(rn->table == lsdb->type[lsa->data->type].db);
+ /* Update ORR Root table MPLS-TE Router address's advertise router */
+ if (lsa->data->type == OSPF_OPAQUE_AREA_LSA)
+ ospf_orr_root_table_update(lsa, false);
+
if (IS_LSA_SELF(lsa))
lsdb->type[lsa->data->type].count_self--;
lsdb->type[lsa->data->type].count--;
@@ -134,6 +139,10 @@ void ospf_lsdb_add(struct ospf_lsdb *lsdb, struct ospf_lsa *lsa)
#endif /* MONITOR_LSDB_CHANGE */
lsdb->type[lsa->data->type].checksum += ntohs(lsa->data->checksum);
rn->info = ospf_lsa_lock(lsa); /* lsdb */
+
+ /* Update ORR Root table MPLS-TE Router address's advertise router */
+ if (lsa->data->type == OSPF_OPAQUE_AREA_LSA)
+ ospf_orr_root_table_update(lsa, true);
}
void ospf_lsdb_delete(struct ospf_lsdb *lsdb, struct ospf_lsa *lsa)