X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvpp%2Fapi%2Fapi.c;h=9c2381189a21c32e4fb39dbcbef8245c92846629;hb=097fa66b986f06281f603767d321ab13ab6c88c3;hp=ed769d284fc3491d54786d294e21e0a0f8814ddd;hpb=f49ba0e81e0cb9b9f8075cb4ce051b5bacde8ad3;p=vpp.git diff --git a/src/vpp/api/api.c b/src/vpp/api/api.c index ed769d284fc..9c2381189a2 100644 --- a/src/vpp/api/api.c +++ b/src/vpp/api/api.c @@ -59,6 +59,8 @@ #include #include +#include +#include #define vl_typedefs /* define message structures */ #include @@ -225,7 +227,7 @@ vl_api_cli_inband_t_handler (vl_api_cli_inband_t * mp) unformat_init_string (&input, (char *) vl_api_from_api_string (&mp->cmd), vl_api_string_len (&mp->cmd)); - vlib_cli_input (vm, &input, inband_cli_output, (uword) & out_vec); + rv = vlib_cli_input (vm, &input, inband_cli_output, (uword) & out_vec); len = vec_len (out_vec); @@ -286,8 +288,7 @@ get_thread_data (vl_api_thread_data_t * td, int index) static void vl_api_show_threads_t_handler (vl_api_show_threads_t * mp) { - vlib_main_t *vm = vlib_get_main (); - int rv = 0, count = 0; + int count = 0; #if !defined(__powerpc64__) vl_api_registration_t *reg; @@ -537,7 +538,9 @@ vpe_api_hookup (vlib_main_t * vm) /* * Thread-safe API messages */ - am->is_mp_safe[VL_API_IP_ADD_DEL_ROUTE] = 1; + am->is_mp_safe[VL_API_CONTROL_PING] = 1; + am->is_mp_safe[VL_API_CONTROL_PING_REPLY] = 1; + am->is_mp_safe[VL_API_IP_ROUTE_ADD_DEL] = 1; am->is_mp_safe[VL_API_GET_NODE_GRAPH] = 1; /* @@ -698,7 +701,7 @@ format_arp_event (u8 * s, va_list * args) vl_api_ip4_arp_event_t *event = va_arg (*args, vl_api_ip4_arp_event_t *); s = format (s, "pid %d: ", ntohl (event->pid)); - s = format (s, "resolution for %U", format_ip4_address, &event->address); + s = format (s, "resolution for %U", format_vl_api_ip4_address, event->ip); return s; } @@ -708,7 +711,7 @@ format_nd_event (u8 * s, va_list * args) vl_api_ip6_nd_event_t *event = va_arg (*args, vl_api_ip6_nd_event_t *); s = format (s, "pid %d: ", ntohl (event->pid)); - s = format (s, "resolution for %U", format_ip6_address, event->address); + s = format (s, "resolution for %U", format_vl_api_ip6_address, event->ip); return s; }