FD.io VPP  v19.08.3-2-gbabecb413
Vector Packet Processing
l2_api.c File Reference
+ Include dependency graph for l2_api.c:

Go to the source code of this file.

Macros

#define vl_typedefs   /* define message structures */
 
#define vl_endianfun   /* define message structures */
 
#define vl_api_bridge_domain_details_t_endian   vl_noop_handler
 
#define vl_api_bridge_domain_details_t_print   vl_noop_handler
 
#define vl_print(handle, ...)   vlib_cli_output (handle, __VA_ARGS__)
 
#define vl_printfun
 
#define foreach_vpe_api_msg
 
#define vl_msg_name_crc_list
 

Functions

static void send_l2_xconnect_details (vl_api_registration_t *reg, u32 context, u32 rx_sw_if_index, u32 tx_sw_if_index)
 
static void vl_api_l2_xconnect_dump_t_handler (vl_api_l2_xconnect_dump_t *mp)
 
static void vl_api_l2_fib_clear_table_t_handler (vl_api_l2_fib_clear_table_t *mp)
 
static void send_l2fib_table_entry (vpe_api_main_t *am, vl_api_registration_t *reg, l2fib_entry_key_t *l2fe_key, l2fib_entry_result_t *l2fe_res, u32 context)
 
static void vl_api_l2_fib_table_dump_t_handler (vl_api_l2_fib_table_dump_t *mp)
 
static void vl_api_l2fib_add_del_t_handler (vl_api_l2fib_add_del_t *mp)
 
static void vl_api_want_l2_macs_events_t_handler (vl_api_want_l2_macs_events_t *mp)
 
static void vl_api_l2fib_flush_int_t_handler (vl_api_l2fib_flush_int_t *mp)
 
static void vl_api_l2fib_flush_all_t_handler (vl_api_l2fib_flush_all_t *mp)
 
static void vl_api_l2fib_flush_bd_t_handler (vl_api_l2fib_flush_bd_t *mp)
 
static void vl_api_l2_flags_t_handler (vl_api_l2_flags_t *mp)
 
static void vl_api_bridge_domain_set_mac_age_t_handler (vl_api_bridge_domain_set_mac_age_t *mp)
 
static void vl_api_bridge_domain_add_del_t_handler (vl_api_bridge_domain_add_del_t *mp)
 
static void send_bridge_domain_details (l2input_main_t *l2im, vl_api_registration_t *reg, l2_bridge_domain_t *bd_config, u32 n_sw_ifs, u32 context)
 
static void vl_api_bridge_domain_dump_t_handler (vl_api_bridge_domain_dump_t *mp)
 
static bd_flags_t bd_flags_decode (vl_api_bd_flags_t v)
 
static void vl_api_bridge_flags_t_handler (vl_api_bridge_flags_t *mp)
 
static void vl_api_l2_interface_vlan_tag_rewrite_t_handler (vl_api_l2_interface_vlan_tag_rewrite_t *mp)
 
static void vl_api_l2_interface_pbb_tag_rewrite_t_handler (vl_api_l2_interface_pbb_tag_rewrite_t *mp)
 
static void vl_api_sw_interface_set_l2_xconnect_t_handler (vl_api_sw_interface_set_l2_xconnect_t *mp)
 
static int l2_bd_port_type_decode (vl_api_l2_port_type_t v, l2_bd_port_type_t *l)
 
static void vl_api_sw_interface_set_l2_bridge_t_handler (vl_api_sw_interface_set_l2_bridge_t *mp)
 
static void send_bd_ip_mac_entry (vpe_api_main_t *am, vl_api_registration_t *reg, u32 bd_id, const ip46_address_t *ip, ip46_type_t itype, const mac_address_t *mac, u32 context)
 
static void vl_api_bd_ip_mac_dump_t_handler (vl_api_bd_ip_mac_dump_t *mp)
 
static void vl_api_bd_ip_mac_add_del_t_handler (vl_api_bd_ip_mac_add_del_t *mp)
 
static void vl_api_bd_ip_mac_flush_t_handler (vl_api_bd_ip_mac_flush_t *mp)
 
void l2_efp_filter_configure (vnet_main_t *vnet_main, u32 sw_if_index, u8 enable)
 Enable/disable the EFP Filter check on the subinterface. More...
 
static void vl_api_l2_interface_efp_filter_t_handler (vl_api_l2_interface_efp_filter_t *mp)
 
static void vl_api_l2_patch_add_del_t_handler (vl_api_l2_patch_add_del_t *mp)
 
static void vl_api_sw_interface_set_vpath_t_handler (vl_api_sw_interface_set_vpath_t *mp)
 
static void vl_api_bvi_create_t_handler (vl_api_bvi_create_t *mp)
 
static void vl_api_bvi_delete_t_handler (vl_api_bvi_delete_t *mp)
 
static void setup_message_id_table (api_main_t *am)
 
static clib_error_tl2_api_hookup (vlib_main_t *vm)
 
 VLIB_API_INIT_FUNCTION (l2_api_hookup)
 

Macro Definition Documentation

◆ foreach_vpe_api_msg

#define foreach_vpe_api_msg
Value:
_(L2_XCONNECT_DUMP, l2_xconnect_dump) \
_(L2_FIB_CLEAR_TABLE, l2_fib_clear_table) \
_(L2_FIB_TABLE_DUMP, l2_fib_table_dump) \
_(L2FIB_FLUSH_ALL, l2fib_flush_all) \
_(L2FIB_FLUSH_INT, l2fib_flush_int) \
_(L2FIB_FLUSH_BD, l2fib_flush_bd) \
_(L2FIB_ADD_DEL, l2fib_add_del) \
_(WANT_L2_MACS_EVENTS, want_l2_macs_events) \
_(L2_FLAGS, l2_flags) \
_(SW_INTERFACE_SET_L2_XCONNECT, sw_interface_set_l2_xconnect) \
_(SW_INTERFACE_SET_L2_BRIDGE, sw_interface_set_l2_bridge) \
_(L2_PATCH_ADD_DEL, l2_patch_add_del) \
_(L2_INTERFACE_EFP_FILTER, l2_interface_efp_filter) \
_(BD_IP_MAC_ADD_DEL, bd_ip_mac_add_del) \
_(BD_IP_MAC_FLUSH, bd_ip_mac_flush) \
_(BD_IP_MAC_DUMP, bd_ip_mac_dump) \
_(BRIDGE_DOMAIN_ADD_DEL, bridge_domain_add_del) \
_(BRIDGE_DOMAIN_DUMP, bridge_domain_dump) \
_(BRIDGE_FLAGS, bridge_flags) \
_(L2_INTERFACE_VLAN_TAG_REWRITE, l2_interface_vlan_tag_rewrite) \
_(L2_INTERFACE_PBB_TAG_REWRITE, l2_interface_pbb_tag_rewrite) \
_(BRIDGE_DOMAIN_SET_MAC_AGE, bridge_domain_set_mac_age) \
_(SW_INTERFACE_SET_VPATH, sw_interface_set_vpath) \
_(BVI_CREATE, bvi_create) \
_(BVI_DELETE, bvi_delete)

Definition at line 55 of file l2_api.c.

◆ vl_api_bridge_domain_details_t_endian

#define vl_api_bridge_domain_details_t_endian   vl_noop_handler

Definition at line 44 of file l2_api.c.

◆ vl_api_bridge_domain_details_t_print

#define vl_api_bridge_domain_details_t_print   vl_noop_handler

Definition at line 45 of file l2_api.c.

◆ vl_endianfun

#define vl_endianfun   /* define message structures */

Definition at line 40 of file l2_api.c.

◆ vl_msg_name_crc_list

#define vl_msg_name_crc_list

Definition at line 1055 of file l2_api.c.

◆ vl_print

#define vl_print (   handle,
  ... 
)    vlib_cli_output (handle, __VA_ARGS__)

Definition at line 48 of file l2_api.c.

◆ vl_printfun

#define vl_printfun

Definition at line 49 of file l2_api.c.

◆ vl_typedefs

#define vl_typedefs   /* define message structures */

Definition at line 36 of file l2_api.c.

Function Documentation

◆ bd_flags_decode()

static bd_flags_t bd_flags_decode ( vl_api_bd_flags_t  v)
static

Definition at line 541 of file l2_api.c.

+ Here is the caller graph for this function:

◆ l2_api_hookup()

static clib_error_t* l2_api_hookup ( vlib_main_t vm)
static

Definition at line 1068 of file l2_api.c.

+ Here is the call graph for this function:

◆ l2_bd_port_type_decode()

static int l2_bd_port_type_decode ( vl_api_l2_port_type_t  v,
l2_bd_port_type_t l 
)
static

Definition at line 719 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ l2_efp_filter_configure()

void l2_efp_filter_configure ( vnet_main_t vnet_main,
u32  sw_if_index,
u8  enable 
)

Enable/disable the EFP Filter check on the subinterface.

Definition at line 505 of file l2_efp_filter.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ send_bd_ip_mac_entry()

static void send_bd_ip_mac_entry ( vpe_api_main_t am,
vl_api_registration_t reg,
u32  bd_id,
const ip46_address_t *  ip,
ip46_type_t  itype,
const mac_address_t mac,
u32  context 
)
static

Definition at line 787 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ send_bridge_domain_details()

static void send_bridge_domain_details ( l2input_main_t l2im,
vl_api_registration_t reg,
l2_bridge_domain_t bd_config,
u32  n_sw_ifs,
u32  context 
)
static

Definition at line 454 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ send_l2_xconnect_details()

static void send_l2_xconnect_details ( vl_api_registration_t reg,
u32  context,
u32  rx_sw_if_index,
u32  tx_sw_if_index 
)
static

Definition at line 83 of file l2_api.c.

+ Here is the call graph for this function:

◆ send_l2fib_table_entry()

static void send_l2fib_table_entry ( vpe_api_main_t am,
vl_api_registration_t reg,
l2fib_entry_key_t l2fe_key,
l2fib_entry_result_t l2fe_res,
u32  context 
)
static

Definition at line 136 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setup_message_id_table()

static void setup_message_id_table ( api_main_t am)
static

Definition at line 1060 of file l2_api.c.

+ Here is the caller graph for this function:

◆ vl_api_bd_ip_mac_add_del_t_handler()

static void vl_api_bd_ip_mac_add_del_t_handler ( vl_api_bd_ip_mac_add_del_t mp)
static

Definition at line 881 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bd_ip_mac_dump_t_handler()

static void vl_api_bd_ip_mac_dump_t_handler ( vl_api_bd_ip_mac_dump_t mp)
static

Definition at line 810 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bd_ip_mac_flush_t_handler()

static void vl_api_bd_ip_mac_flush_t_handler ( vl_api_bd_ip_mac_flush_t mp)
static

Definition at line 919 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bridge_domain_add_del_t_handler()

static void vl_api_bridge_domain_add_del_t_handler ( vl_api_bridge_domain_add_del_t mp)
static

Definition at line 432 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bridge_domain_dump_t_handler()

static void vl_api_bridge_domain_dump_t_handler ( vl_api_bridge_domain_dump_t mp)
static

Definition at line 502 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bridge_domain_set_mac_age_t_handler()

static void vl_api_bridge_domain_set_mac_age_t_handler ( vl_api_bridge_domain_set_mac_age_t mp)
static

Definition at line 404 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bridge_flags_t_handler()

static void vl_api_bridge_flags_t_handler ( vl_api_bridge_flags_t mp)
static

Definition at line 564 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bvi_create_t_handler()

static void vl_api_bvi_create_t_handler ( vl_api_bvi_create_t mp)
static

Definition at line 1018 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_bvi_delete_t_handler()

static void vl_api_bvi_delete_t_handler ( vl_api_bvi_delete_t mp)
static

Definition at line 1038 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2_fib_clear_table_t_handler()

static void vl_api_l2_fib_clear_table_t_handler ( vl_api_l2_fib_clear_table_t mp)
static

Definition at line 124 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2_fib_table_dump_t_handler()

static void vl_api_l2_fib_table_dump_t_handler ( vl_api_l2_fib_table_dump_t mp)
static

Definition at line 161 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2_flags_t_handler()

static void vl_api_l2_flags_t_handler ( vl_api_l2_flags_t mp)
static

Definition at line 364 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2_interface_efp_filter_t_handler()

static void vl_api_l2_interface_efp_filter_t_handler ( vl_api_l2_interface_efp_filter_t mp)
static

Definition at line 953 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2_interface_pbb_tag_rewrite_t_handler()

static void vl_api_l2_interface_pbb_tag_rewrite_t_handler ( vl_api_l2_interface_pbb_tag_rewrite_t mp)
static

Definition at line 642 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ vl_api_l2_interface_vlan_tag_rewrite_t_handler()

static void vl_api_l2_interface_vlan_tag_rewrite_t_handler ( vl_api_l2_interface_vlan_tag_rewrite_t mp)
static

Definition at line 600 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ vl_api_l2_patch_add_del_t_handler()

static void vl_api_l2_patch_add_del_t_handler ( vl_api_l2_patch_add_del_t mp)
static

Definition at line 971 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2_xconnect_dump_t_handler()

static void vl_api_l2_xconnect_dump_t_handler ( vl_api_l2_xconnect_dump_t mp)
static

Definition at line 99 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2fib_add_del_t_handler()

static void vl_api_l2fib_add_del_t_handler ( vl_api_l2fib_add_del_t mp)
static

Definition at line 200 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2fib_flush_all_t_handler()

static void vl_api_l2fib_flush_all_t_handler ( vl_api_l2fib_flush_all_t mp)
static

Definition at line 334 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2fib_flush_bd_t_handler()

static void vl_api_l2fib_flush_bd_t_handler ( vl_api_l2fib_flush_bd_t mp)
static

Definition at line 344 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_l2fib_flush_int_t_handler()

static void vl_api_l2fib_flush_int_t_handler ( vl_api_l2fib_flush_int_t mp)
static

Definition at line 318 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_sw_interface_set_l2_bridge_t_handler()

static void vl_api_sw_interface_set_l2_bridge_t_handler ( vl_api_sw_interface_set_l2_bridge_t mp)
static

Definition at line 741 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ vl_api_sw_interface_set_l2_xconnect_t_handler()

static void vl_api_sw_interface_set_l2_xconnect_t_handler ( vl_api_sw_interface_set_l2_xconnect_t mp)
static

Definition at line 678 of file l2_api.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ vl_api_sw_interface_set_vpath_t_handler()

static void vl_api_sw_interface_set_vpath_t_handler ( vl_api_sw_interface_set_vpath_t mp)
static

Definition at line 994 of file l2_api.c.

+ Here is the call graph for this function:

◆ vl_api_want_l2_macs_events_t_handler()

static void vl_api_want_l2_macs_events_t_handler ( vl_api_want_l2_macs_events_t mp)
static

Definition at line 263 of file l2_api.c.

+ Here is the call graph for this function:

◆ VLIB_API_INIT_FUNCTION()

VLIB_API_INIT_FUNCTION ( l2_api_hookup  )
+ Here is the caller graph for this function: