summaryrefslogtreecommitdiffstats
path: root/src/plugins/dhcp/dhcp6_pd_client_dp.c
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2019-09-30 10:53:31 +0000
committerOle Trøan <otroan@employees.org>2019-12-17 10:56:20 +0000
commitcbe25aab3be72154f2c706c39eeba6a77f34450f (patch)
tree131fb53b5ec973be045ffb9e2eb797af01d112a0 /src/plugins/dhcp/dhcp6_pd_client_dp.c
parent96453fd2417ebd1d69354a7fb692976129cea80e (diff)
ip: Protocol Independent IP Neighbors
Type: feature - ip-neighbour: generic neighbour handling; APIs, DBs, event handling, aging - arp: ARP protocol implementation - ip6-nd; IPv6 neighbor discovery implementation; separate ND, MLD, RA - ip6-link; manage link-local addresses - l2-arp-term; events separated from IP neighbours, since they are not the same. vnet retains just enough education to perform ND/ARP packet construction. arp and ip6-nd to be moved to plugins soon. Change-Id: I88dedd0006b299344f4c7024a0aa5baa6b9a8bbe Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'src/plugins/dhcp/dhcp6_pd_client_dp.c')
-rw-r--r--src/plugins/dhcp/dhcp6_pd_client_dp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/plugins/dhcp/dhcp6_pd_client_dp.c b/src/plugins/dhcp/dhcp6_pd_client_dp.c
index 7896e9a6403..980c83c7bbe 100644
--- a/src/plugins/dhcp/dhcp6_pd_client_dp.c
+++ b/src/plugins/dhcp/dhcp6_pd_client_dp.c
@@ -20,10 +20,10 @@
#include <vnet/mfib/ip6_mfib.h>
#include <vnet/fib/fib.h>
#include <vnet/adj/adj_mcast.h>
-#include <vnet/ip/ip6_neighbor.h>
#include <dhcp/dhcp6_pd_client_dp.h>
#include <dhcp/dhcp6_client_common_dp.h>
#include <vnet/ip/ip_types_api.h>
+#include <vnet/ip/ip6_link.h>
dhcp6_pd_client_main_t dhcp6_pd_client_main;
dhcp6_pd_client_public_main_t dhcp6_pd_client_public_main;
@@ -90,7 +90,7 @@ create_buffer_for_client_message (vlib_main_t * vm,
ip6_header_t *ip;
udp_header_t *udp;
dhcpv6_header_t *dhcp;
- ip6_address_t src_addr;
+ const ip6_address_t *src_addr;
u32 dhcp_opt_len = 0;
client_state->transaction_start = vlib_time_now (vm);
u32 n_prefixes;
@@ -102,9 +102,9 @@ create_buffer_for_client_message (vlib_main_t * vm,
*/
/* Get a link-local address */
- src_addr = ip6_neighbor_get_link_local_address (sw_if_index);
+ src_addr = ip6_get_link_local_address (sw_if_index);
- if (src_addr.as_u8[0] != 0xfe)
+ if (src_addr->as_u8[0] != 0xfe)
{
clib_warning ("Could not find source address to send DHCPv6 packet");
return NULL;
@@ -129,7 +129,7 @@ create_buffer_for_client_message (vlib_main_t * vm,
udp = (udp_header_t *) (ip + 1);
dhcp = (dhcpv6_header_t *) (udp + 1);
- ip->src_address = src_addr;
+ ip->src_address = *src_addr;
ip->hop_limit = 255;
ip->ip_version_traffic_class_and_flow_label =
clib_host_to_net_u32 (0x6 << 28);