vl_api_ip_neighbor_details_t *mp;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_NEIGHBOR_DETAILS);
mp->context = context;
mp->sw_if_index = htonl (sw_if_index);
mp = vl_msg_api_alloc (sizeof (*mp) + path_count * sizeof (*fp));
if (!mp)
return;
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_FIB_DETAILS);
mp->context = context;
mp = vl_msg_api_alloc (sizeof (*mp) + path_count * sizeof (*fp));
if (!mp)
return;
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP6_FIB_DETAILS);
mp->context = context;
mp = vl_msg_api_alloc (sizeof (*mp) + path_count * sizeof (*fp));
if (!mp)
return;
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_MFIB_DETAILS);
mp->context = context;
mp = vl_msg_api_alloc (sizeof (*mp) + path_count * sizeof (*fp));
if (!mp)
return;
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP6_MFIB_DETAILS);
mp->context = context;
{
ip46_address_t nh;
- memset (&nh, 0, sizeof (nh));
+ clib_memset (&nh, 0, sizeof (nh));
if (mp->is_ip6)
{
clib_memcpy (&pfx.fp_addr.ip4, mp->dst_address, sizeof (pfx.fp_addr.ip4));
ip46_address_t nh;
- memset (&nh, 0, sizeof (nh));
+ clib_memset (&nh, 0, sizeof (nh));
memcpy (&nh.ip4, mp->next_hop_address, sizeof (nh.ip4));
n_labels = mp->next_hop_n_out_labels;
clib_memcpy (&pfx.fp_addr.ip6, mp->dst_address, sizeof (pfx.fp_addr.ip6));
ip46_address_t nh;
- memset (&nh, 0, sizeof (nh));
+ clib_memset (&nh, 0, sizeof (nh));
memcpy (&nh.ip6, mp->next_hop_address, sizeof (nh.ip6));
n_labels = mp->next_hop_n_out_labels;
sizeof (pfx.fp_grp_addr.ip4));
clib_memcpy (&pfx.fp_src_addr.ip4, mp->src_address,
sizeof (pfx.fp_src_addr.ip4));
- memset (&nh.ip6, 0, sizeof (nh.ip6));
+ clib_memset (&nh.ip6, 0, sizeof (nh.ip6));
clib_memcpy (&nh.ip4, mp->nh_address, sizeof (nh.ip4));
if (!ip46_address_is_zero (&pfx.fp_src_addr))
pfx.fp_len = 64;
vl_api_ip_details_t *mp;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_DETAILS);
mp->sw_if_index = ntohl (sw_if_index);
vl_api_ip_address_details_t *mp;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_ADDRESS_DETAILS);
if (is_ipv6)
vl_api_ip_unnumbered_details_t *mp;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_UNNUMBERED_DETAILS);
mp->context = context;
vl_api_ip6nd_proxy_details_t *mp;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP6ND_PROXY_DETAILS);
mp->context = context;
mp->sw_if_index = htonl (sw_if_index);
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_MFIB_SIGNAL_DETAILS);
mp->context = context;
int rv = 0;
clib_error_t *error;
- memset (&args, 0, sizeof (args));
+ clib_memset (&args, 0, sizeof (args));
ip_set (&args.prefix.fp_addr, mp->ip, mp->is_ip4);
args.prefix.fp_len = mp->plen ? mp->plen : (mp->is_ip4 ? 32 : 128);
args.sw_if_index = clib_net_to_host_u32 (mp->sw_if_index);
if (!mp)
return 1;
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_IP_CONTAINER_PROXY_DETAILS);
mp->context = ctx->context;
if (reg && vl_api_can_send_msg (vl_reg))
{
vl_api_ip4_arp_event_t * event = vl_msg_api_alloc (sizeof *event);
- memset (event, 0, sizeof *event);
+ clib_memset (event, 0, sizeof *event);
event->_vl_msg_id = htons (VL_API_IP4_ARP_EVENT);
event->client_index = reg->client_index;
event->pid = reg->client_pid;
if (vl_reg && vl_api_can_send_msg (vl_reg))
{
vl_api_ip6_nd_event_t * event = vl_msg_api_alloc (sizeof *event);
- memset (event, 0, sizeof *event);
+ clib_memset (event, 0, sizeof *event);
event->_vl_msg_id = htons (VL_API_IP6_ND_EVENT);
event->client_index = reg->client_index;
event->pid = reg->client_pid;
sizeof (vl_api_ip6_ra_prefix_info_t);
vl_api_ip6_ra_event_t *event =
vl_msg_api_alloc (event_size);
- memset (event, 0, event_size);
+ clib_memset (event, 0, event_size);
event->_vl_msg_id = htons (VL_API_IP6_RA_EVENT);
event->client_index = reg->client_index;
event->pid = reg->client_pid;
pool_put (am->arp_events, event);
goto reply;
}
- memset (event, 0, sizeof (*event));
+ clib_memset (event, 0, sizeof (*event));
/* Python API expects events to have no context */
event->_vl_msg_id = htons (VL_API_IP4_ARP_EVENT);
pool_put (am->nd_events, event);
goto reply;
}
- memset (event, 0, sizeof (*event));
+ clib_memset (event, 0, sizeof (*event));
event->_vl_msg_id = ntohs (VL_API_IP6_ND_EVENT);
event->client_index = mp->client_index;
ctx = data;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_PROXY_ARP_DETAILS);
mp->context = ctx->context;
mp->proxy.vrf_id = htonl (fib_index);
ctx = data;
mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
+ clib_memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_PROXY_ARP_INTFC_DETAILS);
mp->context = ctx->context;
mp->sw_if_index = htonl (si->sw_if_index);
return;
vl_api_ip_reassembly_get_reply_t *rmp = vl_msg_api_alloc (sizeof (*rmp));
- memset (rmp, 0, sizeof (*rmp));
+ clib_memset (rmp, 0, sizeof (*rmp));
rmp->_vl_msg_id = ntohs (VL_API_IP_REASSEMBLY_GET_REPLY);
rmp->context = mp->context;
rmp->retval = 0;
foreach_ip_api_msg;
#undef _
+ /*
+ * Mark the route add/del API as MP safe
+ */
+ am->is_mp_safe[VL_API_IP_ADD_DEL_ROUTE] = 1;
+ am->is_mp_safe[VL_API_IP_ADD_DEL_ROUTE_REPLY] = 1;
+
/*
* Set up the (msg_name, crc, message-id) table
*/