|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
38 #define vl_print(handle, ...) vlib_cli_output (handle, __VA_ARGS__)
45 #define foreach_vpe_api_msg \
46 _(SW_INTERFACE_SPAN_ENABLE_DISABLE, sw_interface_span_enable_disable) \
47 _(SW_INTERFACE_SPAN_DUMP, sw_interface_span_dump) \
53 vl_api_sw_interface_span_enable_disable_reply_t *rmp;
62 REPLY_MACRO (VL_API_SW_INTERFACE_SPAN_ENABLE_DISABLE_REPLY);
93 rmp->_vl_msg_id =
ntohs (VL_API_SW_INTERFACE_SPAN_DETAILS);
117 #define vl_msg_name_crc_list
119 #undef vl_msg_name_crc_list
124 #define _(id,n,crc) vl_msg_api_add_msg_name_crc (am, #n "_" #crc, id);
125 foreach_vl_msg_name_crc_span;
135 vl_msg_api_set_handlers(VL_API_##N, #n, \
136 vl_api_##n##_t_handler, \
138 vl_api_##n##_t_endian, \
139 vl_api_##n##_t_print, \
140 sizeof(vl_api_##n##_t), 1);
static void setup_message_id_table(api_main_t *am)
static vl_api_registration_t * vl_api_client_index_to_registration(u32 index)
Reply to SPAN dump request.
vl_api_interface_index_t sw_if_index_from
static void vl_api_send_msg(vl_api_registration_t *rp, u8 *elem)
vl_api_span_state_t state
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
VLIB_API_INIT_FUNCTION(span_api_hookup)
static void vl_api_sw_interface_span_enable_disable_t_handler(vl_api_sw_interface_span_enable_disable_t *mp)
static uword clib_bitmap_get(uword *ai, uword i)
Gets the ith bit value from a bitmap.
An API client registration, only in vpp/vlib.
clib_bitmap_t * mirror_ports
#define clib_bitmap_free(v)
Free a bitmap.
static api_main_t * vlibapi_get_main(void)
static clib_error_t * span_api_hookup(vlib_main_t *vm)
sll srl srl sll sra u16x4 i
#define foreach_vpe_api_msg
API main structure, used by both vpp and binary API clients.
static void vl_api_sw_interface_span_dump_t_handler(vl_api_sw_interface_span_dump_t *mp)
vl_api_interface_index_t sw_if_index_to
vl_api_span_state_t state
int span_add_delete_entry(vlib_main_t *vm, u32 src_sw_if_index, u32 dst_sw_if_index, u8 state, span_feat_t sf)
#define vec_foreach(var, vec)
Vector iterator.
vl_api_interface_index_t sw_if_index_from
clib_memset(h->entries, 0, sizeof(h->entries[0]) *entries)
static vlib_main_t * vlib_get_main(void)
vl_api_interface_index_t sw_if_index_to
#define clib_bitmap_foreach(i, ai)
Macro to iterate across set bits in a bitmap.
span_interface_t * interfaces
static uword * clib_bitmap_dup_or(uword *ai, uword *bi)
Logical operator across two bitmaps which duplicates the first bitmap.
Enable/Disable span to mirror traffic from one interface to another.
void * vl_msg_api_alloc(int nbytes)