FD.io VPP  v19.04.4-rc0-5-ge88582fac
Vector Packet Processing
session_node.c File Reference
+ Include dependency graph for session_node.c:

Go to the source code of this file.

Data Structures

struct  session_queue_trace_t
 

Macros

#define foreach_session_queue_error
 

Enumerations

enum  session_queue_error_t { SESSION_QUEUE_N_ERROR }
 
enum  { SESSION_TX_NO_BUFFERS = -2, SESSION_TX_NO_DATA, SESSION_TX_OK }
 

Functions

static void session_mq_accepted_reply_handler (void *data)
 
static void accepted_notify_cb (void *data, u32 data_len)
 
static void session_mq_reset_reply_handler (void *data)
 
static void session_mq_disconnected_handler (void *data)
 
static void session_mq_disconnected_reply_handler (void *data)
 
static void session_mq_worker_update_handler (void *data)
 
static u8format_session_queue_trace (u8 *s, va_list *args)
 
static void session_tx_trace_frame (vlib_main_t *vm, vlib_node_runtime_t *node, u32 next_index, u32 *to_next, u16 n_segs, session_t *s, u32 n_trace)
 
static void session_tx_fifo_chain_tail (vlib_main_t *vm, session_tx_context_t *ctx, vlib_buffer_t *b, u16 *n_bufs, u8 peek_data)
 
static void session_tx_fill_buffer (vlib_main_t *vm, session_tx_context_t *ctx, vlib_buffer_t *b, u16 *n_bufs, u8 peek_data)
 
static u8 session_tx_not_ready (session_t *s, u8 peek_data)
 
static transport_connection_tsession_tx_get_transport (session_tx_context_t *ctx, u8 peek_data)
 
static void session_tx_set_dequeue_params (vlib_main_t *vm, session_tx_context_t *ctx, u32 max_segs, u8 peek_data)
 
static int session_tx_fifo_read_and_snd_i (vlib_main_t *vm, vlib_node_runtime_t *node, session_worker_t *wrk, session_event_t *e, int *n_tx_packets, u8 peek_data)
 
int session_tx_fifo_peek_and_snd (vlib_main_t *vm, vlib_node_runtime_t *node, session_worker_t *wrk, session_event_t *e, int *n_tx_pkts)
 
int session_tx_fifo_dequeue_and_snd (vlib_main_t *vm, vlib_node_runtime_t *node, session_worker_t *wrk, session_event_t *e, int *n_tx_pkts)
 
int session_tx_fifo_dequeue_internal (vlib_main_t *vm, vlib_node_runtime_t *node, session_worker_t *wrk, session_event_t *e, int *n_tx_pkts)
 
static session_tsession_event_get_session (session_event_t *e, u8 thread_index)
 
static void session_update_dispatch_period (session_worker_t *wrk, f64 now, u32 thread_index)
 
static uword session_queue_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
void dump_thread_0_event_queue (void)
 
static u8 session_node_cmp_event (session_event_t *e, svm_fifo_t *f)
 
u8 session_node_lookup_fifo_event (svm_fifo_t *f, session_event_t *e)
 
static clib_error_tsession_queue_exit (vlib_main_t *vm)
 
static uword session_queue_process (vlib_main_t *vm, vlib_node_runtime_t *rt, vlib_frame_t *f)
 
static_always_inline uword session_queue_pre_input_inline (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 

Variables

vlib_node_registration_t session_queue_node
 (constructor) VLIB_REGISTER_NODE (session_queue_node) More...
 
static char * session_queue_error_strings []
 
vlib_node_registration_t session_queue_process_node
 (constructor) VLIB_REGISTER_NODE (session_queue_process_node) More...
 
vlib_node_registration_t session_queue_pre_input_node
 (constructor) VLIB_REGISTER_NODE (session_queue_pre_input_node) More...
 

Macro Definition Documentation

◆ foreach_session_queue_error

#define foreach_session_queue_error
Value:
_(TX, "Packets transmitted") \
_(TIMER, "Timer events") \
_(NO_BUFFER, "Out of buffers")

Definition at line 315 of file session_node.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
SESSION_TX_NO_BUFFERS 
SESSION_TX_NO_DATA 
SESSION_TX_OK 

Definition at line 334 of file session_node.c.

◆ session_queue_error_t

Enumerator
SESSION_QUEUE_N_ERROR 

Definition at line 320 of file session_node.c.

Function Documentation

◆ accepted_notify_cb()

static void accepted_notify_cb ( void *  data,
u32  data_len 
)
static

Definition at line 31 of file session_node.c.

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

◆ dump_thread_0_event_queue()

void dump_thread_0_event_queue ( void  )

Definition at line 1035 of file session_node.c.

+ Here is the call graph for this function:

◆ format_session_queue_trace()

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

Definition at line 304 of file session_node.c.

+ Here is the call graph for this function:

◆ session_event_get_session()

static session_t* session_event_get_session ( session_event_t *  e,
u8  thread_index 
)
inlinestatic

Definition at line 829 of file session_node.c.

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

◆ session_mq_accepted_reply_handler()

static void session_mq_accepted_reply_handler ( void *  data)
static

Definition at line 37 of file session_node.c.

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

◆ session_mq_disconnected_handler()

static void session_mq_disconnected_handler ( void *  data)
static

Definition at line 143 of file session_node.c.

+ Here is the call graph for this function:

◆ session_mq_disconnected_reply_handler()

static void session_mq_disconnected_reply_handler ( void *  data)
static

Definition at line 189 of file session_node.c.

+ Here is the call graph for this function:

◆ session_mq_reset_reply_handler()

static void session_mq_reset_reply_handler ( void *  data)
static

Definition at line 99 of file session_node.c.

+ Here is the call graph for this function:

◆ session_mq_worker_update_handler()

static void session_mq_worker_update_handler ( void *  data)
static

Definition at line 215 of file session_node.c.

+ Here is the call graph for this function:

◆ session_node_cmp_event()

static u8 session_node_cmp_event ( session_event_t *  e,
svm_fifo_t f 
)
static

Definition at line 1094 of file session_node.c.

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

◆ session_node_lookup_fifo_event()

u8 session_node_lookup_fifo_event ( svm_fifo_t f,
session_event_t *  e 
)

Definition at line 1124 of file session_node.c.

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

◆ session_queue_exit()

static clib_error_t* session_queue_exit ( vlib_main_t vm)
static

Definition at line 1171 of file session_node.c.

+ Here is the call graph for this function:

◆ session_queue_node_fn()

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

Definition at line 847 of file session_node.c.

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

◆ session_queue_pre_input_inline()

static_always_inline uword session_queue_pre_input_inline ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)

Definition at line 1234 of file session_node.c.

+ Here is the call graph for this function:

◆ session_queue_process()

static uword session_queue_process ( vlib_main_t vm,
vlib_node_runtime_t rt,
vlib_frame_t f 
)
static

Definition at line 1190 of file session_node.c.

+ Here is the call graph for this function:

◆ session_tx_fifo_chain_tail()

static void session_tx_fifo_chain_tail ( vlib_main_t vm,
session_tx_context_t ctx,
vlib_buffer_t b,
u16 n_bufs,
u8  peek_data 
)
inlinestatic

Definition at line 362 of file session_node.c.

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

◆ session_tx_fifo_dequeue_and_snd()

int session_tx_fifo_dequeue_and_snd ( vlib_main_t vm,
vlib_node_runtime_t node,
session_worker_t wrk,
session_event_t *  e,
int *  n_tx_pkts 
)

Definition at line 807 of file session_node.c.

+ Here is the call graph for this function:

◆ session_tx_fifo_dequeue_internal()

int session_tx_fifo_dequeue_internal ( vlib_main_t vm,
vlib_node_runtime_t node,
session_worker_t wrk,
session_event_t *  e,
int *  n_tx_pkts 
)

Definition at line 815 of file session_node.c.

+ Here is the call graph for this function:

◆ session_tx_fifo_peek_and_snd()

int session_tx_fifo_peek_and_snd ( vlib_main_t vm,
vlib_node_runtime_t node,
session_worker_t wrk,
session_event_t *  e,
int *  n_tx_pkts 
)

Definition at line 799 of file session_node.c.

+ Here is the call graph for this function:

◆ session_tx_fifo_read_and_snd_i()

static int session_tx_fifo_read_and_snd_i ( vlib_main_t vm,
vlib_node_runtime_t node,
session_worker_t wrk,
session_event_t *  e,
int *  n_tx_packets,
u8  peek_data 
)
inlinestatic

Definition at line 623 of file session_node.c.

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

◆ session_tx_fill_buffer()

static void session_tx_fill_buffer ( vlib_main_t vm,
session_tx_context_t ctx,
vlib_buffer_t b,
u16 n_bufs,
u8  peek_data 
)
inlinestatic

Definition at line 440 of file session_node.c.

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

◆ session_tx_get_transport()

static transport_connection_t* session_tx_get_transport ( session_tx_context_t ctx,
u8  peek_data 
)
inlinestatic

Definition at line 536 of file session_node.c.

+ Here is the caller graph for this function:

◆ session_tx_not_ready()

static u8 session_tx_not_ready ( session_t s,
u8  peek_data 
)
inlinestatic

Definition at line 521 of file session_node.c.

+ Here is the caller graph for this function:

◆ session_tx_set_dequeue_params()

static void session_tx_set_dequeue_params ( vlib_main_t vm,
session_tx_context_t ctx,
u32  max_segs,
u8  peek_data 
)
inlinestatic

Definition at line 556 of file session_node.c.

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

◆ session_tx_trace_frame()

static void session_tx_trace_frame ( vlib_main_t vm,
vlib_node_runtime_t node,
u32  next_index,
u32 to_next,
u16  n_segs,
session_t s,
u32  n_trace 
)
static

Definition at line 342 of file session_node.c.

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

◆ session_update_dispatch_period()

static void session_update_dispatch_period ( session_worker_t wrk,
f64  now,
u32  thread_index 
)
static

Definition at line 835 of file session_node.c.

+ Here is the caller graph for this function:

Variable Documentation

◆ session_queue_error_strings

char* session_queue_error_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_session_queue_error
Definition: session_node.c:315

Definition at line 328 of file session_node.c.

◆ session_queue_node

vlib_node_registration_t session_queue_node
Initial value:
=
{
.function = session_queue_node_fn,
.name = "session-queue",
.format_trace = format_session_queue_trace,
.error_strings = session_queue_error_strings,
.state = VLIB_NODE_STATE_DISABLED,
}
static uword session_queue_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: session_node.c:847
static char * session_queue_error_strings[]
Definition: session_node.c:328
#define ARRAY_LEN(x)
Definition: clib.h:62
static u8 * format_session_queue_trace(u8 *s, va_list *args)
Definition: session_node.c:304

(constructor) VLIB_REGISTER_NODE (session_queue_node)

Definition at line 294 of file session_node.c.

◆ session_queue_pre_input_node

vlib_node_registration_t session_queue_pre_input_node
Initial value:
=
{
.name = "session-queue-main",
.state = VLIB_NODE_STATE_DISABLED,
}
static_always_inline uword session_queue_pre_input_inline(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)

(constructor) VLIB_REGISTER_NODE (session_queue_pre_input_node)

Definition at line 1244 of file session_node.c.

◆ session_queue_process_node

vlib_node_registration_t session_queue_process_node
Initial value:
=
{
.function = session_queue_process,
.name = "session-queue-process",
.state = VLIB_NODE_STATE_DISABLED,
}
static uword session_queue_process(vlib_main_t *vm, vlib_node_runtime_t *rt, vlib_frame_t *f)

(constructor) VLIB_REGISTER_NODE (session_queue_process_node)

Definition at line 1224 of file session_node.c.