Skip to content

Commit 0e85099

Browse files
author
Arto Kinnunen
authored
Update router id sequence number in router sync (#1594)
Router id sequence number updated in router sync to ensure that the number will be updated in case of power cycling leader.
1 parent f2cd4cf commit 0e85099

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

source/6LoWPAN/Thread/thread_leader_service.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1483,6 +1483,7 @@ void thread_leader_service_timer(protocol_interface_info_entry_t *cur, uint32_t
14831483
thread_bootstrap_network_data_update(cur);
14841484
}
14851485
}
1486+
14861487
if (cur->thread_info->leader_private_data->leader_id_seq_timer) {
14871488
if (cur->thread_info->leader_private_data->leader_id_seq_timer > ticks) {
14881489
cur->thread_info->leader_private_data->leader_id_seq_timer -= ticks;
@@ -1637,6 +1638,9 @@ int thread_leader_service_thread_partitition_restart(int8_t interface_id, mle_tl
16371638
// Clear network data (if exists) and propagate new empty network data
16381639
thread_network_data_free_and_clean(&cur->thread_info->networkDataStorage);
16391640
thread_network_data_base_init(&cur->thread_info->networkDataStorage);
1641+
// Update router sequence id to prevent network fragmentation in case of Leader was temporarily down
1642+
// and routers were not able to get new sequence id for NETWORK_ID_TIMEOUT duration.
1643+
thread_leader_service_update_id_set(cur);
16401644
return 0;
16411645
}
16421646

0 commit comments

Comments
 (0)