FD.io VPP  v21.01.1
Vector Packet Processing
node.c File Reference
+ Include dependency graph for node.c:

Go to the source code of this file.

Data Structures

struct  srv6_end_rewrite_trace_t
 

Macros

#define foreach_srv6_end_v4_error
 
#define foreach_srv6_t_v4_d_error
 
#define foreach_srv6_end_v6_e_error
 
#define foreach_srv6_end_v6_d_error
 
#define foreach_srv6_end_v6_d_di_error
 
#define foreach_srv6_end_v6_dt_error
 
#define foreach_srv6_t_v4_dt_error
 

Enumerations

enum  srv6_end_error_v4_t { SRV6_END_N_V4_ERROR }
 
enum  srv6_t_error_v4_d_t { SRV6_T_N_V4_D_ERROR }
 
enum  srv6_end_error_v6_e_t { SRV6_END_N_V6_E_ERROR }
 
enum  srv6_end_error_v6_d_t { SRV6_END_N_V6_D_ERROR }
 
enum  srv6_end_error_v6_d_di_t { SRV6_END_N_V6_D_DI_ERROR }
 
enum  srv6_end_error_v6_dt_t { SRV6_END_N_V6_DT_ERROR }
 
enum  srv6_t_error_v4_dt_t { SRV6_T_N_V4_DT_ERROR }
 
enum  srv6_end_m_gtp4_e_next_t { SRV6_END_M_GTP4_E_NEXT_DROP, SRV6_END_M_GTP4_E_NEXT_LOOKUP, SRV6_END_M_GTP4_E_N_NEXT }
 
enum  srv6_T_m_gtp4_d_next_t { SRV6_T_M_GTP4_D_NEXT_DROP, SRV6_T_M_GTP4_D_NEXT_LOOKUP, SRV6_T_M_GTP4_D_N_NEXT }
 
enum  srv6_end_m_gtp6_e_next_t { SRV6_END_M_GTP6_E_NEXT_DROP, SRV6_END_M_GTP6_E_NEXT_LOOKUP, SRV6_END_M_GTP6_E_N_NEXT }
 
enum  srv6_end_m_gtp6_d_next_t { SRV6_END_M_GTP6_D_NEXT_DROP, SRV6_END_M_GTP6_D_NEXT_LOOKUP, SRV6_END_M_GTP6_D_N_NEXT }
 
enum  srv6_end_m_gtp6_d_di_next_t { SRV6_END_M_GTP6_D_DI_NEXT_DROP, SRV6_END_M_GTP6_D_DI_NEXT_LOOKUP, SRV6_END_M_GTP6_D_DI_N_NEXT }
 
enum  srv6_end_m_gtp6_dt_next_t { SRV6_END_M_GTP6_DT_NEXT_DROP, SRV6_END_M_GTP6_DT_NEXT_LOOKUP4, SRV6_END_M_GTP6_DT_NEXT_LOOKUP6, SRV6_END_M_GTP6_DT_N_NEXT }
 
enum  srv6_t_m_gtp4_dt_next_t { SRV6_T_M_GTP4_DT_NEXT_DROP, SRV6_T_M_GTP4_DT_NEXT_LOOKUP4, SRV6_T_M_GTP4_DT_NEXT_LOOKUP6, SRV6_T_M_GTP4_DT_N_NEXT }
 

Functions

static u8format_srv6_end_rewrite_trace (u8 *s, va_list *args)
 
static u8format_srv6_end_rewrite_trace6 (u8 *s, va_list *args)
 
static u16 hash_uword_to_u16 (uword *key)
 
static u8 gtpu_type_get (u16 tag)
 
VLIB_NODE_FN() srv6_end_m_gtp4_e (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() srv6_t_m_gtp4_d (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() srv6_end_m_gtp6_e (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() srv6_end_m_gtp6_d (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() srv6_end_m_gtp6_d_di (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() srv6_end_m_gtp6_dt (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() srv6_t_m_gtp4_dt (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 

Variables

ip6_address_t sr_pr_encaps_src
 
static u16 srh_tagfield [256]
 
static char * srv6_end_error_v4_strings []
 
static char * srv6_t_error_v4_d_strings []
 
static char * srv6_end_error_v6_e_strings []
 
static char * srv6_end_error_v6_d_strings []
 
static char * srv6_end_error_v6_d_di_strings []
 
static char * srv6_end_error_v6_dt_strings []
 
static char * srv6_t_error_v4_dt_strings []
 
vlib_node_registration_t srv6_end_m_gtp4_e
 (constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp4_e) More...
 
vlib_node_registration_t srv6_t_m_gtp4_d
 (constructor) VLIB_REGISTER_NODE (srv6_t_m_gtp4_d) More...
 
vlib_node_registration_t srv6_end_m_gtp6_e
 (constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_e) More...
 
vlib_node_registration_t srv6_end_m_gtp6_d
 (constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_d) More...
 
vlib_node_registration_t srv6_end_m_gtp6_d_di
 (constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_d_di) More...
 
vlib_node_registration_t srv6_end_m_gtp6_dt
 (constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_dt) More...
 
vlib_node_registration_t srv6_t_m_gtp4_dt
 (constructor) VLIB_REGISTER_NODE (srv6_t_m_gtp4_dt) More...
 

Macro Definition Documentation

◆ foreach_srv6_end_v4_error

#define foreach_srv6_end_v4_error
Value:
_(M_GTP4_E_PACKETS, "srv6 End.M.GTP4.E packets") \
_(M_GTP4_E_BAD_PACKETS, "srv6 End.M.GTP4.E bad packets")

Definition at line 112 of file node.c.

◆ foreach_srv6_end_v6_d_di_error

#define foreach_srv6_end_v6_d_di_error
Value:
_(M_GTP6_D_DI_PACKETS, "srv6 End.M.GTP6.D.DI packets") \
_(M_GTP6_D_DI_BAD_PACKETS, "srv6 End.M.GTP6.D.DI bad packets")

Definition at line 128 of file node.c.

◆ foreach_srv6_end_v6_d_error

#define foreach_srv6_end_v6_d_error
Value:
_(M_GTP6_D_PACKETS, "srv6 End.M.GTP6.D packets") \
_(M_GTP6_D_BAD_PACKETS, "srv6 End.M.GTP6.D bad packets")

Definition at line 124 of file node.c.

◆ foreach_srv6_end_v6_dt_error

#define foreach_srv6_end_v6_dt_error
Value:
_(M_GTP6_DT_PACKETS, "srv6 End.M.GTP6.DT packets") \
_(M_GTP6_DT_BAD_PACKETS, "srv6 End.M.GTP6.DT bad packets")

Definition at line 132 of file node.c.

◆ foreach_srv6_end_v6_e_error

#define foreach_srv6_end_v6_e_error
Value:
_(M_GTP6_E_PACKETS, "srv6 End.M.GTP6.E packets") \
_(M_GTP6_E_BAD_PACKETS, "srv6 End.M.GTP6.E bad packets")

Definition at line 120 of file node.c.

◆ foreach_srv6_t_v4_d_error

#define foreach_srv6_t_v4_d_error
Value:
_(M_GTP4_D_PACKETS, "srv6 T.M.GTP4.D packets") \
_(M_GTP4_D_BAD_PACKETS, "srv6 T.M.GTP4.D bad packets")

Definition at line 116 of file node.c.

◆ foreach_srv6_t_v4_dt_error

#define foreach_srv6_t_v4_dt_error
Value:
_(M_GTP4_DT_PACKETS, "srv6 T.M.GTP4.DT packets") \
_(M_GTP4_DT_BAD_PACKETS, "srv6 T.M.GTP4.DT bad packets")

Definition at line 136 of file node.c.

Enumeration Type Documentation

◆ srv6_end_error_v4_t

Enumerator
SRV6_END_N_V4_ERROR 

Definition at line 140 of file node.c.

◆ srv6_end_error_v6_d_di_t

Enumerator
SRV6_END_N_V6_D_DI_ERROR 

Definition at line 172 of file node.c.

◆ srv6_end_error_v6_d_t

Enumerator
SRV6_END_N_V6_D_ERROR 

Definition at line 164 of file node.c.

◆ srv6_end_error_v6_dt_t

Enumerator
SRV6_END_N_V6_DT_ERROR 

Definition at line 180 of file node.c.

◆ srv6_end_error_v6_e_t

Enumerator
SRV6_END_N_V6_E_ERROR 

Definition at line 156 of file node.c.

◆ srv6_end_m_gtp4_e_next_t

Enumerator
SRV6_END_M_GTP4_E_NEXT_DROP 
SRV6_END_M_GTP4_E_NEXT_LOOKUP 
SRV6_END_M_GTP4_E_N_NEXT 

Definition at line 238 of file node.c.

◆ srv6_end_m_gtp6_d_di_next_t

Enumerator
SRV6_END_M_GTP6_D_DI_NEXT_DROP 
SRV6_END_M_GTP6_D_DI_NEXT_LOOKUP 
SRV6_END_M_GTP6_D_DI_N_NEXT 

Definition at line 266 of file node.c.

◆ srv6_end_m_gtp6_d_next_t

Enumerator
SRV6_END_M_GTP6_D_NEXT_DROP 
SRV6_END_M_GTP6_D_NEXT_LOOKUP 
SRV6_END_M_GTP6_D_N_NEXT 

Definition at line 259 of file node.c.

◆ srv6_end_m_gtp6_dt_next_t

Enumerator
SRV6_END_M_GTP6_DT_NEXT_DROP 
SRV6_END_M_GTP6_DT_NEXT_LOOKUP4 
SRV6_END_M_GTP6_DT_NEXT_LOOKUP6 
SRV6_END_M_GTP6_DT_N_NEXT 

Definition at line 273 of file node.c.

◆ srv6_end_m_gtp6_e_next_t

Enumerator
SRV6_END_M_GTP6_E_NEXT_DROP 
SRV6_END_M_GTP6_E_NEXT_LOOKUP 
SRV6_END_M_GTP6_E_N_NEXT 

Definition at line 252 of file node.c.

◆ srv6_t_error_v4_d_t

Enumerator
SRV6_T_N_V4_D_ERROR 

Definition at line 148 of file node.c.

◆ srv6_t_error_v4_dt_t

Enumerator
SRV6_T_N_V4_DT_ERROR 

Definition at line 188 of file node.c.

◆ srv6_T_m_gtp4_d_next_t

Enumerator
SRV6_T_M_GTP4_D_NEXT_DROP 
SRV6_T_M_GTP4_D_NEXT_LOOKUP 
SRV6_T_M_GTP4_D_N_NEXT 

Definition at line 245 of file node.c.

◆ srv6_t_m_gtp4_dt_next_t

Enumerator
SRV6_T_M_GTP4_DT_NEXT_DROP 
SRV6_T_M_GTP4_DT_NEXT_LOOKUP4 
SRV6_T_M_GTP4_DT_NEXT_LOOKUP6 
SRV6_T_M_GTP4_DT_N_NEXT 

Definition at line 281 of file node.c.

Function Documentation

◆ format_srv6_end_rewrite_trace()

static u8* format_srv6_end_rewrite_trace ( u8 s,
va_list *  args 
)
static

Definition at line 87 of file node.c.

◆ format_srv6_end_rewrite_trace6()

static u8* format_srv6_end_rewrite_trace6 ( u8 s,
va_list *  args 
)
static

Definition at line 99 of file node.c.

◆ gtpu_type_get()

static u8 gtpu_type_get ( u16  tag)
inlinestatic

Definition at line 302 of file node.c.

+ Here is the caller graph for this function:

◆ hash_uword_to_u16()

static u16 hash_uword_to_u16 ( uword key)
inlinestatic

Definition at line 290 of file node.c.

+ Here is the caller graph for this function:

◆ srv6_end_m_gtp4_e()

VLIB_NODE_FN() srv6_end_m_gtp4_e ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 320 of file node.c.

+ Here is the call graph for this function:

◆ srv6_end_m_gtp6_d()

VLIB_NODE_FN() srv6_end_m_gtp6_d ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 1570 of file node.c.

+ Here is the call graph for this function:

◆ srv6_end_m_gtp6_d_di()

VLIB_NODE_FN() srv6_end_m_gtp6_d_di ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 2072 of file node.c.

+ Here is the call graph for this function:

◆ srv6_end_m_gtp6_dt()

VLIB_NODE_FN() srv6_end_m_gtp6_dt ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 2527 of file node.c.

+ Here is the call graph for this function:

◆ srv6_end_m_gtp6_e()

VLIB_NODE_FN() srv6_end_m_gtp6_e ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 1238 of file node.c.

+ Here is the call graph for this function:

◆ srv6_t_m_gtp4_d()

VLIB_NODE_FN() srv6_t_m_gtp4_d ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 688 of file node.c.

+ Here is the call graph for this function:

◆ srv6_t_m_gtp4_dt()

VLIB_NODE_FN() srv6_t_m_gtp4_dt ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 2748 of file node.c.

+ Here is the call graph for this function:

Variable Documentation

◆ sr_pr_encaps_src

ip6_address_t sr_pr_encaps_src

◆ srh_tagfield

u16 srh_tagfield[256]
static

Definition at line 31 of file node.c.

◆ srv6_end_error_v4_strings

char* srv6_end_error_v4_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_end_v4_error
Definition: node.c:112

Definition at line 196 of file node.c.

◆ srv6_end_error_v6_d_di_strings

char* srv6_end_error_v6_d_di_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_end_v6_d_di_error
Definition: node.c:128

Definition at line 220 of file node.c.

◆ srv6_end_error_v6_d_strings

char* srv6_end_error_v6_d_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_end_v6_d_error
Definition: node.c:124

Definition at line 214 of file node.c.

◆ srv6_end_error_v6_dt_strings

char* srv6_end_error_v6_dt_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_end_v6_dt_error
Definition: node.c:132

Definition at line 226 of file node.c.

◆ srv6_end_error_v6_e_strings

char* srv6_end_error_v6_e_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_end_v6_e_error
Definition: node.c:120

Definition at line 208 of file node.c.

◆ srv6_end_m_gtp4_e

vlib_node_registration_t srv6_end_m_gtp4_e
Initial value:
=
{
.name = "srv6-end-m-gtp4-e",.vector_size = sizeof (u32),.format_trace =
srv6_end_error_v4_strings,.n_next_nodes =
{
"error-drop",[SRV6_END_M_GTP4_E_NEXT_LOOKUP] = "ip4-lookup",}
,}
unsigned int u32
Definition: types.h:88
static u8 * format_srv6_end_rewrite_trace(u8 *s, va_list *args)
Definition: node.c:87
#define ARRAY_LEN(x)
Definition: clib.h:67
static char * srv6_end_error_v4_strings[]
Definition: node.c:196

(constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp4_e)

Definition at line 1213 of file node.c.

◆ srv6_end_m_gtp6_d

vlib_node_registration_t srv6_end_m_gtp6_d
Initial value:
=
{
.name = "srv6-end-m-gtp6-d",.vector_size = sizeof (u32),.format_trace =
{
"error-drop",[SRV6_END_M_GTP6_D_NEXT_LOOKUP] = "ip6-lookup",}
,}
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:67
static u8 * format_srv6_end_rewrite_trace6(u8 *s, va_list *args)
Definition: node.c:99
static char * srv6_end_error_v6_d_strings[]
Definition: node.c:214

(constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_d)

Definition at line 2975 of file node.c.

◆ srv6_end_m_gtp6_d_di

vlib_node_registration_t srv6_end_m_gtp6_d_di
Initial value:
=
{
.name = "srv6-end-m-gtp6-d-di",.vector_size = sizeof (u32),.format_trace =
{
,}
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:67
static u8 * format_srv6_end_rewrite_trace6(u8 *s, va_list *args)
Definition: node.c:99
static char * srv6_end_error_v6_d_di_strings[]
Definition: node.c:220

(constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_d_di)

Definition at line 2987 of file node.c.

◆ srv6_end_m_gtp6_dt

vlib_node_registration_t srv6_end_m_gtp6_dt
Initial value:
=
{
.name = "srv6-end-m-gtp6-dt",.vector_size = sizeof (u32),.format_trace =
{
"error-drop",
= "ip4-lookup",[SRV6_END_M_GTP6_DT_NEXT_LOOKUP6] = "ip6-lookup",}
,}
unsigned int u32
Definition: types.h:88
static char * srv6_end_error_v6_dt_strings[]
Definition: node.c:226
#define ARRAY_LEN(x)
Definition: clib.h:67
static u8 * format_srv6_end_rewrite_trace6(u8 *s, va_list *args)
Definition: node.c:99

(constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_dt)

Definition at line 2999 of file node.c.

◆ srv6_end_m_gtp6_e

vlib_node_registration_t srv6_end_m_gtp6_e
Initial value:
=
{
.name = "srv6-end-m-gtp6-e",.vector_size = sizeof (u32),.format_trace =
{
"error-drop",[SRV6_END_M_GTP6_E_NEXT_LOOKUP] = "ip6-lookup",}
,}
unsigned int u32
Definition: types.h:88
static char * srv6_end_error_v6_e_strings[]
Definition: node.c:208
#define ARRAY_LEN(x)
Definition: clib.h:67
static u8 * format_srv6_end_rewrite_trace6(u8 *s, va_list *args)
Definition: node.c:99

(constructor) VLIB_REGISTER_NODE (srv6_end_m_gtp6_e)

Definition at line 2963 of file node.c.

◆ srv6_t_error_v4_d_strings

char* srv6_t_error_v4_d_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_t_v4_d_error
Definition: node.c:116

Definition at line 202 of file node.c.

◆ srv6_t_error_v4_dt_strings

char* srv6_t_error_v4_dt_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_srv6_t_v4_dt_error
Definition: node.c:136

Definition at line 232 of file node.c.

◆ srv6_t_m_gtp4_d

vlib_node_registration_t srv6_t_m_gtp4_d
Initial value:
=
{
.name = "srv6-t-m-gtp4-d",.vector_size = sizeof (u32),.format_trace =
srv6_t_error_v4_d_strings,.n_next_nodes =
SRV6_T_M_GTP4_D_N_NEXT,.next_nodes =
{
"error-drop",[SRV6_T_M_GTP4_D_NEXT_LOOKUP] = "ip6-lookup",}
,}
unsigned int u32
Definition: types.h:88
static u8 * format_srv6_end_rewrite_trace(u8 *s, va_list *args)
Definition: node.c:87
static char * srv6_t_error_v4_d_strings[]
Definition: node.c:202
#define ARRAY_LEN(x)
Definition: clib.h:67

(constructor) VLIB_REGISTER_NODE (srv6_t_m_gtp4_d)

Definition at line 1225 of file node.c.

◆ srv6_t_m_gtp4_dt

vlib_node_registration_t srv6_t_m_gtp4_dt
Initial value:
=
{
.name = "srv6-t-m-gtp4-dt",.vector_size = sizeof (u32),.format_trace =
{
"error-drop",
"ip4-lookup",[SRV6_T_M_GTP4_DT_NEXT_LOOKUP6] = "ip6-lookup",}
,}
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:67
static char * srv6_t_error_v4_dt_strings[]
Definition: node.c:232
static u8 * format_srv6_end_rewrite_trace6(u8 *s, va_list *args)
Definition: node.c:99

(constructor) VLIB_REGISTER_NODE (srv6_t_m_gtp4_dt)

Definition at line 3013 of file node.c.