FD.io VPP  v19.08.3-2-gbabecb413
Vector Packet Processing
l2_bvi.h File Reference
+ Include dependency graph for l2_bvi.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define TO_BVI_ERR_OK   0
 
#define TO_BVI_ERR_BAD_MAC   1
 
#define TO_BVI_ERR_ETHERTYPE   2
 

Functions

static_always_inline u32 l2_to_bvi (vlib_main_t *vlib_main, vnet_main_t *vnet_main, vlib_buffer_t *b0, u32 bvi_sw_if_index, next_by_ethertype_t *l3_next, u16 *next0)
 Send a packet from L2 processing to L3 via the BVI interface. More...
 
void l2bvi_register_input_type (vlib_main_t *vm, ethernet_type_t type, u32 node_index)
 
int l2_bvi_create (u32 instance, const mac_address_t *mac, u32 *sw_if_index)
 
int l2_bvi_delete (u32 sw_if_index)
 

Macro Definition Documentation

◆ TO_BVI_ERR_BAD_MAC

#define TO_BVI_ERR_BAD_MAC   1

Definition at line 28 of file l2_bvi.h.

◆ TO_BVI_ERR_ETHERTYPE

#define TO_BVI_ERR_ETHERTYPE   2

Definition at line 29 of file l2_bvi.h.

◆ TO_BVI_ERR_OK

#define TO_BVI_ERR_OK   0

Definition at line 27 of file l2_bvi.h.

Function Documentation

◆ l2_bvi_create()

int l2_bvi_create ( u32  instance,
const mac_address_t mac,
u32 sw_if_index 
)

Definition at line 136 of file l2_bvi.c.

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

◆ l2_bvi_delete()

int l2_bvi_delete ( u32  sw_if_index)

Definition at line 210 of file l2_bvi.c.

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

◆ l2_to_bvi()

static_always_inline u32 l2_to_bvi ( vlib_main_t vlib_main,
vnet_main_t vnet_main,
vlib_buffer_t b0,
u32  bvi_sw_if_index,
next_by_ethertype_t l3_next,
u16 next0 
)

Send a packet from L2 processing to L3 via the BVI interface.

Set next0 to the proper L3 input node. Return an error if the packet isn't what we expect.

Definition at line 38 of file l2_bvi.h.

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

◆ l2bvi_register_input_type()

void l2bvi_register_input_type ( vlib_main_t vm,
ethernet_type_t  type,
u32  node_index 
)

Definition at line 29 of file l2_bvi.c.

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