-/*
- * l2_api_hookup
- * Add vpe's API message handlers to the table.
- * vlib has already mapped shared memory and
- * added the client registration handlers.
- * See .../vlib-api/vlibmemory/memclnt_vlib.c:memclnt_process()
- */
-#define vl_msg_name_crc_list
-#include <l2e/l2e_all_api_h.h>
-#undef vl_msg_name_crc_list
-
-static void
-setup_message_id_table (api_main_t * am)
-{
- l2_emulation_main_t *l2em = &l2_emulation_main;
-#define _(id,n,crc) \
- vl_msg_api_add_msg_name_crc (am, #n "_" #crc, id + L2E_MSG_BASE);
- foreach_vl_msg_name_crc_l2e;
-#undef _
-}
-
-static void
-l2e_api_hookup (vlib_main_t * vm)
-{
- l2_emulation_main_t *l2em = &l2_emulation_main;
-#define _(N,n) \
- vl_msg_api_set_handlers(VL_API_##N + L2E_MSG_BASE, \
- #n, \
- vl_api_##n##_t_handler, \
- vl_noop_handler, \
- vl_api_##n##_t_endian, \
- vl_api_##n##_t_print, \
- sizeof(vl_api_##n##_t), 1);
- foreach_l2e_api_msg;
-#undef _
-}
-