FD.io VPP  v16.06
Vector Packet Processing
l2_bd.h File Reference
+ Include dependency graph for l2_bd.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  bd_main_t
 
struct  l2_flood_member_t
 
struct  l2_bridge_domain_t
 

Macros

#define L2_FLOOD_MEMBER_NORMAL   0
 
#define L2_FLOOD_MEMBER_BVI   1
 
#define L2_LEARN   (1<<0)
 
#define L2_FWD   (1<<1)
 
#define L2_FLOOD   (1<<2)
 
#define L2_UU_FLOOD   (1<<3)
 
#define L2_ARP_TERM   (1<<4)
 

Functions

always_inline u32 bd_is_valid (l2_bridge_domain_t *bd_config)
 
void bd_validate (l2_bridge_domain_t *bd_config)
 
void bd_add_member (l2_bridge_domain_t *bd_config, l2_flood_member_t *member)
 
u32 bd_remove_member (l2_bridge_domain_t *bd_config, u32 sw_if_index)
 
u32 bd_set_flags (vlib_main_t *vm, u32 bd_index, u32 flags, u32 enable)
 
u32 bd_find_or_add_bd_index (bd_main_t *bdm, u32 bd_id)
 Get or create a bridge domain. More...
 
int bd_delete_bd_index (bd_main_t *bdm, u32 bd_id)
 Delete a bridge domain. More...
 
u32 bd_add_del_ip_mac (u32 bd_index, u8 *ip_addr, u8 *mac_addr, u8 is_ip6, u8 is_add)
 

Variables

bd_main_t bd_main
 

Macro Definition Documentation

#define L2_ARP_TERM   (1<<4)

Definition at line 99 of file l2_bd.h.

#define L2_FLOOD   (1<<2)

Definition at line 97 of file l2_bd.h.

#define L2_FLOOD_MEMBER_BVI   1

Definition at line 41 of file l2_bd.h.

#define L2_FLOOD_MEMBER_NORMAL   0

Definition at line 40 of file l2_bd.h.

#define L2_FWD   (1<<1)

Definition at line 96 of file l2_bd.h.

#define L2_LEARN   (1<<0)

Definition at line 95 of file l2_bd.h.

#define L2_UU_FLOOD   (1<<3)

Definition at line 98 of file l2_bd.h.

Function Documentation

u32 bd_add_del_ip_mac ( u32  bd_index,
u8 ip_addr,
u8 mac_addr,
u8  is_ip6,
u8  is_add 
)

Definition at line 447 of file l2_bd.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void bd_add_member ( l2_bridge_domain_t bd_config,
l2_flood_member_t member 
)

Definition at line 102 of file l2_bd.c.

+ Here is the caller graph for this function:

int bd_delete_bd_index ( bd_main_t bdm,
u32  bd_id 
)

Delete a bridge domain.

Delete an existing bridge domain with the given bridge domain ID.

Parameters
bdmbd_main pointer.
bd_idThe bridge domain ID.
Returns
0 on success and -1 if the bridge domain does not exist.

Definition at line 80 of file l2_bd.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 bd_find_or_add_bd_index ( bd_main_t bdm,
u32  bd_id 
)

Get or create a bridge domain.

Get or create a bridge domain with the given bridge domain ID.

Parameters
bdmbd_main pointer.
bd_idThe bridge domain ID or ~0 if an arbitrary unused bridge domain should be used.
Returns
The bridge domain index in l2input_main->l2_bridge_domain_t vector.

Definition at line 52 of file l2_bd.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

always_inline u32 bd_is_valid ( l2_bridge_domain_t bd_config)

Definition at line 76 of file l2_bd.h.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 bd_remove_member ( l2_bridge_domain_t bd_config,
u32  sw_if_index 
)

Definition at line 127 of file l2_bd.c.

+ Here is the caller graph for this function:

u32 bd_set_flags ( vlib_main_t vm,
u32  bd_index,
u32  flags,
u32  enable 
)

Definition at line 164 of file l2_bd.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void bd_validate ( l2_bridge_domain_t bd_config)

Definition at line 40 of file l2_bd.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Variable Documentation

bd_main_t bd_main

Definition at line 36 of file l2_bd.h.