FD.io VPP
v17.07-30-g839fa73
Vector Packet Processing
|
Ethernet Bridge Domain. More...
Go to the source code of this file.
Macros | |
#define | BD_REMOVE_ERROR_OK 0 |
#define | BD_REMOVE_ERROR_NOT_FOUND 1 |
Functions | |
void | bd_validate (l2_bridge_domain_t *bd_config) |
Init bridge domain if not done already. More... | |
u32 | bd_find_index (bd_main_t *bdm, u32 bd_id) |
Get a bridge domain. More... | |
u32 | bd_add_bd_index (bd_main_t *bdm, u32 bd_id) |
Create a bridge domain. More... | |
static int | bd_delete (bd_main_t *bdm, u32 bd_index) |
static void | update_flood_count (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) |
clib_error_t * | l2bd_init (vlib_main_t *vm) |
u32 | bd_set_flags (vlib_main_t *vm, u32 bd_index, u32 flags, u32 enable) |
Set the learn/forward/flood flags for the bridge domain. More... | |
void | bd_set_mac_age (vlib_main_t *vm, u32 bd_index, u8 age) |
Set the mac age for the bridge domain. More... | |
static clib_error_t * | bd_learn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Set bridge-domain learn enable/disable. More... | |
static clib_error_t * | bd_fwd (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Set bridge-domain forward enable/disable. More... | |
static clib_error_t * | bd_flood (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Set bridge-domain flood enable/disable. More... | |
static clib_error_t * | bd_uu_flood (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Set bridge-domain unkown-unicast flood enable/disable. More... | |
static clib_error_t * | bd_arp_term (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Set bridge-domain arp term enable/disable. More... | |
static clib_error_t * | bd_mac_age (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
u32 | bd_add_del_ip_mac (u32 bd_index, u8 *ip_addr, u8 *mac_addr, u8 is_ip6, u8 is_add) |
Add/delete IP address to MAC address mapping. More... | |
static clib_error_t * | bd_arp_entry (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Set bridge-domain arp entry add/delete. More... | |
u8 * | format_vtr (u8 *s, va_list *args) |
static clib_error_t * | bd_show (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Show bridge-domain state. More... | |
int | bd_add_del (l2_bridge_domain_add_del_args_t *a) |
static clib_error_t * | bd_add_del_command_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd) |
Create or delete bridge-domain. More... | |
Variables | |
bd_main_t | bd_main |
static vlib_cli_command_t | bd_learn_cli |
(constructor) VLIB_CLI_COMMAND (bd_learn_cli) More... | |
static vlib_cli_command_t | bd_fwd_cli |
(constructor) VLIB_CLI_COMMAND (bd_fwd_cli) More... | |
static vlib_cli_command_t | bd_flood_cli |
(constructor) VLIB_CLI_COMMAND (bd_flood_cli) More... | |
static vlib_cli_command_t | bd_uu_flood_cli |
(constructor) VLIB_CLI_COMMAND (bd_uu_flood_cli) More... | |
static vlib_cli_command_t | bd_mac_age_cli |
(constructor) VLIB_CLI_COMMAND (bd_mac_age_cli) More... | |
static vlib_cli_command_t | bd_arp_term_cli |
(constructor) VLIB_CLI_COMMAND (bd_arp_term_cli) More... | |
static vlib_cli_command_t | bd_arp_entry_cli |
(constructor) VLIB_CLI_COMMAND (bd_arp_entry_cli) More... | |
static vlib_cli_command_t | bd_show_cli |
(constructor) VLIB_CLI_COMMAND (bd_show_cli) More... | |
static vlib_cli_command_t | bd_create_cli |
(constructor) VLIB_CLI_COMMAND (bd_create_cli) More... | |
Ethernet Bridge Domain.
Code in this file manages Layer 2 bridge domains.
Definition in file l2_bd.c.
Create a bridge domain.
Create a bridge domain with the given bridge domain ID
bdm | bd_main pointer. |
l2input_main->l2_bridge_domain_t
vector. Definition at line 76 of file l2_bd.c.
int bd_add_del | ( | l2_bridge_domain_add_del_args_t * | a | ) |
|
static |
Add/delete IP address to MAC address mapping.
The clib hash implementation stores uword entries in the hash table. The hash table mac_by_ip4 is keyed via IP4 address and store the 6-byte MAC address directly in the hash table entry uword.
Definition at line 719 of file l2_bd.c.
void bd_add_member | ( | l2_bridge_domain_t * | bd_config, |
l2_flood_member_t * | member | ||
) |
|
static |
|
static |
Get a bridge domain.
Get a bridge domain with the given bridge domain ID.
bdm | bd_main pointer. |
bd_id | The bridge domain ID |
l2input_main->l2_bridge_domain_t
vector. Definition at line 67 of file l2_bd.c.
|
static |
|
static |
|
static |
|
static |
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 | ||
) |
void bd_set_mac_age | ( | vlib_main_t * | vm, |
u32 | bd_index, | ||
u8 | age | ||
) |
|
static |
|
static |
void bd_validate | ( | l2_bridge_domain_t * | bd_config | ) |
clib_error_t* l2bd_init | ( | vlib_main_t * | vm | ) |
|
static |
|
static |
(constructor) VLIB_CLI_COMMAND (bd_arp_entry_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_arp_term_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_create_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_flood_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_fwd_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_learn_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_mac_age_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_show_cli)
|
static |
(constructor) VLIB_CLI_COMMAND (bd_uu_flood_cli)