From 6b1886f511c1d3ee07f52ad6156dfe2a79c7a209 Mon Sep 17 00:00:00 2001 From: Chirag Shah Date: Thu, 12 Apr 2018 17:44:07 -0700 Subject: [PATCH] ospf6d: router-id change to display msg to restart When neighbor state transition from LOADING to FULL state, active full neighbors count incremented. The full neighbors count is used for router-id change if any full neighbor exist, displays message to restart ospf6/frr to activate new router-id. In the case of P-t-P neighbor type neighbor transition from EXCHANGE to FULL which missed full neighbors count. Ticket:CM-20574 Testing Done: Initially, Bring up zebra assigned router-id in ospf6 with point-to-point link based neighbor. Configure static router-id where restart of ospf6 message is displayed. Signed-off-by: Chirag Shah --- ospf6d/ospf6_neighbor.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ospf6d/ospf6_neighbor.c b/ospf6d/ospf6_neighbor.c index 6455f606bd..b5a1812ffa 100644 --- a/ospf6d/ospf6_neighbor.c +++ b/ospf6d/ospf6_neighbor.c @@ -193,8 +193,9 @@ static void ospf6_neighbor_state_change(uint8_t next_state, OSPF6_INTRA_PREFIX_LSA_SCHEDULE_STUB(on->ospf6_if->area); - if (prev_state == OSPF6_NEIGHBOR_LOADING - && next_state == OSPF6_NEIGHBOR_FULL) { + if ((prev_state == OSPF6_NEIGHBOR_LOADING || + prev_state == OSPF6_NEIGHBOR_EXCHANGE) && + next_state == OSPF6_NEIGHBOR_FULL) { OSPF6_AS_EXTERN_LSA_SCHEDULE(on->ospf6_if); on->ospf6_if->area->full_nbrs++; } -- 2.39.5