FD.io VPP
v18.01-8-g0eacf49
Vector Packet Processing
|
L2 input classifier. More...
Go to the source code of this file.
Data Structures | |
struct | l2_input_classify_trace_t |
l2_input_classifier packet trace record. More... | |
struct | l2_input_classify_runtime_t |
vlib node runtime. More... | |
Macros | |
#define | foreach_l2_input_classify_error |
Enumerations | |
enum | l2_input_classify_error_t { L2_INPUT_CLASSIFY_N_ERROR } |
Variables | |
l2_input_classify_main_t | l2_input_classify_main |
l2 input classifier main data structure. More... | |
vlib_node_registration_t | l2_input_classify_node |
(constructor) VLIB_REGISTER_NODE (l2_input_classify_node) More... | |
static char * | l2_input_classify_error_strings [] |
static vlib_cli_command_t | int_l2_input_classify_cli |
(constructor) VLIB_CLI_COMMAND (int_l2_input_classify_cli) More... | |
L2 input classifier.
Definition in file l2_input_classify.c.
#define foreach_l2_input_classify_error |
Definition at line 75 of file l2_input_classify.c.
Enumerator | |
---|---|
L2_INPUT_CLASSIFY_N_ERROR |
Definition at line 81 of file l2_input_classify.c.
Packet trace format function.
Definition at line 58 of file l2_input_classify.c.
|
static |
clib_error_t* l2_input_classify_init | ( | vlib_main_t * | vm | ) |
l2 input classsifier feature initialization.
Definition at line 475 of file l2_input_classify.c.
|
static |
l2 input classifier node.
l2-input-classify
This is the l2 input classifier dispatch node
vm | vlib_main_t corresponding to the current thread. |
node | vlib_node_runtime_t data for this node. |
frame | vlib_frame_t whose contents should be dispatched. |
Uses:
(l2_input_classify_runtime_t *) rt->classify_table_index_by_sw_if_index
~0
=> send pkts to the next feature in the L2 feature chain.vnet_buffer(b)->sw_if_index[VLIB_RX]
sw_if_index
value of the interface that the packet was received on.vnet_buffer(b0)->l2.feature_bitmap
(vnet_classify_entry_t) e0->next_index
(vnet_classify_entry_t) e0->advance
vlib_buffer_advance
when the classifier hits on a session(vnet_classify_table_t) t0->miss_next_index
Sets:
vnet_buffer (b0)->l2_classify.table_index
vnet_buffer (b0)->l2_classify.hash
vnet_buffer (b0)->l2.feature_bitmap
vnet_buffer (b0)->l2_classify.opaque_index
Counters:
L2_INPUT_CLASSIFY_ERROR_MISS
Classifier missesL2_INPUT_CLASSIFY_ERROR_HIT
Classifier hitsL2_INPUT_CLASSIFY_ERROR_CHAIN_HIT
Classifier hits in other than the first table Definition at line 146 of file l2_input_classify.c.
clib_error_t* l2_input_classify_worker_init | ( | vlib_main_t * | vm | ) |
VLIB_NODE_FUNCTION_MULTIARCH | ( | l2_input_classify_node | , |
l2_input_classify_node_fn | |||
) |
VLIB_WORKER_INIT_FUNCTION | ( | l2_input_classify_worker_init | ) |
void vnet_l2_input_classify_enable_disable | ( | u32 | sw_if_index, |
int | enable_disable | ||
) |
Enable/disable l2 input classification on a specific interface.
Definition at line 518 of file l2_input_classify.c.
int vnet_l2_input_classify_set_tables | ( | u32 | sw_if_index, |
u32 | ip4_table_index, | ||
u32 | ip6_table_index, | ||
u32 | other_table_index | ||
) |
Set l2 per-protocol, per-interface input classification tables.
sw_if_index | interface handle |
ip4_table_index | ip4 classification table index, or ~0 |
ip6_table_index | ip6 classification table index, or ~0 |
other_table_index | non-ip4, non-ip6 classification table index, or ~0 |
Definition at line 536 of file l2_input_classify.c.
|
static |
(constructor) VLIB_CLI_COMMAND (int_l2_input_classify_cli)
Definition at line 647 of file l2_input_classify.c.
|
static |
Definition at line 89 of file l2_input_classify.c.
l2_input_classify_main_t l2_input_classify_main |
l2 input classifier main data structure.
Definition at line 71 of file l2_input_classify.c.
vlib_node_registration_t l2_input_classify_node |
(constructor) VLIB_REGISTER_NODE (l2_input_classify_node)
Definition at line 73 of file l2_input_classify.c.