aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/l2/l2_bd.h
diff options
context:
space:
mode:
authorJerome Tollet <jtollet@cisco.com>2020-12-18 09:44:24 +0100
committerJohn Lo <loj@cisco.com>2021-01-06 04:17:09 +0000
commit5f93e3b7f85e2257406cf601e5f231a872100fcf (patch)
treea9ae2588b3d28ac380b0a97b827ac52101ebbd52 /src/vnet/l2/l2_bd.h
parent1b576e0aa08c575a4409b50dc71e8f51d231f199 (diff)
l2: add per bridge domain learn limit
Type: feature Signed-off-by: Jerome Tollet <jtollet@cisco.com> Change-Id: I57ed6699050445d9c9aec98eff3aab56735aca54 Signed-off-by: Jerome Tollet <jtollet@cisco.com>
Diffstat (limited to 'src/vnet/l2/l2_bd.h')
-rw-r--r--src/vnet/l2/l2_bd.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/vnet/l2/l2_bd.h b/src/vnet/l2/l2_bd.h
index 943358b4e15..0d77292519d 100644
--- a/src/vnet/l2/l2_bd.h
+++ b/src/vnet/l2/l2_bd.h
@@ -110,6 +110,12 @@ typedef struct
/* Bridge domain tag (C string NULL terminated) */
u8 *bd_tag;
+ /* Maximum number of learned entries */
+ u32 learn_limit;
+
+ /* Current number of learned entries */
+ u32 learn_count;
+
} l2_bridge_domain_t;
/* Limit Bridge Domain ID to 24 bits to match 24-bit VNI range */
@@ -158,6 +164,7 @@ typedef enum bd_flags_t_
u32 bd_set_flags (vlib_main_t * vm, u32 bd_index, bd_flags_t flags,
u32 enable);
void bd_set_mac_age (vlib_main_t * vm, u32 bd_index, u8 age);
+void bd_set_learn_limit (vlib_main_t *vm, u32 bd_index, u32 learn_limit);
int bd_add_del (l2_bridge_domain_add_del_args_t * args);
/**