|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
22 #include <vpp/app/version.h>
43 return (
format (s,
"SR: dynamic_proxy_index:[%u]",
index));
69 static u8 def_str[] =
"Transit function with DT for IPv4/GTP tunnel";
70 static u8 param_str[] =
"fib-index <index> [local-fib-table <index>]";
77 s =
format (s,
"SRv6 Transit gtp4.dt\n\t");
82 s =
format (s,
" Type GTP4.DT6, fib-table %u, local-fib-table %u\n",
85 s =
format (s,
" Type GTP4.DT46, fib-table %u, local-fib-table %u\n",
96 void **plugin_mem_p = va_arg (*args,
void **);
99 u32 local_fib_index = 0;
102 if (
unformat (input,
"t.m.gtp4.dt4 fib-table %u", &fib_index))
106 else if (
unformat (input,
"t.m.gtp4.dt6 fib-table %u local-fib-table %u",
107 &fib_index, &local_fib_index))
111 else if (
unformat (input,
"t.m.gtp4.dt46 fib-table %u local-fib-table %u",
112 &fib_index, &local_fib_index))
123 *plugin_mem_p = ls_mem;
184 "couldn't be registered");
191 .arc_name =
"ip4-unicast",
192 .node_name =
"srv6-t-m-gtp4-dt",
dpo_type_t dpo_register_new_type(const dpo_vft_t *vft, const char *const *const *nodes)
Create and register a new DPO type.
static void clib_mem_free(void *p)
vlib_main_t vlib_node_runtime_t * node
#define clib_error_return(e, args...)
static int clb_creation_srv6_t_m_gtp4_dt(ip6_sr_policy_t *sr_policy)
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
static u8 * clb_format_srv6_t_m_gtp4_dt(u8 *s, va_list *args)
static void clb_dpo_lock_srv6_t_m_gtp4_dt(dpo_id_t *dpo)
const static char *const *const dpo_nodes[DPO_PROTO_NUM]
srv6_t_main_v4_dt_t srv6_t_main_v4_dt
const static char *const srv6_t_m_gtp4_dt_nodes[]
vlib_node_registration_t srv6_t_m_gtp4_dt
(constructor) VLIB_REGISTER_NODE (srv6_t_m_gtp4_dt)
static clib_error_t * srv6_t_m_gtp4_dt_init(vlib_main_t *vm)
static int clb_removal_srv6_t_m_gtp4_dt(ip6_sr_policy_t *sr_policy)
static void clb_dpo_unlock_srv6_t_m_gtp4_dt(dpo_id_t *dpo)
vnet_main_t * vnet_get_main(void)
u32 index_t
A Data-Path Object is an object that represents actions that are applied to packets are they are swit...
enum dpo_type_t_ dpo_type_t
Common types of data-path objects New types can be dynamically added using dpo_register_new_type()
int sr_policy_register_function(vlib_main_t *vm, u8 *fn_name, u8 *keyword_str, u8 *def_str, u8 *params_str, u8 prefix_length, dpo_type_t *dpo, format_function_t *ls_format, unformat_function_t *ls_unformat, sr_p_plugin_callback_t *creation_fn, sr_p_plugin_callback_t *removal_fn)
SR Policy plugin registry.
dpo_lock_fn_t dv_lock
A reference counting lock function.
const static dpo_vft_t dpo_vft
vlib_node_t * vlib_get_node_by_name(vlib_main_t *vm, u8 *name)
static u8 * clb_dpo_format_srv6_t_m_gtp4_dt(u8 *s, va_list *args)
description fragment has unexpected format
#define VLIB_INIT_FUNCTION(x)
u32 t_m_gtp4_dt_node_index
static uword clb_unformat_srv6_t_m_gtp4_dt(unformat_input_t *input, va_list *args)
clib_memset(h->entries, 0, sizeof(h->entries[0]) *entries)
A virtual function table regisitered for a DPO type.
clib_error_t *() vlib_init_function_t(struct vlib_main_t *vm)
static void * clib_mem_alloc_aligned_at_offset(uword size, uword align, uword align_offset, int os_out_of_memory_on_failure)
The identity of a DPO is a combination of its type and its instance number/index of objects of that t...
const static char *const srv6_t_m_gtp4_dt_v6_nodes[]
VNET_FEATURE_INIT(srv6_t_m_gtp4_dt, static)
u32 fib_table_find(fib_protocol_t proto, u32 table_id)
Get the index of the FIB for a Table-ID.
vl_api_fib_path_type_t type