FD.io VPP  v18.07.1-19-g511ce25
Vector Packet Processing
out2in.c File Reference
+ Include dependency graph for out2in.c:

Go to the source code of this file.

Data Structures

struct  snat_out2in_trace_t
 
struct  snat_out2in_worker_handoff_trace_t
 
struct  nat44_out2in_reass_trace_t
 
struct  nat44_ed_out2in_trace_t
 

Macros

#define foreach_snat_out2in_error
 

Enumerations

enum  snat_out2in_error_t { SNAT_OUT2IN_N_ERROR }
 
enum  snat_out2in_next_t {
  SNAT_OUT2IN_NEXT_DROP, SNAT_OUT2IN_NEXT_LOOKUP, SNAT_OUT2IN_NEXT_ICMP_ERROR, SNAT_OUT2IN_NEXT_REASS,
  SNAT_OUT2IN_N_NEXT
}
 
enum  nat44_ed_out2in_next_t {
  NAT44_ED_OUT2IN_NEXT_DROP, NAT44_ED_OUT2IN_NEXT_LOOKUP, NAT44_ED_OUT2IN_NEXT_ICMP_ERROR, NAT44_ED_OUT2IN_NEXT_IN2OUT,
  NAT44_ED_OUT2IN_NEXT_SLOW_PATH, NAT44_ED_OUT2IN_N_NEXT
}
 

Functions

static u8format_snat_out2in_trace (u8 *s, va_list *args)
 
static u8format_snat_out2in_fast_trace (u8 *s, va_list *args)
 
static u8format_snat_out2in_worker_handoff_trace (u8 *s, va_list *args)
 
static u8format_nat44_out2in_reass_trace (u8 *s, va_list *args)
 
static snat_session_t * create_session_for_static_mapping (snat_main_t *sm, vlib_buffer_t *b0, snat_session_key_t in2out, snat_session_key_t out2in, vlib_node_runtime_t *node, u32 thread_index)
 Create session for static mapping. More...
 
static_always_inline snat_out2in_error_t icmp_get_key (ip4_header_t *ip0, snat_session_key_t *p_key0)
 
u32 icmp_match_out2in_slow (snat_main_t *sm, vlib_node_runtime_t *node, u32 thread_index, vlib_buffer_t *b0, ip4_header_t *ip0, u8 *p_proto, snat_session_key_t *p_value, u8 *p_dont_translate, void *d, void *e)
 Get address and port values to be used for ICMP packet translation and create session if needed. More...
 
u32 icmp_match_out2in_fast (snat_main_t *sm, vlib_node_runtime_t *node, u32 thread_index, vlib_buffer_t *b0, ip4_header_t *ip0, u8 *p_proto, snat_session_key_t *p_value, u8 *p_dont_translate, void *d, void *e)
 Get address and port values to be used for ICMP packet translation. More...
 
static u32 icmp_out2in (snat_main_t *sm, vlib_buffer_t *b0, ip4_header_t *ip0, icmp46_header_t *icmp0, u32 sw_if_index0, u32 rx_fib_index0, vlib_node_runtime_t *node, u32 next0, u32 thread_index, void *d, void *e)
 
static u32 icmp_out2in_slow_path (snat_main_t *sm, vlib_buffer_t *b0, ip4_header_t *ip0, icmp46_header_t *icmp0, u32 sw_if_index0, u32 rx_fib_index0, vlib_node_runtime_t *node, u32 next0, f64 now, u32 thread_index, snat_session_t **p_s0)
 
static int nat_out2in_sm_unknown_proto (snat_main_t *sm, vlib_buffer_t *b, ip4_header_t *ip, u32 rx_fib_index)
 
static uword snat_out2in_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (snat_out2in_node, snat_out2in_node_fn)
 
static uword nat44_out2in_reass_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (nat44_out2in_reass_node, nat44_out2in_reass_node_fn)
 
static u8format_nat44_ed_out2in_trace (u8 *s, va_list *args)
 
static snat_session_t * create_session_for_static_mapping_ed (snat_main_t *sm, vlib_buffer_t *b, snat_session_key_t l_key, snat_session_key_t e_key, vlib_node_runtime_t *node, u32 thread_index, twice_nat_type_t twice_nat, u8 is_lb)
 
static_always_inline int icmp_get_ed_key (ip4_header_t *ip0, nat_ed_ses_key_t *p_key0)
 
static int next_src_nat (snat_main_t *sm, ip4_header_t *ip, u8 proto, u16 src_port, u16 dst_port, u32 thread_index, u32 rx_fib_index)
 
static void create_bypass_for_fwd (snat_main_t *sm, ip4_header_t *ip, u32 rx_fib_index, u32 thread_index)
 
u32 icmp_match_out2in_ed (snat_main_t *sm, vlib_node_runtime_t *node, u32 thread_index, vlib_buffer_t *b, ip4_header_t *ip, u8 *p_proto, snat_session_key_t *p_value, u8 *p_dont_translate, void *d, void *e)
 
static snat_session_t * nat44_ed_out2in_unknown_proto (snat_main_t *sm, vlib_buffer_t *b, ip4_header_t *ip, u32 rx_fib_index, u32 thread_index, f64 now, vlib_main_t *vm, vlib_node_runtime_t *node)
 
static uword nat44_ed_out2in_node_fn_inline (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame, int is_slow_path)
 
static uword nat44_ed_out2in_fast_path_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (nat44_ed_out2in_node, nat44_ed_out2in_fast_path_fn)
 
static uword nat44_ed_out2in_slow_path_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (nat44_ed_out2in_slowpath_node, nat44_ed_out2in_slow_path_fn)
 
static uword snat_det_out2in_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (snat_det_out2in_node, snat_det_out2in_node_fn)
 
u32 icmp_match_out2in_det (snat_main_t *sm, vlib_node_runtime_t *node, u32 thread_index, vlib_buffer_t *b0, ip4_header_t *ip0, u8 *p_proto, snat_session_key_t *p_value, u8 *p_dont_translate, void *d, void *e)
 Get address and port values to be used for ICMP packet translation and create session if needed. More...
 
static uword snat_out2in_worker_handoff_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (snat_out2in_worker_handoff_node, snat_out2in_worker_handoff_fn)
 
static uword snat_out2in_fast_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (snat_out2in_fast_node, snat_out2in_fast_node_fn)
 

Variables

vlib_node_registration_t snat_out2in_node
 (constructor) VLIB_REGISTER_NODE (snat_out2in_node) More...
 
vlib_node_registration_t snat_out2in_fast_node
 (constructor) VLIB_REGISTER_NODE (snat_out2in_fast_node) More...
 
vlib_node_registration_t snat_out2in_worker_handoff_node
 (constructor) VLIB_REGISTER_NODE (snat_out2in_worker_handoff_node) More...
 
vlib_node_registration_t snat_det_out2in_node
 (constructor) VLIB_REGISTER_NODE (snat_det_out2in_node) More...
 
vlib_node_registration_t nat44_out2in_reass_node
 (constructor) VLIB_REGISTER_NODE (nat44_out2in_reass_node) More...
 
vlib_node_registration_t nat44_ed_out2in_node
 (constructor) VLIB_REGISTER_NODE (nat44_ed_out2in_node) More...
 
vlib_node_registration_t nat44_ed_out2in_slowpath_node
 (constructor) VLIB_REGISTER_NODE (nat44_ed_out2in_slowpath_node) More...
 
static char * snat_out2in_error_strings []
 

Macro Definition Documentation

#define foreach_snat_out2in_error
Value:
_(UNSUPPORTED_PROTOCOL, "Unsupported protocol") \
_(OUT2IN_PACKETS, "Good out2in packets processed") \
_(OUT_OF_PORTS, "Out of ports") \
_(BAD_ICMP_TYPE, "unsupported ICMP type") \
_(NO_TRANSLATION, "No translation") \
_(MAX_SESSIONS_EXCEEDED, "Maximum sessions exceeded") \
_(DROP_FRAGMENT, "Drop fragment") \
_(MAX_REASS, "Maximum reassemblies exceeded") \
_(MAX_FRAG, "Maximum fragments per reassembly exceeded")\
_(FQ_CONGESTED, "Handoff frame queue congested")

Definition at line 110 of file out2in.c.

Enumeration Type Documentation

Enumerator
NAT44_ED_OUT2IN_NEXT_DROP 
NAT44_ED_OUT2IN_NEXT_LOOKUP 
NAT44_ED_OUT2IN_NEXT_ICMP_ERROR 
NAT44_ED_OUT2IN_NEXT_IN2OUT 
NAT44_ED_OUT2IN_NEXT_SLOW_PATH 
NAT44_ED_OUT2IN_N_NEXT 

Definition at line 1539 of file out2in.c.

Enumerator
SNAT_OUT2IN_N_ERROR 

Definition at line 122 of file out2in.c.

Enumerator
SNAT_OUT2IN_NEXT_DROP 
SNAT_OUT2IN_NEXT_LOOKUP 
SNAT_OUT2IN_NEXT_ICMP_ERROR 
SNAT_OUT2IN_NEXT_REASS 
SNAT_OUT2IN_N_NEXT 

Definition at line 135 of file out2in.c.

Function Documentation

static void create_bypass_for_fwd ( snat_main_t sm,
ip4_header_t ip,
u32  rx_fib_index,
u32  thread_index 
)
static

Definition at line 1732 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static snat_session_t* create_session_for_static_mapping ( snat_main_t sm,
vlib_buffer_t b0,
snat_session_key_t  in2out,
snat_session_key_t  out2in,
vlib_node_runtime_t node,
u32  thread_index 
)
inlinestatic

Create session for static mapping.

Create NAT session initiated by host from external network with static mapping.

Parameters
smNAT main.
b0Vlib buffer.
in2outIn2out NAT44 session key.
out2inOut2in NAT44 session key.
nodeVlib node.
Returns
SNAT session if successfully created otherwise 0.

Definition at line 158 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static snat_session_t* create_session_for_static_mapping_ed ( snat_main_t sm,
vlib_buffer_t b,
snat_session_key_t  l_key,
snat_session_key_t  e_key,
vlib_node_runtime_t node,
u32  thread_index,
twice_nat_type_t  twice_nat,
u8  is_lb 
)
static

Definition at line 1572 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

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

Definition at line 1556 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

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

Definition at line 89 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

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

Definition at line 58 of file out2in.c.

+ Here is the call graph for this function:

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

Definition at line 47 of file out2in.c.

+ Here is the call graph for this function:

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

Definition at line 69 of file out2in.c.

+ Here is the call graph for this function:

static_always_inline int icmp_get_ed_key ( ip4_header_t ip0,
nat_ed_ses_key_t p_key0 
)

Definition at line 1668 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Definition at line 228 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 icmp_match_out2in_det ( snat_main_t sm,
vlib_node_runtime_t node,
u32  thread_index,
vlib_buffer_t b0,
ip4_header_t ip0,
u8 p_proto,
snat_session_key_t p_value,
u8 p_dont_translate,
void *  d,
void *  e 
)

Get address and port values to be used for ICMP packet translation and create session if needed.

Parameters
[in,out]smNAT main
[in,out]nodeNAT node runtime
[in]thread_indexthread index
[in,out]b0buffer containing packet to be translated
[out]p_protoprotocol used for matching
[out]p_valueaddress and port after NAT translation
[out]p_dont_translateif packet should not be translated
doptional parameter
eoptional parameter

Definition at line 3331 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 icmp_match_out2in_ed ( snat_main_t sm,
vlib_node_runtime_t node,
u32  thread_index,
vlib_buffer_t b,
ip4_header_t ip,
u8 p_proto,
snat_session_key_t p_value,
u8 p_dont_translate,
void *  d,
void *  e 
)

Definition at line 1822 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 icmp_match_out2in_fast ( snat_main_t sm,
vlib_node_runtime_t node,
u32  thread_index,
vlib_buffer_t b0,
ip4_header_t ip0,
u8 p_proto,
snat_session_key_t p_value,
u8 p_dont_translate,
void *  d,
void *  e 
)

Get address and port values to be used for ICMP packet translation.

Parameters
[in]smNAT main
[in,out]nodeNAT node runtime
[in]thread_indexthread index
[in,out]b0buffer containing packet to be translated
[out]p_protoprotocol used for matching
[out]p_valueaddress and port after NAT translation
[out]p_dont_translateif packet should not be translated
doptional parameter
eoptional parameter

Definition at line 404 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 icmp_match_out2in_slow ( snat_main_t sm,
vlib_node_runtime_t node,
u32  thread_index,
vlib_buffer_t b0,
ip4_header_t ip0,
u8 p_proto,
snat_session_key_t p_value,
u8 p_dont_translate,
void *  d,
void *  e 
)

Get address and port values to be used for ICMP packet translation and create session if needed.

Parameters
[in,out]smNAT main
[in,out]nodeNAT node runtime
[in]thread_indexthread index
[in,out]b0buffer containing packet to be translated
[out]p_protoprotocol used for matching
[out]p_valueaddress and port after NAT translation
[out]p_dont_translateif packet should not be translated
doptional parameter
eoptional parameter

Definition at line 286 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u32 icmp_out2in ( snat_main_t sm,
vlib_buffer_t b0,
ip4_header_t ip0,
icmp46_header_t *  icmp0,
u32  sw_if_index0,
u32  rx_fib_index0,
vlib_node_runtime_t node,
u32  next0,
u32  thread_index,
void *  d,
void *  e 
)
inlinestatic

Definition at line 463 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u32 icmp_out2in_slow_path ( snat_main_t sm,
vlib_buffer_t b0,
ip4_header_t ip0,
icmp46_header_t *  icmp0,
u32  sw_if_index0,
u32  rx_fib_index0,
vlib_node_runtime_t node,
u32  next0,
f64  now,
u32  thread_index,
snat_session_t **  p_s0 
)
inlinestatic

Definition at line 589 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword nat44_ed_out2in_fast_path_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 2761 of file out2in.c.

+ Here is the call graph for this function:

static uword nat44_ed_out2in_node_fn_inline ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame,
int  is_slow_path 
)
inlinestatic

Definition at line 2034 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword nat44_ed_out2in_slow_path_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 2795 of file out2in.c.

+ Here is the call graph for this function:

static snat_session_t* nat44_ed_out2in_unknown_proto ( snat_main_t sm,
vlib_buffer_t b,
ip4_header_t ip,
u32  rx_fib_index,
u32  thread_index,
f64  now,
vlib_main_t vm,
vlib_node_runtime_t node 
)
static

Definition at line 1929 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword nat44_out2in_reass_node_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 1250 of file out2in.c.

+ Here is the call graph for this function:

static int nat_out2in_sm_unknown_proto ( snat_main_t sm,
vlib_buffer_t b,
ip4_header_t ip,
u32  rx_fib_index 
)
static

Definition at line 615 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static int next_src_nat ( snat_main_t sm,
ip4_header_t ip,
u8  proto,
u16  src_port,
u16  dst_port,
u32  thread_index,
u32  rx_fib_index 
)
static

Definition at line 1717 of file out2in.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword snat_det_out2in_node_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 2833 of file out2in.c.

+ Here is the call graph for this function:

static uword snat_out2in_fast_node_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 3649 of file out2in.c.

+ Here is the call graph for this function:

static uword snat_out2in_node_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 647 of file out2in.c.

+ Here is the call graph for this function:

static uword snat_out2in_worker_handoff_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 3460 of file out2in.c.

+ Here is the call graph for this function:

VLIB_NODE_FUNCTION_MULTIARCH ( snat_out2in_node  ,
snat_out2in_node_fn   
)

+ Here is the caller graph for this function:

VLIB_NODE_FUNCTION_MULTIARCH ( nat44_out2in_reass_node  ,
nat44_out2in_reass_node_fn   
)
VLIB_NODE_FUNCTION_MULTIARCH ( nat44_ed_out2in_node  ,
nat44_ed_out2in_fast_path_fn   
)
VLIB_NODE_FUNCTION_MULTIARCH ( nat44_ed_out2in_slowpath_node  ,
nat44_ed_out2in_slow_path_fn   
)
VLIB_NODE_FUNCTION_MULTIARCH ( snat_det_out2in_node  ,
snat_det_out2in_node_fn   
)
VLIB_NODE_FUNCTION_MULTIARCH ( snat_out2in_worker_handoff_node  ,
snat_out2in_worker_handoff_fn   
)
VLIB_NODE_FUNCTION_MULTIARCH ( snat_out2in_fast_node  ,
snat_out2in_fast_node_fn   
)

Variable Documentation

vlib_node_registration_t nat44_ed_out2in_node
Initial value:
= {
.name = "nat44-ed-out2in",
.vector_size = sizeof (u32),
.error_strings = snat_out2in_error_strings,
.runtime_data_bytes = sizeof (snat_runtime_t),
.n_next_nodes = NAT44_ED_OUT2IN_N_NEXT,
.next_nodes = {
[NAT44_ED_OUT2IN_NEXT_DROP] = "error-drop",
[NAT44_ED_OUT2IN_NEXT_LOOKUP] = "ip4-lookup",
[NAT44_ED_OUT2IN_NEXT_SLOW_PATH] = "nat44-ed-out2in-slowpath",
[NAT44_ED_OUT2IN_NEXT_ICMP_ERROR] = "ip4-icmp-error",
[NAT44_ED_OUT2IN_NEXT_IN2OUT] = "nat44-ed-in2out",
},
}
static u8 * format_nat44_ed_out2in_trace(u8 *s, va_list *args)
Definition: out2in.c:1556
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:59
static char * snat_out2in_error_strings[]
Definition: out2in.c:129
static uword nat44_ed_out2in_fast_path_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:2761

(constructor) VLIB_REGISTER_NODE (nat44_ed_out2in_node)

Definition at line 107 of file out2in.c.

vlib_node_registration_t nat44_ed_out2in_slowpath_node
Initial value:
= {
.name = "nat44-ed-out2in-slowpath",
.vector_size = sizeof (u32),
.error_strings = snat_out2in_error_strings,
.runtime_data_bytes = sizeof (snat_runtime_t),
.n_next_nodes = NAT44_ED_OUT2IN_N_NEXT,
.next_nodes = {
[NAT44_ED_OUT2IN_NEXT_DROP] = "error-drop",
[NAT44_ED_OUT2IN_NEXT_LOOKUP] = "ip4-lookup",
[NAT44_ED_OUT2IN_NEXT_SLOW_PATH] = "nat44-ed-out2in-slowpath",
[NAT44_ED_OUT2IN_NEXT_ICMP_ERROR] = "ip4-icmp-error",
[NAT44_ED_OUT2IN_NEXT_IN2OUT] = "nat44-ed-in2out",
},
}
static u8 * format_nat44_ed_out2in_trace(u8 *s, va_list *args)
Definition: out2in.c:1556
unsigned int u32
Definition: types.h:88
static uword nat44_ed_out2in_slow_path_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:2795
#define ARRAY_LEN(x)
Definition: clib.h:59
static char * snat_out2in_error_strings[]
Definition: out2in.c:129

(constructor) VLIB_REGISTER_NODE (nat44_ed_out2in_slowpath_node)

Definition at line 108 of file out2in.c.

vlib_node_registration_t nat44_out2in_reass_node
Initial value:
= {
.name = "nat44-out2in-reass",
.vector_size = sizeof (u32),
.error_strings = snat_out2in_error_strings,
.n_next_nodes = SNAT_OUT2IN_N_NEXT,
.next_nodes = {
[SNAT_OUT2IN_NEXT_DROP] = "error-drop",
[SNAT_OUT2IN_NEXT_LOOKUP] = "ip4-lookup",
[SNAT_OUT2IN_NEXT_ICMP_ERROR] = "ip4-icmp-error",
[SNAT_OUT2IN_NEXT_REASS] = "nat44-out2in-reass",
},
}
unsigned int u32
Definition: types.h:88
static uword nat44_out2in_reass_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:1250
#define ARRAY_LEN(x)
Definition: clib.h:59
static u8 * format_nat44_out2in_reass_trace(u8 *s, va_list *args)
Definition: out2in.c:89
static char * snat_out2in_error_strings[]
Definition: out2in.c:129

(constructor) VLIB_REGISTER_NODE (nat44_out2in_reass_node)

Definition at line 106 of file out2in.c.

vlib_node_registration_t snat_det_out2in_node
Initial value:
= {
.name = "nat44-det-out2in",
.vector_size = sizeof (u32),
.format_trace = format_snat_out2in_trace,
.error_strings = snat_out2in_error_strings,
.runtime_data_bytes = sizeof (snat_runtime_t),
.n_next_nodes = SNAT_OUT2IN_N_NEXT,
.next_nodes = {
[SNAT_OUT2IN_NEXT_DROP] = "error-drop",
[SNAT_OUT2IN_NEXT_LOOKUP] = "ip4-lookup",
[SNAT_OUT2IN_NEXT_ICMP_ERROR] = "ip4-icmp-error",
[SNAT_OUT2IN_NEXT_REASS] = "nat44-out2in-reass",
},
}
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:59
static uword snat_det_out2in_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:2833
static char * snat_out2in_error_strings[]
Definition: out2in.c:129
static u8 * format_snat_out2in_trace(u8 *s, va_list *args)
Definition: out2in.c:47

(constructor) VLIB_REGISTER_NODE (snat_det_out2in_node)

Definition at line 105 of file out2in.c.

char* snat_out2in_error_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_snat_out2in_error
Definition: out2in.c:110

Definition at line 129 of file out2in.c.

vlib_node_registration_t snat_out2in_fast_node
Initial value:
= {
.name = "nat44-out2in-fast",
.vector_size = sizeof (u32),
.error_strings = snat_out2in_error_strings,
.runtime_data_bytes = sizeof (snat_runtime_t),
.n_next_nodes = SNAT_OUT2IN_N_NEXT,
.next_nodes = {
[SNAT_OUT2IN_NEXT_LOOKUP] = "ip4-lookup",
[SNAT_OUT2IN_NEXT_DROP] = "error-drop",
[SNAT_OUT2IN_NEXT_ICMP_ERROR] = "ip4-icmp-error",
[SNAT_OUT2IN_NEXT_REASS] = "nat44-out2in-reass",
},
}
static u8 * format_snat_out2in_fast_trace(u8 *s, va_list *args)
Definition: out2in.c:58
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:59
static char * snat_out2in_error_strings[]
Definition: out2in.c:129
static uword snat_out2in_fast_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:3649

(constructor) VLIB_REGISTER_NODE (snat_out2in_fast_node)

Definition at line 103 of file out2in.c.

vlib_node_registration_t snat_out2in_node
Initial value:
= {
.function = snat_out2in_node_fn,
.name = "nat44-out2in",
.vector_size = sizeof (u32),
.format_trace = format_snat_out2in_trace,
.error_strings = snat_out2in_error_strings,
.runtime_data_bytes = sizeof (snat_runtime_t),
.n_next_nodes = SNAT_OUT2IN_N_NEXT,
.next_nodes = {
[SNAT_OUT2IN_NEXT_DROP] = "error-drop",
[SNAT_OUT2IN_NEXT_LOOKUP] = "ip4-lookup",
[SNAT_OUT2IN_NEXT_ICMP_ERROR] = "ip4-icmp-error",
[SNAT_OUT2IN_NEXT_REASS] = "nat44-out2in-reass",
},
}
unsigned int u32
Definition: types.h:88
#define ARRAY_LEN(x)
Definition: clib.h:59
static char * snat_out2in_error_strings[]
Definition: out2in.c:129
static u8 * format_snat_out2in_trace(u8 *s, va_list *args)
Definition: out2in.c:47
static uword snat_out2in_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:647

(constructor) VLIB_REGISTER_NODE (snat_out2in_node)

Definition at line 102 of file out2in.c.

vlib_node_registration_t snat_out2in_worker_handoff_node
Initial value:
= {
.name = "nat44-out2in-worker-handoff",
.vector_size = sizeof (u32),
.error_strings = snat_out2in_error_strings,
.n_next_nodes = 1,
.next_nodes = {
[0] = "error-drop",
},
}
unsigned int u32
Definition: types.h:88
static uword snat_out2in_worker_handoff_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: out2in.c:3460
#define ARRAY_LEN(x)
Definition: clib.h:59
static char * snat_out2in_error_strings[]
Definition: out2in.c:129
static u8 * format_snat_out2in_worker_handoff_trace(u8 *s, va_list *args)
Definition: out2in.c:69

(constructor) VLIB_REGISTER_NODE (snat_out2in_worker_handoff_node)

Definition at line 104 of file out2in.c.