Skip to content

Commit

Permalink
Added disabling of NA for Wi-SUN BR PPP backbone
Browse files Browse the repository at this point in the history
If backbone is PPP and not ethernet, BR no longer sends neighbor
advertisements to the interface when new address is registered.
  • Loading branch information
Mika Leppänen committed Aug 22, 2019
1 parent d2ea325 commit 4c50e52
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
4 changes: 4 additions & 0 deletions source/6LoWPAN/ws/ws_bbr_api.c
Expand Up @@ -239,6 +239,10 @@ static void wisun_bbr_na_send(int8_t interface_id, const uint8_t target[static 1
if (!cur) {
return;
}
// Send NA only if it is enabled for the backhaul
if (!cur->send_na) {
return;
}

buffer_t *buffer = icmpv6_build_na(cur, false, true, true, target, NULL, ADDR_UNSPECIFIED);
protocol_push(buffer);
Expand Down
1 change: 1 addition & 0 deletions source/NWK_INTERFACE/Include/protocol.h
Expand Up @@ -410,6 +410,7 @@ struct protocol_interface_info_entry {
bool mpl_treat_realm_domains_as_one: 1;
bool mpl_auto_domain_on_group_join: 1;
#endif
bool send_na : 1;
/* RFC 4861 Router Variables */
bool ip_forwarding : 1;
bool ip_multicast_forwarding : 1;
Expand Down
2 changes: 2 additions & 0 deletions source/NWK_INTERFACE/protocol_core.c
Expand Up @@ -485,6 +485,7 @@ static void protocol_core_base_finish_init(protocol_interface_info_entry_t *entr
entry->dad_failures = 0;
entry->icmp_tokens = 10;
entry->mle_link_reject_tokens = 2;
entry->send_na = true; /* Default to on for now... */
entry->ip_forwarding = true; /* Default to on for now... */
entry->ip_multicast_forwarding = true; /* Default to on for now... */
#ifdef HAVE_IPV6_ND
Expand Down Expand Up @@ -936,6 +937,7 @@ protocol_interface_info_entry_t *protocol_stack_interface_generate_ppp(eth_mac_a
memcpy(new_entry->iid_eui64, iid64, 8);
new_entry->send_mld = false; // No mld for PPP
new_entry->dup_addr_detect_transmits = 0; // No duplicate detection for PPP
new_entry->send_na = false; // No neighbor advertisements for PPP

ns_list_add_to_start(&protocol_interface_info_list, new_entry);

Expand Down

0 comments on commit 4c50e52

Please sign in to comment.