|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
23 #include <vnet/tunnel/tunnel_types.api_enum.h>
24 #include <vnet/tunnel/tunnel_types.api_types.h>
29 "tunnel API and internal flags enum size differ");
31 "tunnel API and internal flags enum size differ");
39 return (VNET_API_ERROR_INVALID_VALUE_2);
45 vl_api_tunnel_encap_decap_flags_t
48 return ((vl_api_tunnel_encap_decap_flags_t)
f);
56 return (VNET_API_ERROR_INVALID_VALUE_2);
65 return ((vl_api_tunnel_flags_t)
f);
74 case TUNNEL_API_MODE_##n: \
75 *out = TUNNEL_MODE_##n; \
81 return (VNET_API_ERROR_INVALID_VALUE_2);
92 case TUNNEL_MODE_##n: \
93 out = TUNNEL_API_MODE_##n; \
111 return (VNET_API_ERROR_INVALID_PROTOCOL);
114 return (VNET_API_ERROR_SAME_SRC_DST);
132 out->
t_table_id = clib_net_to_host_u32 (in->table_id);
138 return (VNET_API_ERROR_NO_SUCH_FIB);
152 out->encap_decap_flags =
156 out->table_id = clib_host_to_net_u32 (in->
t_table_id);
STATIC_ASSERT(sizeof(vl_api_tunnel_encap_decap_flags_t)==sizeof(tunnel_encap_decap_flags_t), "tunnel API and internal flags enum size differ")
vl_api_tunnel_mode_t tunnel_mode_encode(tunnel_mode_t in)
enum tunnel_encap_decap_flags_t_ tunnel_encap_decap_flags_t
A representation of an IP tunnel config.
enum tunnel_flags_t_ tunnel_flags_t
vl_api_ip_dscp_t ip_dscp_encode(ip_dscp_t dscp)
u32 t_fib_index
derived data
const u8 TUNNEL_FLAG_MASK
@ TUNNEL_API_MODE_P2P
point-to-point
void ip_address_encode2(const ip_address_t *in, vl_api_address_t *out)
#define ip_addr_version(_a)
int tunnel_encap_decap_flags_decode(vl_api_tunnel_encap_decap_flags_t f, tunnel_encap_decap_flags_t *o)
Conversion functions to/from (decode/encode) API types to VPP internal types.
ip_dscp_t ip_dscp_decode(vl_api_ip_dscp_t in)
fib_protocol_t ip_address_family_to_fib_proto(ip_address_family_t af)
void ip_address_decode2(const vl_api_address_t *in, ip_address_t *out)
void tunnel_encode(const tunnel_t *in, vl_api_tunnel_t *out)
int tunnel_flags_decode(vl_api_tunnel_flags_t f, tunnel_flags_t *o)
enum tunnel_mode_t_ tunnel_mode_t
vl_api_tunnel_flags_t tunnel_flags_encode(tunnel_flags_t f)
const u8 TUNNEL_ENCAP_DECAP_FLAG_MASK
tunnel_encap_decap_flags_t t_encap_decap_flags
vl_api_tunnel_encap_decap_flags_t tunnel_encap_decap_flags_encode(tunnel_encap_decap_flags_t f)
int tunnel_mode_decode(vl_api_tunnel_mode_t in, tunnel_mode_t *out)
int ip_address_cmp(const ip_address_t *ip1, const ip_address_t *ip2)
int tunnel_decode(const vl_api_tunnel_t *in, tunnel_t *out)
u32 fib_table_find(fib_protocol_t proto, u32 table_id)
Get the index of the FIB for a Table-ID.