|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
32 #include <ioam/ip6/ioam_cache.api_enum.h>
33 #include <ioam/ip6/ioam_cache.api_types.h>
35 #define REPLY_MSG_ID_BASE cm->msg_id_base
43 ioam_e2e_id_option_t *e2e = (ioam_e2e_id_option_t *) opt;
59 ioam_e2e_cache_option_t *e2e = (ioam_e2e_cache_option_t *) opt;
64 format (s,
"IP6_HOP_BY_HOP E2E CACHE = pool:%d idx:%d\n",
65 e2e->pool_id, e2e->pool_index);
75 ip6_address_t * sr_localsid,
u8 is_disable)
109 ip6_address_t * sr_localsid,
150 vl_api_ioam_cache_ip6_enable_disable_reply_t *rmp;
152 ip6_address_t sr_localsid;
155 sr_localsid.as_u64[0] = 0;
156 sr_localsid.as_u64[1] = 0;
159 REPLY_MACRO (VL_API_IOAM_CACHE_IP6_ENABLE_DISABLE_REPLY);
168 ip6_address_t sr_localsid;
175 else if (!address_set
183 if (is_disable == 0 && !address_set)
194 .path =
"set ioam ip6 cache",.short_help =
195 "set ioam ip6 cache sr_localsid <ip6 address> [disable]",.function =
199 #define IOAM_TS_WAIT_FOR_RESPONSES 3
208 ip6_address_t sr_localsid;
218 else if (
unformat (input,
"oneway"))
220 else if (
unformat (input,
"wait_for_responses %d", &no_of_responses))
222 else if (!address_set
229 if (is_disable == 0 && !address_set)
231 "Error: SRv6 LocalSID address is mandatory to receive response.");
234 &sr_localsid, is_disable);
242 .path =
"set ioam ip6 sr-tunnel-select",.short_help =
243 "set ioam ip6 sr-tunnel-select [disable] [oneway|rtt] [wait_for_responses <n|default 3>] \
262 for (
i = 0;
i < no_of_threads;
i++)
265 (pool found to be full: %lu times)",
i,
266 cm->ts_stats[
i].inuse,
cm->ts_stats[
i].add_failed);
304 .path =
"show ioam ip6 cache",.short_help =
308 #include <ioam/ip6/ioam_cache.api.c>
316 vlib_node_t *ip6_hbyh_node = NULL, *ip6_hbh_pop_node = NULL, *error_node =
void vlib_worker_thread_barrier_release(vlib_main_t *vm)
ioam_cache_main_t ioam_cache_main
static u8 * format_ioam_cache_ts_entry(u8 *s, va_list *args)
static u8 * format_ioam_cache_entry(u8 *s, va_list *args)
static uword vlib_node_add_next(vlib_main_t *vm, uword node, uword next_node)
ip6_address_t sr_localsid_cache
@ IP6_LOOKUP_NEXT_POP_HOP_BY_HOP
vlib_main_t vlib_node_runtime_t * node
vlib_node_registration_t ioam_cache_ts_node
(constructor) VLIB_REGISTER_NODE (ioam_cache_ts_node)
#define clib_error_return(e, args...)
static clib_error_t * show_ioam_cache_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
static int ip6_ioam_ts_cache_cleanup_rewrite(void)
static int ioam_cache_ts_table_destroy(vlib_main_t *vm)
static clib_error_t * set_ioam_tunnel_select_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
vlib_worker_thread_t * vlib_worker_threads
static u8 * ioam_e2e_id_trace_handler(u8 *s, ip6_hop_by_hop_option_t *opt)
static int ip6_ioam_ts_cache_set_rewrite(void)
static clib_error_t * ioam_cache_init(vlib_main_t *vm)
static void setup_message_id_table(api_main_t *am)
int ip6_hbh_register_option(u8 option, int options(vlib_buffer_t *b, ip6_header_t *ip, ip6_hop_by_hop_option_t *opt), u8 *trace(u8 *s, ip6_hop_by_hop_option_t *opt))
#define pool_foreach(VAR, POOL)
Iterate through pool.
#define vec_len(v)
Number of elements in vector (rvalue-only, NULL tolerant)
u32 ip6_add_from_cache_hbh_node_index
#define vlib_worker_thread_barrier_sync(X)
static clib_error_t * set_ioam_cache_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
sll srl srl sll sra u16x4 i
vnet_feature_config_main_t * cm
#define VLIB_CLI_COMMAND(x,...)
static void vl_api_ioam_cache_ip6_enable_disable_t_handler(vl_api_ioam_cache_ip6_enable_disable_t *mp)
void vlib_cli_output(vlib_main_t *vm, char *fmt,...)
u32 ip6_reset_ts_hbh_node_index
static u8 * ioam_e2e_cache_trace_handler(u8 *s, ip6_hop_by_hop_option_t *opt)
static int ioam_cache_table_init(vlib_main_t *vm)
vlib_node_t * vlib_get_node_by_name(vlib_main_t *vm, u8 *name)
u32 ip6_hbh_pop_node_index
static vlib_cli_command_t set_ioam_cache_command
(constructor) VLIB_CLI_COMMAND (set_ioam_cache_command)
vlib_node_registration_t ioam_cache_node
(constructor) VLIB_REGISTER_NODE (ioam_cache_node)
int ioam_tunnel_select_ip6_enable_disable(ioam_cache_main_t *em, u8 criteria, u8 no_of_responses, ip6_address_t *sr_localsid, u8 is_disable)
description fragment has unexpected format
#define VLIB_INIT_FUNCTION(x)
static vlib_cli_command_t set_ioam_cache_ts_command
(constructor) VLIB_CLI_COMMAND (set_ioam_cache_ts_command)
#define HBH_OPTION_TYPE_IOAM_EDGE_TO_EDGE_ID
void ioam_cache_ts_timer_node_enable(vlib_main_t *vm, u8 enable)
static int ioam_cache_table_destroy(vlib_main_t *vm)
clib_memset(h->entries, 0, sizeof(h->entries[0]) *entries)
int ioam_cache_ip6_enable_disable(ioam_cache_main_t *em, ip6_address_t *sr_localsid, u8 is_disable)
clib_error_t *() vlib_init_function_t(struct vlib_main_t *vm)
static int ioam_cache_ts_table_init(vlib_main_t *vm)
int ip6_hbh_unregister_option(u8 option)
ip6_address_t sr_localsid_ts
void ip6_hbh_set_next_override(uword next)
#define IOAM_TS_WAIT_FOR_RESPONSES
#define HBH_OPTION_TYPE_IOAM_E2E_CACHE_ID
static void ioam_cache_table_print(vlib_main_t *vm, u8 verbose)
static vlib_cli_command_t show_ioam_cache_command
(constructor) VLIB_CLI_COMMAND (show_ioam_cache_command)