Check if LISP is enable
[vpp.git] / vnet / vnet / lisp-gpe / lisp_gpe.h
index cba7795..705b64f 100644 (file)
@@ -171,24 +171,6 @@ extern vlib_node_registration_t lisp_gpe_ip6_input_node;
 u8 *
 format_lisp_gpe_header_with_length (u8 * s, va_list * args);
 
-typedef struct
-{
-  u8 is_add;
-  ip4_address_t src, dst;
-  u32 encap_fib_index;
-  u32 decap_fib_index;
-  u32 decap_next_index;
-  u8 flags;
-  u8 ver_res;
-  u8 res;
-  u8 next_protocol;
-  u32 vni; /* host byte order */
-} vnet_lisp_gpe_add_del_tunnel_args_t;
-
-int
-vnet_lisp_gpe_add_del_tunnel (vnet_lisp_gpe_add_del_tunnel_args_t *a,
-                             u32 * sw_if_indexp);
-
 typedef struct
 {
   u8 is_add;
@@ -198,7 +180,7 @@ typedef struct
 
 u8
 vnet_lisp_gpe_enable_disable_status(void);
-void
+int
 vnet_lisp_gpe_add_del_iface (vnet_lisp_gpe_add_del_iface_args_t *a,
                             u32 * hw_if_indexp);
 
@@ -221,20 +203,29 @@ typedef enum
 typedef struct
 {
   u8 is_add;
+
+  /* type of mapping */
   u8 is_negative;
   negative_fwd_actions_e action;
+
+  /* local and remote eids */
   gid_address_t seid; /* TODO convert to ip4, ip6, mac ? */
   gid_address_t deid;
+
+  /* local and remote locators (underlay attachment points) */
   ip_address_t slocator;
   ip_address_t dlocator;
+
+  /* FIB indices to lookup remote locator at encap and inner IP at decap */
   u32 encap_fib_index;
   u32 decap_fib_index;
+
   u32 decap_next_index; /* TODO is this really needed? */
-  u8 flags;
-  u8 ver_res;
-  u8 res;
-  u8 next_protocol;
-  u32 vni; /* host byte order */
+
+  /* VNI/tenant id in HOST byte order */
+  u32 vni;
+
+  /* vrf where fwd entry should be inserted */
   u32 table_id;
 } vnet_lisp_gpe_add_del_fwd_entry_args_t;
 
@@ -274,4 +265,6 @@ typedef enum lgpe_ip6_lookup_next
   LGPE_IP6_LOOKUP_N_NEXT,
 } lgpe_ip6_lookup_next_t;
 
+u8 * format_vnet_lisp_gpe_status (u8 * s, va_list * args);
+
 #endif /* included_vnet_lisp_gpe_h */