Changeset 464 for azure_iot_hub_f767zi/trunk/asp_baseplatform/lwip/contrib-2.1.0/addons/ipv6_static_routing/README
- Timestamp:
- Jun 22, 2021, 9:00:19 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
azure_iot_hub_f767zi/trunk/asp_baseplatform/lwip/contrib-2.1.0/addons/ipv6_static_routing/README
r457 r464 1 A simple routing table implementation for addition, deletion and lookup of IPv6 routes. ï¾ï£°1 A simple routing table implementation for addition, deletion and lookup of IPv6 routes. 2 2 3 3 APIs are: 4 4 1) s8_t ip6_add_route_entry(struct ip6_prefix *ip6_prefix, 5 ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£°struct netif *netif,6 ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£°ip6_addr_t *gateway,7 ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£° ï¾ï£°s8_t *index);5               struct netif *netif, 6               ip6_addr_t *gateway, 7               s8_t *index); 8 8 9 9 2) err_t ip6_remove_route_entry(struct ip6_prefix *ip6_prefix); … … 17 17 6) struct ip6_route_entry *ip6_get_route_table(void); 18 18 19 For route lookup from the table, The ï¾ï£°LWIP_HOOK_IP6_ROUTE hook in ip6_route(..) of ip6.c19 For route lookup from the table, The LWIP_HOOK_IP6_ROUTE hook in ip6_route(..) of ip6.c 20 20 could be assigned to the ip6_static_route() API of this implementation to return the 21 21 appropriate netif. 22 22 23 -- The application can add routes using the API ip6_add_route_entry(..). ï¾ï£°24 ï¾ï£° ï¾ï£°This API adds the ip6 prefix route into the static route table while25 ï¾ï£° ï¾ï£°keeping all entries sorted in decreasing order of prefix length.26 ï¾ï£° ï¾ï£°Subsequently, a linear search down the list can be performed to retrieve a27 ï¾ï£° ï¾ï£°matching route entry for a Longest Prefix Match.28 ï¾ï£° ï¾ï£°The prefix length is expected to be at an 8-bit boundary. While this isï¾ï£° 29 ï¾ï£° ï¾ï£°a limitation, it would serve most practical purposes.23 -- The application can add routes using the API ip6_add_route_entry(..). 24   This API adds the ip6 prefix route into the static route table while 25   keeping all entries sorted in decreasing order of prefix length. 26   Subsequently, a linear search down the list can be performed to retrieve a 27   matching route entry for a Longest Prefix Match. 28   The prefix length is expected to be at an 8-bit boundary. While this is 29   a limitation, it would serve most practical purposes. 30 30 31 31 -- The application can remove routes using the API ip6_remove_route_entry(..). 32 32 33 -- The application can find a route entry for a specific address using the ï¾ï£°34 ï¾ï£° ï¾ï£°ip6_find_route_entry() function which returns the index of the found entry.ï¾ï£° 35 ï¾ï£° ï¾ï£°This is used internally by the route lookup function ip6_static_route() API.33 -- The application can find a route entry for a specific address using the 34   ip6_find_route_entry() function which returns the index of the found entry. 35   This is used internally by the route lookup function ip6_static_route() API. 36 36 37 -- To fetch the gateway IPv6 address for a specific destination IPv6 ï¾ï£°38 ï¾ï£° ï¾ï£°address and target netif, the application can call ip6_get_gateway(..).37 -- To fetch the gateway IPv6 address for a specific destination IPv6 38   address and target netif, the application can call ip6_get_gateway(..). 39 39 This API could be assigned to the LWIP_HOOK_ND6_GET_GW() if a gateway has 40 40 been added as part of the ip6_add_route_entry(). 41 41 42 -- To fetch a pointer to the head of the table, the application can call ï¾ï£°43 ï¾ï£° ï¾ï£°ip6_get_route_table().42 -- To fetch a pointer to the head of the table, the application can call 43   ip6_get_route_table().
Note:
See TracChangeset
for help on using the changeset viewer.