|
FD.io VPP
v21.10.1-2-g0a485f517
Vector Packet Processing
|
Go to the documentation of this file.
30 #include <geneve/geneve.api_enum.h>
31 #include <geneve/geneve.api_types.h>
37 #define REPLY_MSG_ID_BASE geneve_base_msg_id
45 vl_api_sw_interface_set_geneve_bypass_reply_t *rmp;
54 REPLY_MACRO (VL_API_SW_INTERFACE_SET_GENEVE_BYPASS_REPLY);
67 rv = VNET_API_ERROR_NO_SUCH_FIB;
75 .encap_fib_index = p[0],
77 .vni = ntohl (mp->
vni),
86 rv = VNET_API_ERROR_SAME_SRC_DST;
92 rv = VNET_API_ERROR_INVALID_SW_IF_INDEX;
118 rv = VNET_API_ERROR_NO_SUCH_FIB;
126 .encap_fib_index = p[0],
128 .vni = ntohl (mp->
vni),
138 rv = VNET_API_ERROR_SAME_SRC_DST;
144 rv = VNET_API_ERROR_INVALID_SW_IF_INDEX;
180 rmp->
vni = htonl (t->
vni);
229 #include <geneve/geneve.api.c>
250 #include <vpp/app/version.h>
254 .version = VPP_BUILD_VER,
255 .description =
"GENEVE Tunnels",
u32 * tunnel_index_by_sw_if_index
vnet_interface_main_t * im
#define VALIDATE_SW_IF_INDEX(mp)
static vl_api_registration_t * vl_api_client_index_to_registration(u32 index)
static u32 geneve_base_msg_id
Base message ID fot the plugin.
#define REPLY_MACRO2(t, body)
#define REPLY_MSG_ID_BASE
vl_api_address_t dst_address
int vnet_geneve_add_del_tunnel(vnet_geneve_add_del_tunnel_args_t *a, u32 *sw_if_indexp)
ip4_main_t ip4_main
Global ip4 main structure.
static void vl_api_send_msg(vl_api_registration_t *rp, u8 *elem)
static uword ip46_address_is_multicast(const ip46_address_t *a)
vl_api_address_t remote_address
static int ip46_address_cmp(const ip46_address_t *ip46_1, const ip46_address_t *ip46_2)
static u8 ip46_address_is_ip4(const ip46_address_t *ip46)
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
geneve_main_t geneve_main
static void vl_api_geneve_add_del_tunnel_t_handler(vl_api_geneve_add_del_tunnel_t *mp)
vl_api_address_t local_address
ip46_type_t ip_address_decode(const vl_api_address_t *in, ip46_address_t *out)
Decode/Encode for struct/union types.
#define pool_foreach(VAR, POOL)
Iterate through pool.
void vnet_int_geneve_bypass_mode(u32 sw_if_index, u8 is_ip6, u8 is_enable)
vl_api_address_t remote_address
#define vec_len(v)
Number of elements in vector (rvalue-only, NULL tolerant)
static void send_geneve_tunnel_details(geneve_tunnel_t *t, vl_api_registration_t *reg, u32 context)
static clib_error_t * geneve_api_hookup(vlib_main_t *vm)
u32 ft_table_id
Table ID (hash key) for this FIB.
An API client registration, only in vpp/vlib.
static void setup_message_id_table(api_main_t *am)
vl_api_interface_index_t sw_if_index
static api_main_t * vlibapi_get_main(void)
vl_api_interface_index_t sw_if_index
Interface set geneve-bypass request.
vl_api_interface_index_t sw_if_index
struct fib_table_t_ * fibs
vl_api_interface_index_t mcast_sw_if_index
#define BAD_SW_IF_INDEX_LABEL
vl_api_interface_index_t mcast_sw_if_index
API main structure, used by both vpp and binary API clients.
static uword vnet_sw_if_index_is_api_valid(u32 sw_if_index)
geneve_tunnel_t * tunnels
static void vl_api_sw_interface_set_geneve_bypass_t_handler(vl_api_sw_interface_set_geneve_bypass_t *mp)
struct fib_table_t_ * fibs
Vector of FIBs.
vl_api_address_t src_address
vl_api_interface_index_t sw_if_index
VLIB_API_INIT_FUNCTION(geneve_api_hookup)
vl_api_interface_index_t sw_if_index
clib_memset(h->entries, 0, sizeof(h->entries[0]) *entries)
void ip_address_encode(const ip46_address_t *in, ip46_type_t type, vl_api_address_t *out)
static void vl_api_geneve_tunnel_dump_t_handler(vl_api_geneve_tunnel_dump_t *mp)
vl_api_interface_index_t mcast_sw_if_index
vl_api_address_t local_address
vl_api_interface_index_t sw_if_index
void * vl_msg_api_alloc(int nbytes)
static void vl_api_geneve_add_del_tunnel2_t_handler(vl_api_geneve_add_del_tunnel2_t *mp)