/* Create a new localsid registry */
pool_get (sm->localsids, ls);
- memset (ls, 0, sizeof (*ls));
+ clib_memset (ls, 0, sizeof (*ls));
clib_memcpy (&ls->localsid, localsid_addr, sizeof (ip6_address_t));
ls->end_psp = end_psp;
int rv;
- memset (&resulting_address, 0, sizeof (ip6_address_t));
+ clib_memset (&resulting_address, 0, sizeof (ip6_address_t));
ip46_address_reset (&next_hop);
while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
vlib_cli_output (vm,
"\tAddress: \t%U\n\tBehavior: \tT (Endpoint with specific IPv6 table lookup)"
"\n\tTable: \t%u",
- format_ip6_address, &ls->localsid,
- format_vnet_sw_if_index_name, vnm, ls->vrf_index);
+ format_ip6_address, &ls->localsid, ls->vrf_index);
break;
case SR_BEHAVIOR_DX4:
vlib_cli_output (vm,
/* *INDENT-OFF* */
VLIB_CLI_COMMAND (clear_sr_localsid_counters_command, static) = {
- .path = "clear sr localsid counters",
- .short_help = "clear sr localsid counters",
+ .path = "clear sr localsid-counters",
+ .short_help = "clear sr localsid-counters",
.function = clear_sr_localsid_counters_command_fn,
};
/* *INDENT-ON* */
from = vlib_frame_vector_args (from_frame);
n_left_from = from_frame->n_vectors;
next_index = node->cached_next_index;
- u32 thread_index = vlib_get_thread_index ();
+ u32 thread_index = vm->thread_index;
while (n_left_from > 0)
{
vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
ls1 =
pool_elt_at_index (sm->localsids,
- vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
+ vnet_buffer (b1)->ip.adj_index[VLIB_TX]);
ls2 =
pool_elt_at_index (sm->localsids,
- vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
+ vnet_buffer (b2)->ip.adj_index[VLIB_TX]);
ls3 =
pool_elt_at_index (sm->localsids,
- vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
+ vnet_buffer (b3)->ip.adj_index[VLIB_TX]);
ip0 = vlib_buffer_get_current (b0);
ip1 = vlib_buffer_get_current (b1);
from = vlib_frame_vector_args (from_frame);
n_left_from = from_frame->n_vectors;
next_index = node->cached_next_index;
- u32 thread_index = vlib_get_thread_index ();
+ u32 thread_index = vm->thread_index;
while (n_left_from > 0)
{
vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
ls1 =
pool_elt_at_index (sm->localsids,
- vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
+ vnet_buffer (b1)->ip.adj_index[VLIB_TX]);
ls2 =
pool_elt_at_index (sm->localsids,
- vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
+ vnet_buffer (b2)->ip.adj_index[VLIB_TX]);
ls3 =
pool_elt_at_index (sm->localsids,
- vnet_buffer (b0)->ip.adj_index[VLIB_TX]);
+ vnet_buffer (b3)->ip.adj_index[VLIB_TX]);
end_srh_processing (node, b0, ip0, sr0, ls0, &next0, ls0->end_psp,
prev0);
plugin - sm->plugin_functions);
}
- memset (plugin, 0, sizeof (*plugin));
+ clib_memset (plugin, 0, sizeof (*plugin));
plugin->sr_localsid_function_number = (plugin - sm->plugin_functions);
plugin->sr_localsid_function_number += SR_BEHAVIOR_LAST;