FD.io VPP  v19.04-6-g6f05f72
Vector Packet Processing
udp_local.c File Reference
+ Include dependency graph for udp_local.c:

Go to the source code of this file.

Data Structures

struct  udp_local_rx_trace_t
 

Macros

#define foreach_udp_local_next
 
#define udp_local_next_drop(is_ip4)   ((is_ip4) ? UDP_LOCAL_NEXT_DROP4 : UDP_LOCAL_NEXT_DROP6)
 
#define udp_local_next_punt(is_ip4)   ((is_ip4) ? UDP_LOCAL_NEXT_PUNT4 : UDP_LOCAL_NEXT_PUNT6)
 
#define udp_error(n, s)   s,
 

Enumerations

enum  udp_local_next_t { UDP_LOCAL_N_NEXT }
 

Functions

u8format_udp_rx_trace (u8 *s, va_list *args)
 
static uword udp46_local_inline (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame, int is_ip4)
 
VLIB_NODE_FN() udp4_local_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)
 
VLIB_NODE_FN() udp6_local_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)
 
static void add_dst_port (udp_main_t *um, udp_dst_port_t dst_port, char *dst_port_name, u8 is_ip4)
 
void udp_register_dst_port (vlib_main_t *vm, udp_dst_port_t dst_port, u32 node_index, u8 is_ip4)
 
void udp_unregister_dst_port (vlib_main_t *vm, udp_dst_port_t dst_port, u8 is_ip4)
 
bool udp_is_valid_dst_port (udp_dst_port_t dst_port, u8 is_ip4)
 
void udp_punt_unknown (vlib_main_t *vm, u8 is_ip4, u8 is_add)
 
uword unformat_udp_header (unformat_input_t *input, va_list *args)
 
static void udp_setup_node (vlib_main_t *vm, u32 node_index)
 
clib_error_tudp_local_init (vlib_main_t *vm)
 

Variables

static char * udp_error_strings []
 
vlib_node_registration_t udp4_local_node
 (constructor) VLIB_REGISTER_NODE (udp4_local_node) More...
 
vlib_node_registration_t udp6_local_node
 (constructor) VLIB_REGISTER_NODE (udp6_local_node) More...
 

Macro Definition Documentation

#define foreach_udp_local_next
Value:
_ (PUNT4, "ip4-punt") \
_ (PUNT6, "ip6-punt") \
_ (DROP4, "ip4-drop") \
_ (DROP6, "ip6-drop") \
_ (ICMP4_ERROR, "ip4-icmp-error") \
_ (ICMP6_ERROR, "ip6-icmp-error")

Definition at line 24 of file udp_local.c.

#define udp_error (   n,
 
)    s,
#define udp_local_next_drop (   is_ip4)    ((is_ip4) ? UDP_LOCAL_NEXT_DROP4 : UDP_LOCAL_NEXT_DROP6)

Definition at line 40 of file udp_local.c.

#define udp_local_next_punt (   is_ip4)    ((is_ip4) ? UDP_LOCAL_NEXT_PUNT4 : UDP_LOCAL_NEXT_PUNT6)

Definition at line 41 of file udp_local.c.

Enumeration Type Documentation

Enumerator
UDP_LOCAL_N_NEXT 

Definition at line 32 of file udp_local.c.

Function Documentation

static void add_dst_port ( udp_main_t um,
udp_dst_port_t  dst_port,
char *  dst_port_name,
u8  is_ip4 
)
static

Definition at line 464 of file udp_local.c.

+ Here is the caller graph for this function:

u8* format_udp_rx_trace ( u8 s,
va_list *  args 
)

Definition at line 52 of file udp_local.c.

+ Here is the call graph for this function:

static uword udp46_local_inline ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame,
int  is_ip4 
)
inlinestatic

Definition at line 67 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

VLIB_NODE_FN() udp4_local_node ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame 
)

Definition at line 404 of file udp_local.c.

+ Here is the call graph for this function:

VLIB_NODE_FN() udp6_local_node ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame 
)

Definition at line 411 of file udp_local.c.

+ Here is the call graph for this function:

bool udp_is_valid_dst_port ( udp_dst_port_t  dst_port,
u8  is_ip4 
)

Definition at line 545 of file udp_local.c.

+ Here is the caller graph for this function:

clib_error_t* udp_local_init ( vlib_main_t vm)

Definition at line 616 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void udp_punt_unknown ( vlib_main_t vm,
u8  is_ip4,
u8  is_add 
)

Definition at line 561 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void udp_register_dst_port ( vlib_main_t vm,
udp_dst_port_t  dst_port,
u32  node_index,
u8  is_ip4 
)

Definition at line 484 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void udp_setup_node ( vlib_main_t vm,
u32  node_index 
)
static

Definition at line 605 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void udp_unregister_dst_port ( vlib_main_t vm,
udp_dst_port_t  dst_port,
u8  is_ip4 
)

Definition at line 522 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

uword unformat_udp_header ( unformat_input_t input,
va_list *  args 
)

Definition at line 578 of file udp_local.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Variable Documentation

vlib_node_registration_t udp4_local_node
Initial value:
= {
.name = "ip4-udp-lookup",
.vector_size = sizeof (u32),
.n_errors = UDP_N_ERROR,
.error_strings = udp_error_strings,
.n_next_nodes = UDP_LOCAL_N_NEXT,
.next_nodes = {
#define _(s,n)
},
.format_buffer = format_udp_header,
.format_trace = format_udp_rx_trace,
.unformat_buffer = unformat_udp_header,
}
format_function_t format_udp_header
Definition: format.h:101
static char * udp_error_strings[]
Definition: udp_local.c:398
unsigned int u32
Definition: types.h:88
#define foreach_udp_local_next
Definition: udp_local.c:24
uword unformat_udp_header(unformat_input_t *input, va_list *args)
Definition: udp_local.c:578
u8 * format_udp_rx_trace(u8 *s, va_list *args)
Definition: udp_local.c:52

(constructor) VLIB_REGISTER_NODE (udp4_local_node)

Definition at line 419 of file udp_local.c.

vlib_node_registration_t udp6_local_node
Initial value:
= {
.name = "ip6-udp-lookup",
.vector_size = sizeof (u32),
.n_errors = UDP_N_ERROR,
.error_strings = udp_error_strings,
.n_next_nodes = UDP_LOCAL_N_NEXT,
.next_nodes = {
#define _(s,n)
},
.format_buffer = format_udp_header,
.format_trace = format_udp_rx_trace,
.unformat_buffer = unformat_udp_header,
}
format_function_t format_udp_header
Definition: format.h:101
static char * udp_error_strings[]
Definition: udp_local.c:398
unsigned int u32
Definition: types.h:88
#define foreach_udp_local_next
Definition: udp_local.c:24
uword unformat_udp_header(unformat_input_t *input, va_list *args)
Definition: udp_local.c:578
u8 * format_udp_rx_trace(u8 *s, va_list *args)
Definition: udp_local.c:52

(constructor) VLIB_REGISTER_NODE (udp6_local_node)

Definition at line 441 of file udp_local.c.

char* udp_error_strings[]
static
Initial value:
= {
#define udp_error(n,s)
udp_error (NONE, "no error")
udp_error (NO_LISTENER, "no listener for dst port")
udp_error (LENGTH_ERROR, "UDP packets with length errors")
udp_error (PUNT, "no listener punt")
udp_error (ENQUEUED, "UDP packets enqueued")
udp_error (FIFO_FULL, "UDP fifo full")
udp_error (NOT_READY, "UDP connection not ready")
udp_error (LISTENER, "UDP connected session")
udp_error (CREATE_SESSION, "Failed to create UDP session")
udp_error (EVENT_FIFO_FULL, "UDP session event fifo full")
}
for(i=1;i<=collision_buckets;i++)
vl_api_ip4_address_t dst
Definition: ipsec_gre.api:39
#define udp_error(n, s)

Definition at line 398 of file udp_local.c.