From 02655bd425cc596960b7efc74d1fbad3b3406419 Mon Sep 17 00:00:00 2001 From: Florin Coras Date: Tue, 26 Apr 2016 00:17:24 +0200 Subject: Add lisp-gpe ip6 data-plane support The implementation mimics that of the ip4 data-plane. Therefore, a new lgpe-ip6-lookup lookup node is introduced for ip6 source lookups, a lisp-gpe-ip6-input node for decapsulating ip6 encapsulated packets and the tx function of the lisp-gpe interface is updated to support any mix of v4 and v6 in underlay and overlay. Change-Id: Ib3a6e339b8cd7618a940acf0dd8e61c042fd83dd Signed-off-by: Florin Coras --- vpp/api/api.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'vpp/api/api.c') diff --git a/vpp/api/api.c b/vpp/api/api.c index 1b6d52be..bc2f64cd 100644 --- a/vpp/api/api.c +++ b/vpp/api/api.c @@ -4860,7 +4860,6 @@ send_lisp_gpe_tunnel_details (lisp_gpe_tunnel_t *tunnel, { vl_api_lisp_gpe_tunnel_details_t *rmp; lisp_gpe_main_t * lgm = &lisp_gpe_main; - ip4_address_t *ip4 = NULL; rmp = vl_msg_api_alloc (sizeof (*rmp)); memset (rmp, 0, sizeof (*rmp)); @@ -4868,12 +4867,9 @@ send_lisp_gpe_tunnel_details (lisp_gpe_tunnel_t *tunnel, rmp->tunnels = tunnel - lgm->tunnels; - /*list_gpe_tunnel now support only IPv4*/ - rmp->is_ipv6 = 0; - ip4 = &tunnel->src; - clib_memcpy(rmp->source_ip, ip4, sizeof(*ip4)); - ip4 = &tunnel->dst; - clib_memcpy(rmp->destination_ip, ip4, sizeof(*ip4)); + rmp->is_ipv6 = ip_addr_version(&tunnel->src) == IP6 ? 1 : 0; + ip_address_copy_addr(rmp->source_ip, &tunnel->src); + ip_address_copy_addr(rmp->destination_ip, &tunnel->dst); rmp->encap_fib_id = htonl(tunnel->encap_fib_index); rmp->decap_fib_id = htonl(tunnel->decap_fib_index); -- cgit 1.2.3-korg