FD.io VPP  v20.01-48-g3e0dafb74
Vector Packet Processing
node.c File Reference
+ Include dependency graph for node.c:

Go to the source code of this file.

Data Structures

struct  gso_trace_t
 

Functions

static u8format_gso_trace (u8 *s, va_list *args)
 
static_always_inline u16 tso_alloc_tx_bufs (vlib_main_t *vm, vnet_interface_per_thread_data_t *ptd, vlib_buffer_t *b0, u32 n_bytes_b0, u16 l234_sz, u16 gso_size, u16 first_data_size, gso_header_offset_t *gho)
 
static_always_inline void tso_init_buf_from_template_base (vlib_buffer_t *nb0, vlib_buffer_t *b0, u32 flags, u16 length)
 
static_always_inline void tso_init_buf_from_template (vlib_main_t *vm, vlib_buffer_t *nb0, vlib_buffer_t *b0, u16 template_data_sz, u16 gso_size, u8 **p_dst_ptr, u16 *p_dst_left, u32 next_tcp_seq, u32 flags, gso_header_offset_t *gho)
 
static_always_inline void tso_fixup_segmented_buf (vlib_buffer_t *b0, u8 tcp_flags, int is_ip6, gso_header_offset_t *gho)
 
static_always_inline u32 tso_segment_buffer (vlib_main_t *vm, vnet_interface_per_thread_data_t *ptd, u32 sbi0, vlib_buffer_t *sb0, gso_header_offset_t *gho, u32 n_bytes_b0, int is_ip6)
 Allocate the necessary number of ptd->split_buffers, and segment the possibly chained buffer(s) from b0 into there. More...
 
static_always_inline void drop_one_buffer_and_count (vlib_main_t *vm, vnet_main_t *vnm, vlib_node_runtime_t *node, u32 *pbi0, u32 sw_if_index, u32 drop_error_code)
 
static_always_inline uword vnet_gso_node_inline (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame, vnet_main_t *vnm, vnet_hw_interface_t *hi, int is_ip6, int do_segmentation)
 
static_always_inline uword vnet_gso_inline (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame, int is_ip6)
 
VLIB_NODE_FN() gso_l2_ip4_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() gso_l2_ip6_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() gso_ip4_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
VLIB_NODE_FN() gso_ip6_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
 VNET_FEATURE_INIT (gso_l2_ip4_node, static)
 
 VNET_FEATURE_INIT (gso_l2_ip6_node, static)
 
 VNET_FEATURE_INIT (gso_ip4_node, static)
 
 VNET_FEATURE_INIT (gso_ip6_node, static)
 

Variables

vlib_node_registration_t gso_l2_ip4_node
 (constructor) VLIB_REGISTER_NODE (gso_l2_ip4_node) More...
 
vlib_node_registration_t gso_l2_ip6_node
 (constructor) VLIB_REGISTER_NODE (gso_l2_ip6_node) More...
 
vlib_node_registration_t gso_ip4_node
 (constructor) VLIB_REGISTER_NODE (gso_ip4_node) More...
 
vlib_node_registration_t gso_ip6_node
 (constructor) VLIB_REGISTER_NODE (gso_ip6_node) More...
 

Function Documentation

◆ drop_one_buffer_and_count()

static_always_inline void drop_one_buffer_and_count ( vlib_main_t vm,
vnet_main_t vnm,
vlib_node_runtime_t node,
u32 pbi0,
u32  sw_if_index,
u32  drop_error_code 
)

Definition at line 285 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ format_gso_trace()

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

Definition at line 35 of file node.c.

+ Here is the call graph for this function:

◆ gso_ip4_node()

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

Definition at line 602 of file node.c.

+ Here is the call graph for this function:

◆ gso_ip6_node()

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

Definition at line 608 of file node.c.

+ Here is the call graph for this function:

◆ gso_l2_ip4_node()

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

Definition at line 590 of file node.c.

+ Here is the call graph for this function:

◆ gso_l2_ip6_node()

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

Definition at line 596 of file node.c.

+ Here is the call graph for this function:

◆ tso_alloc_tx_bufs()

static_always_inline u16 tso_alloc_tx_bufs ( vlib_main_t vm,
vnet_interface_per_thread_data_t ptd,
vlib_buffer_t b0,
u32  n_bytes_b0,
u16  l234_sz,
u16  gso_size,
u16  first_data_size,
gso_header_offset_t gho 
)

Definition at line 55 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tso_fixup_segmented_buf()

static_always_inline void tso_fixup_segmented_buf ( vlib_buffer_t b0,
u8  tcp_flags,
int  is_ip6,
gso_header_offset_t gho 
)

Definition at line 136 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tso_init_buf_from_template()

static_always_inline void tso_init_buf_from_template ( vlib_main_t vm,
vlib_buffer_t nb0,
vlib_buffer_t b0,
u16  template_data_sz,
u16  gso_size,
u8 **  p_dst_ptr,
u16 p_dst_left,
u32  next_tcp_seq,
u32  flags,
gso_header_offset_t gho 
)

Definition at line 116 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tso_init_buf_from_template_base()

static_always_inline void tso_init_buf_from_template_base ( vlib_buffer_t nb0,
vlib_buffer_t b0,
u32  flags,
u16  length 
)

Definition at line 102 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tso_segment_buffer()

static_always_inline u32 tso_segment_buffer ( vlib_main_t vm,
vnet_interface_per_thread_data_t ptd,
u32  sbi0,
vlib_buffer_t sb0,
gso_header_offset_t gho,
u32  n_bytes_b0,
int  is_ip6 
)

Allocate the necessary number of ptd->split_buffers, and segment the possibly chained buffer(s) from b0 into there.

Return the cumulative number of bytes sent or zero if allocation failed.

Definition at line 166 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ VNET_FEATURE_INIT() [1/4]

VNET_FEATURE_INIT ( gso_l2_ip4_node  ,
static   
)

◆ VNET_FEATURE_INIT() [2/4]

VNET_FEATURE_INIT ( gso_l2_ip6_node  ,
static   
)

◆ VNET_FEATURE_INIT() [3/4]

VNET_FEATURE_INIT ( gso_ip4_node  ,
static   
)

◆ VNET_FEATURE_INIT() [4/4]

VNET_FEATURE_INIT ( gso_ip6_node  ,
static   
)

◆ vnet_gso_inline()

static_always_inline uword vnet_gso_inline ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame,
int  is_ip6 
)

Definition at line 567 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ vnet_gso_node_inline()

static_always_inline uword vnet_gso_node_inline ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame,
vnet_main_t vnm,
vnet_hw_interface_t hi,
int  is_ip6,
int  do_segmentation 
)

Definition at line 305 of file node.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ gso_ip4_node

Initial value:
= {
.vector_size = sizeof (u32),
.format_trace = format_gso_trace,
.n_errors = 0,
.n_next_nodes = 0,
.name = "gso-ip4",
}
unsigned int u32
Definition: types.h:88
vl_api_fib_path_type_t type
Definition: fib_types.api:123
string name[64]
Definition: ip.api:44
static u8 * format_gso_trace(u8 *s, va_list *args)
Definition: node.c:35

(constructor) VLIB_REGISTER_NODE (gso_ip4_node)

Definition at line 634 of file node.c.

◆ gso_ip6_node

Initial value:
= {
.vector_size = sizeof (u32),
.format_trace = format_gso_trace,
.n_errors = 0,
.n_next_nodes = 0,
.name = "gso-ip6",
}
unsigned int u32
Definition: types.h:88
vl_api_fib_path_type_t type
Definition: fib_types.api:123
string name[64]
Definition: ip.api:44
static u8 * format_gso_trace(u8 *s, va_list *args)
Definition: node.c:35

(constructor) VLIB_REGISTER_NODE (gso_ip6_node)

Definition at line 643 of file node.c.

◆ gso_l2_ip4_node

vlib_node_registration_t gso_l2_ip4_node
Initial value:
= {
.vector_size = sizeof (u32),
.format_trace = format_gso_trace,
.n_errors = 0,
.n_next_nodes = 0,
.name = "gso-l2-ip4",
}
unsigned int u32
Definition: types.h:88
vl_api_fib_path_type_t type
Definition: fib_types.api:123
string name[64]
Definition: ip.api:44
static u8 * format_gso_trace(u8 *s, va_list *args)
Definition: node.c:35

(constructor) VLIB_REGISTER_NODE (gso_l2_ip4_node)

Definition at line 616 of file node.c.

◆ gso_l2_ip6_node

vlib_node_registration_t gso_l2_ip6_node
Initial value:
= {
.vector_size = sizeof (u32),
.format_trace = format_gso_trace,
.n_errors = 0,
.n_next_nodes = 0,
.name = "gso-l2-ip6",
}
unsigned int u32
Definition: types.h:88
vl_api_fib_path_type_t type
Definition: fib_types.api:123
string name[64]
Definition: ip.api:44
static u8 * format_gso_trace(u8 *s, va_list *args)
Definition: node.c:35

(constructor) VLIB_REGISTER_NODE (gso_l2_ip6_node)

Definition at line 625 of file node.c.