FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
wireguard_output_tun.c File Reference
+ Include dependency graph for wireguard_output_tun.c:

Go to the source code of this file.

Data Structures

struct  wg_output_tun_trace_t
 

Macros

#define foreach_wg_output_error
 

Enumerations

enum  wg_output_error_t { WG_OUTPUT_N_ERROR }
 
enum  wg_output_next_t { WG_OUTPUT_NEXT_ERROR, WG_OUTPUT_NEXT_HANDOFF, WG_OUTPUT_NEXT_INTERFACE_OUTPUT, WG_OUTPUT_N_NEXT }
 

Functions

u8format_ip4_udp_header (u8 *s, va_list *args)
 
static u8format_wg_output_tun_trace (u8 *s, va_list *args)
 
VLIB_NODE_FN() wg_output_tun_node (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 

Variables

static char * wg_output_error_strings []
 
vlib_node_registration_t wg_output_tun_node
 (constructor) VLIB_REGISTER_NODE (wg_output_tun_node) More...
 

Macro Definition Documentation

◆ foreach_wg_output_error

#define foreach_wg_output_error
Value:
_(NONE, "No error") \
_(PEER, "Peer error") \
_(KEYPAIR, "Keypair error") \
_(TOO_BIG, "packet too big") \

Definition at line 24 of file wireguard_output_tun.c.

Enumeration Type Documentation

◆ wg_output_error_t

Enumerator
WG_OUTPUT_N_ERROR 

Definition at line 30 of file wireguard_output_tun.c.

◆ wg_output_next_t

Enumerator
WG_OUTPUT_NEXT_ERROR 
WG_OUTPUT_NEXT_HANDOFF 
WG_OUTPUT_NEXT_INTERFACE_OUTPUT 
WG_OUTPUT_N_NEXT 

Definition at line 44 of file wireguard_output_tun.c.

Function Documentation

◆ format_ip4_udp_header()

u8* format_ip4_udp_header ( u8 s,
va_list *  args 
)

Definition at line 59 of file wireguard_output_tun.c.

+ Here is the caller graph for this function:

◆ format_wg_output_tun_trace()

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

Definition at line 71 of file wireguard_output_tun.c.

+ Here is the call graph for this function:

◆ wg_output_tun_node()

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

Definition at line 83 of file wireguard_output_tun.c.

+ Here is the call graph for this function:

Variable Documentation

◆ wg_output_error_strings

char* wg_output_error_strings[]
static
Initial value:
= {
#define _(sym,string)
}

Definition at line 38 of file wireguard_output_tun.c.

◆ wg_output_tun_node

vlib_node_registration_t wg_output_tun_node
Initial value:
=
{
.name = "wg-output-tun",
.vector_size = sizeof (u32),
.format_trace = format_wg_output_tun_trace,
.error_strings = wg_output_error_strings,
.n_next_nodes = WG_OUTPUT_N_NEXT,
.next_nodes = {
[WG_OUTPUT_NEXT_HANDOFF] = "wg-output-tun-handoff",
[WG_OUTPUT_NEXT_INTERFACE_OUTPUT] = "adj-midchain-tx",
[WG_OUTPUT_NEXT_ERROR] = "error-drop",
},
}

(constructor) VLIB_REGISTER_NODE (wg_output_tun_node)

Definition at line 218 of file wireguard_output_tun.c.

wg_output_error_strings
static char * wg_output_error_strings[]
Definition: wireguard_output_tun.c:38
VLIB_NODE_TYPE_INTERNAL
@ VLIB_NODE_TYPE_INTERNAL
Definition: node.h:72
WG_OUTPUT_N_NEXT
@ WG_OUTPUT_N_NEXT
Definition: wireguard_output_tun.c:49
format_wg_output_tun_trace
static u8 * format_wg_output_tun_trace(u8 *s, va_list *args)
Definition: wireguard_output_tun.c:71
WG_OUTPUT_NEXT_HANDOFF
@ WG_OUTPUT_NEXT_HANDOFF
Definition: wireguard_output_tun.c:47
ARRAY_LEN
#define ARRAY_LEN(x)
Definition: clib.h:70
u32
unsigned int u32
Definition: types.h:88
WG_OUTPUT_NEXT_INTERFACE_OUTPUT
@ WG_OUTPUT_NEXT_INTERFACE_OUTPUT
Definition: wireguard_output_tun.c:48
foreach_wg_output_error
#define foreach_wg_output_error
Definition: wireguard_output_tun.c:24
type
vl_api_fib_path_type_t type
Definition: fib_types.api:123
WG_OUTPUT_NEXT_ERROR
@ WG_OUTPUT_NEXT_ERROR
Definition: wireguard_output_tun.c:46