FD.io VPP  v16.09
Vector Packet Processing
l2_efp_filter.c File Reference
+ Include dependency graph for l2_efp_filter.c:

Go to the source code of this file.

Data Structures

struct  l2_efp_filter_main_t
 
struct  l2_efp_filter_trace_t
 

Macros

#define foreach_l2_efp_filter_error
 

Enumerations

enum  l2_efp_filter_error_t { L2_EFP_FILTER_N_ERROR }
 
enum  l2_efp_filter_next_t { L2_EFP_FILTER_NEXT_DROP, L2_EFP_FILTER_N_NEXT }
 

Functions

static u8format_l2_efp_filter_trace (u8 *s, va_list *args)
 
static_always_inline void extract_keys (vnet_main_t *vnet_main, u32 sw_if_index0, vlib_buffer_t *b0, u32 *port_sw_if_index0, u16 *first_ethertype0, u16 *outer_id0, u16 *inner_id0, u32 *match_flags0)
 Extract fields from the packet that will be used in interface classification. More...
 
static uword l2_efp_filter_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 
clib_error_tl2_efp_filter_init (vlib_main_t *vm)
 
void l2_efp_filter_configure (vnet_main_t *vnet_main, u32 sw_if_index, u32 enable)
 Enable/disable the EFP Filter check on the subinterface. More...
 
static clib_error_tint_l2_efp_filter (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 Set subinterface egress efp filter enable/disable. More...
 

Variables

l2_efp_filter_main_t l2_efp_filter_main
 
static vlib_node_registration_t l2_efp_filter_node
 (constructor) VLIB_REGISTER_NODE (l2_efp_filter_node) More...
 
static char * l2_efp_filter_error_strings []
 
static vlib_cli_command_t int_l2_efp_filter_cli
 (constructor) VLIB_CLI_COMMAND (int_l2_efp_filter_cli) More...
 

Macro Definition Documentation

#define foreach_l2_efp_filter_error
Value:
_(L2_EFP_FILTER, "L2 EFP filter packets") \
_(DROP, "L2 EFP filter post-rewrite drops")
DROP
Definition: error.def:41

Definition at line 73 of file l2_efp_filter.c.

Enumeration Type Documentation

Enumerator
L2_EFP_FILTER_N_ERROR 

Definition at line 77 of file l2_efp_filter.c.

Enumerator
L2_EFP_FILTER_NEXT_DROP 
L2_EFP_FILTER_N_NEXT 

Definition at line 91 of file l2_efp_filter.c.

Function Documentation

static_always_inline void extract_keys ( vnet_main_t vnet_main,
u32  sw_if_index0,
vlib_buffer_t b0,
u32 port_sw_if_index0,
u16 first_ethertype0,
u16 outer_id0,
u16 inner_id0,
u32 match_flags0 
)

Extract fields from the packet that will be used in interface classification.

Definition at line 103 of file l2_efp_filter.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

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

Definition at line 52 of file l2_efp_filter.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static clib_error_t* int_l2_efp_filter ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Set subinterface egress efp filter enable/disable.

The CLI format is: set interface l2 efp-filter <interface> [disable]]

Definition at line 542 of file l2_efp_filter.c.

+ Here is the call graph for this function:

void l2_efp_filter_configure ( vnet_main_t vnet_main,
u32  sw_if_index,
u32  enable 
)

Enable/disable the EFP Filter check on the subinterface.

Definition at line 529 of file l2_efp_filter.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

clib_error_t* l2_efp_filter_init ( vlib_main_t vm)

Definition at line 504 of file l2_efp_filter.c.

+ Here is the call graph for this function:

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

Definition at line 159 of file l2_efp_filter.c.

+ Here is the call graph for this function:

Variable Documentation

vlib_cli_command_t int_l2_efp_filter_cli
static
Initial value:
= {
.path = "set interface l2 efp-filter",
.short_help = "set interface l2 efp-filter <interface> [disable]",
.function = int_l2_efp_filter,
}
static clib_error_t * int_l2_efp_filter(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Set subinterface egress efp filter enable/disable.

(constructor) VLIB_CLI_COMMAND (int_l2_efp_filter_cli)

Definition at line 572 of file l2_efp_filter.c.

char* l2_efp_filter_error_strings[]
static
Initial value:
= {
#define _(sym,string)
}
#define foreach_l2_efp_filter_error
Definition: l2_efp_filter.c:73

Definition at line 85 of file l2_efp_filter.c.

l2_efp_filter_main_t l2_efp_filter_main

Definition at line 69 of file l2_efp_filter.c.

static vlib_node_registration_t l2_efp_filter_node
static
Initial value:
= {
.function = l2_efp_filter_node_fn,
.name = "l2-efp-filter",
.vector_size = sizeof (u32),
.format_trace = format_l2_efp_filter_trace,
.error_strings = l2_efp_filter_error_strings,
.n_next_nodes = L2_EFP_FILTER_N_NEXT,
.next_nodes = {
[L2_EFP_FILTER_NEXT_DROP] = "error-drop",
},
}
bad routing header type(not 4)") sr_error (NO_MORE_SEGMENTS
static u8 * format_l2_efp_filter_trace(u8 *s, va_list *args)
Definition: l2_efp_filter.c:52
static char * l2_efp_filter_error_strings[]
Definition: l2_efp_filter.c:85
#define ARRAY_LEN(x)
Definition: clib.h:59
unsigned int u32
Definition: types.h:88
static uword l2_efp_filter_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)

(constructor) VLIB_REGISTER_NODE (l2_efp_filter_node)

Definition at line 71 of file l2_efp_filter.c.