summaryrefslogtreecommitdiffstats
path: root/ospf6d/ospf6_lsa.c
diff options
context:
space:
mode:
authorYash Ranjan <ranjany@vmware.com>2021-03-11 14:41:05 +0100
committerYash Ranjan <ranjany@vmware.com>2021-03-25 08:25:16 +0100
commite161c2dc9ebb99ffa9b394f75ecebc370a58124f (patch)
treede5844a8bfd1c4a1714b874c32e1ec633a51e2df /ospf6d/ospf6_lsa.c
parentMerge pull request #8326 from idryzhov/hide-show-config (diff)
downloadfrr-e161c2dc9ebb99ffa9b394f75ecebc370a58124f.tar.xz
frr-e161c2dc9ebb99ffa9b394f75ecebc370a58124f.zip
ospf6d: Link LSAs are not getting MAX_AGE in neighbor
When the ospf6 daemon goes down, it originates MAX_AGE LSAs for all the self-originated LSAs so that it gets flushed from the neighbor's database. But the link-LSAs are not getting MAX_AGE. Set the self-originated link-LSAs age to MAX_AGE and flood it Signed-off-by: Yash Ranjan <ranjany@vmware.com>
Diffstat (limited to 'ospf6d/ospf6_lsa.c')
-rw-r--r--ospf6d/ospf6_lsa.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/ospf6d/ospf6_lsa.c b/ospf6d/ospf6_lsa.c
index f2a933d87..b4f0c30f1 100644
--- a/ospf6d/ospf6_lsa.c
+++ b/ospf6d/ospf6_lsa.c
@@ -853,11 +853,12 @@ int ospf6_lsa_refresh(struct thread *thread)
void ospf6_flush_self_originated_lsas_now(struct ospf6 *ospf6)
{
- struct listnode *node;
+ struct listnode *node, *nnode;
struct ospf6_area *oa;
struct ospf6_lsa *lsa;
const struct route_node *end = NULL;
uint32_t type, adv_router;
+ struct ospf6_interface *oi;
ospf6->inst_shutdown = 1;
@@ -872,6 +873,19 @@ void ospf6_flush_self_originated_lsas_now(struct ospf6 *ospf6)
lsa = ospf6_lsdb_next(end, lsa);
}
+
+ for (ALL_LIST_ELEMENTS(oa->if_list, node, nnode, oi)) {
+ end = ospf6_lsdb_head(oi->lsdb_self, 0, 0,
+ ospf6->router_id, &lsa);
+ while (lsa) {
+ /* RFC 2328 (14.1): Set MAXAGE */
+ lsa->header->age = htons(OSPF_LSA_MAXAGE);
+ /* Flood MAXAGE LSA*/
+ ospf6_flood(NULL, lsa);
+
+ lsa = ospf6_lsdb_next(end, lsa);
+ }
+ }
}
type = htons(OSPF6_LSTYPE_AS_EXTERNAL);