Skip to content

Commit

Permalink
fixup! nib: implement public NIB functions up to link-local AR
Browse files Browse the repository at this point in the history
Some doc fixes
  • Loading branch information
miri64 committed Oct 6, 2017
1 parent 82537d8 commit e0038c5
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 14 deletions.
4 changes: 2 additions & 2 deletions sys/net/gnrc/network_layer/ipv6/nib/_nib-6ln.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ static inline bool _is_6ln(const gnrc_ipv6_netif_t *netif)
}

/**
* @brief Resolve address statically from destination address using reverse
* @brief Resolves address statically from destination address using reverse
* translation of the IID
*
* @param[in] dst A destination address.
Expand All @@ -73,7 +73,7 @@ bool _resolve_addr_from_ipv6(const ipv6_addr_t *dst, kernel_pid_t iface,
gnrc_ipv6_nib_nc_t *nce);

/**
* @brief Handle ARO
* @brief Handles ARO
*
* @param[in] iface The interface the ARO-carrying message came over.
* @param[in] ipv6 The IPv6 header of the message carrying the ARO.
Expand Down
4 changes: 2 additions & 2 deletions sys/net/gnrc/network_layer/ipv6/nib/_nib-6lr.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ static inline bool _is_6lr(const gnrc_ipv6_netif_t *netif)
}

/**
* @brief Get address registration state of a neighbor
* @brief Gets address registration state of a neighbor
*
* @param[in] entry Neighbor cache entry representing the neighbor.
*
Expand All @@ -61,7 +61,7 @@ static inline uint16_t _get_ar_state(const _nib_onl_entry_t *entry)
}

/**
* @brief Set address registration state of a neighbor
* @brief Sets address registration state of a neighbor
*
* @param[in] entry Neighbor cache entry representing the neighbor.
* @param[in] state Address registration state for the neighbor.
Expand Down
4 changes: 2 additions & 2 deletions sys/net/gnrc/network_layer/ipv6/nib/_nib-arsm.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ static char addr_str[IPV6_ADDR_MAX_STR_LEN];
#endif

/**
* @brief Determine supposed link-layer address from interface and option
* @brief Determines supposed link-layer address from interface and option
* length
*
* @param[in] netif A network interface.
Expand Down Expand Up @@ -171,7 +171,7 @@ static inline unsigned _get_l2addr_len(gnrc_ipv6_netif_t *netif,

#if GNRC_IPV6_NIB_CONF_ARSM
/**
* @brief Calculate exponential back-off for retransmission timer for
* @brief Calculates exponential back-off for retransmission timer for
* neighbor solicitations
*
* @param[in] ns_sent Neighbor solicitations sent up until now.
Expand Down
19 changes: 12 additions & 7 deletions sys/net/gnrc/network_layer/ipv6/nib/_nib-arsm.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ extern "C" {
#endif

/**
* @brief Send neighbor solicitation (including ARO if required)
* @brief Sends neighbor solicitation (including ARO if required)
*
* @pre `(tgt != NULL) && !ipv6_addr_is_multicast(tgt)`
* @pre `(netif != NULL) && (dst != NULL)`
Expand All @@ -51,7 +51,7 @@ void _snd_ns(const ipv6_addr_t *tgt, gnrc_ipv6_netif_t *netif,
const ipv6_addr_t *src, const ipv6_addr_t *dst);

/**
* @brief Send unicast neighbor solicitation and reset corresponding timer
* @brief Sends unicast neighbor solicitation and reset corresponding timer
* event
*
* @note Neighbor solicitations are used *by* the ARSM, but also by other
Expand All @@ -65,7 +65,7 @@ void _snd_ns(const ipv6_addr_t *tgt, gnrc_ipv6_netif_t *netif,
void _snd_uc_ns(_nib_onl_entry_t *nbr, bool reset);

/**
* @brief Handle SL2AO
* @brief Handles SL2AO
*
* @note This is here (but not only available with
* @ref GNRC_IPV6_NIB_CONF_ARSM set) since it is closely related
Expand Down Expand Up @@ -98,15 +98,15 @@ void _handle_snd_ns(_nib_onl_entry_t *nbr);
void _handle_state_timeout(_nib_onl_entry_t *nbr);

/**
* @brief Probe neighbor with neighbor solicitations
* @brief Probes neighbor with neighbor solicitations
*
* @param[in] nbr Neighbor to probe.
* @param[in] reset Reset probe counter.
*/
void _probe_nbr(_nib_onl_entry_t *nbr, bool reset);

/**
* @brief Handle advertised link-layer information
* @brief Handles advertised link-layer information
*
* This can either be an TL2AO or for a link-layer without addresses just a
* neighbor advertisement.
Expand All @@ -132,6 +132,11 @@ void _handle_adv_l2(kernel_pid_t iface, _nib_onl_entry_t *nce,
*/
void _set_reachable(unsigned iface, _nib_onl_entry_t *nce);

/**
* @brief Initializes interface for address registration state machine
*
* @param[in] nib_iface An interface
*/
static inline void _init_iface_arsm(_nib_iface_t *nib_iface)
{
nib_iface->reach_time_base = NDP_REACH_MS;
Expand All @@ -143,7 +148,7 @@ static inline void _init_iface_arsm(_nib_iface_t *nib_iface)
}

/**
* @brief Get neighbor unreachability state of a neighbor
* @brief Gets neighbor unreachability state of a neighbor
*
* @param[in] entry Neighbor cache entry representing the neighbor.
*
Expand All @@ -155,7 +160,7 @@ static inline uint16_t _get_nud_state(_nib_onl_entry_t *entry)
}

/**
* @brief Set neighbor unreachablility state of a neighbor
* @brief Sets neighbor unreachablility state of a neighbor
*
* @param[in] entry Neighbor cache entry representing the neighbor.
* @param[in] state Neighbor unreachability state for the neighbor.
Expand Down
2 changes: 1 addition & 1 deletion sys/net/gnrc/network_layer/ipv6/nib/_nib-internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -809,7 +809,7 @@ int _nib_get_route(const ipv6_addr_t *dst, gnrc_pktsnip_t *ctx,
_nib_iface_t *_nib_iface_get(unsigned iface);

/**
* @brief Recalculate randomized reachable time of an interface.
* @brief Recalculates randomized reachable time of an interface.
*
* @param[in] iface An interface.
*/
Expand Down

0 comments on commit e0038c5

Please sign in to comment.