20 #ifndef included_vnet_vxlan_gpe_h 21 #define included_vnet_vxlan_gpe_h 45 }) ip4_vxlan_gpe_header_t;
54 }) ip6_vxlan_gpe_header_t;
73 }) vxlan4_gpe_tunnel_key_t;
85 }) vxlan6_gpe_tunnel_key_t;
126 #define VXLAN_GPE_TUNNEL_IS_IPV4 1 129 #define foreach_vxlan_gpe_input_next \ 130 _(DROP, "error-drop") \ 131 _(IP4_INPUT, "ip4-input") \ 132 _(IP6_INPUT, "ip6-input") \ 133 _(ETHERNET_INPUT, "ethernet-input") 137 #define _(s,n) VXLAN_GPE_INPUT_NEXT_##s, 145 #define vxlan_gpe_error(n,s) VXLAN_GPE_ERROR_##n, 147 #undef vxlan_gpe_error 201 u8 protocol_override,
uword encap_next_node);
203 u8 protocol_override,
uword encap_next_node);
uword * vxlan6_gpe_tunnel_by_key
lookup IPv6 VXLAN GPE tunnel by key
vlib_node_registration_t vxlan6_gpe_input_node
(constructor) VLIB_REGISTER_NODE (vxlan6_gpe_input_node)
u8 pad[3]
log2 (size of the packing page block)
vlib_node_registration_t vxlan_gpe_encap_node
(constructor) VLIB_REGISTER_NODE (vxlan_gpe_encap_node)
vxlan_gpe_encap_next_t
Struct for defining VXLAN GPE next nodes.
u32 * tunnel_index_by_sw_if_index
Mapping from sw_if_index to tunnel index.
u8 * format_vxlan_gpe_encap_trace(u8 *s, va_list *args)
Trace of packets encapsulated in VXLAN GPE.
struct _vlib_node_registration vlib_node_registration_t
vnet_main_t * vnet_main
State convenience vnet_main_t.
vxlan_gpe_main_t vxlan_gpe_main
typedef CLIB_PACKED(struct{ip4_header_t ip4;udp_header_t udp;vxlan_gpe_header_t vxlan;}) ip4_vxlan_gpe_header_t
VXLAN GPE header struct.
ip46_address_t local
tunnel local address
u8 * rewrite
Rewrite string.
VXLAN GPE packet header structure.
Struct for VXLAN GPE tunnel.
int vnet_vxlan_gpe_add_del_tunnel(vnet_vxlan_gpe_add_del_tunnel_args_t *a, u32 *sw_if_indexp)
Add or Del a VXLAN GPE tunnel.
vlib_node_registration_t vxlan4_gpe_input_node
(constructor) VLIB_REGISTER_NODE (vxlan4_gpe_input_node)
vlib_main_t * vlib_main
State convenience vlib_main_t.
u8 protocol
encapsulated protocol
ip46_address_t remote
tunnel remote address
u32 vni
VXLAN GPE VNI in HOST byte order, shifted left 8 bits.
Struct for VXLAN GPE add/del args.
int vxlan6_gpe_rewrite(vxlan_gpe_tunnel_t *t, u32 extension_size, u8 protocol_override, uword encap_next_node)
Calculate IPv6 VXLAN GPE rewrite header.
vxlan_gpe_input_error_t
struct for VXLAN GPE errors
void vxlan_gpe_unregister_decap_protocol(u8 protocol_id, uword next_node_index)
#define foreach_vxlan_gpe_input_next
next nodes for VXLAN GPE input
void vxlan_gpe_register_decap_protocol(u8 protocol_id, uword next_node_index)
u8 rewrite_size
rewrite size for dynamic plugins like iOAM
Struct for VXLAN GPE node state.
vxlan_gpe_tunnel_t * tunnels
vector of encap tunnel instances
uword * vxlan4_gpe_tunnel_by_key
lookup IPv4 VXLAN GPE tunnel by key
u32 decap_fib_index
FIB indices - inner IP packet lookup here.
int vxlan4_gpe_rewrite(vxlan_gpe_tunnel_t *t, u32 extension_size, u8 protocol_override, uword encap_next_node)
Calculate IPv4 VXLAN GPE rewrite header.
u32 hw_if_index
vnet intfc hw_if_index
vxlan_gpe_input_next_t
struct for next nodes for VXLAN GPE input
u32 encap_fib_index
FIB indices - tunnel partner lookup here.
uword encap_next_node
Next node after VxLAN-GPE encap.
u32 sw_if_index
vnet intfc sw_if_index
u32 * free_vxlan_gpe_tunnel_hw_if_indices
Free vlib hw_if_indices.