net: bridge: add option to allow activity notifications for any fdb entries
This patch adds the ability to notify about activity of any entries (static, permanent or ext_learn). EVPN multihoming peers need it to properly and efficiently handle mac sync (peer active/locally active). We add a new NFEA_ACTIVITY_NOTIFY attribute which is used to dump the current activity state and to control if static entries should be monitored at all. We use 2 bits - one to activate fdb entry tracking (disabled by default) and the second to denote that an entry is inactive. We need the second bit in order to avoid multiple notifications of inactivity. Obviously this makes no difference for dynamic entries since at the time of inactivity they get deleted, while the tracked non-dynamic entries get the inactive bit set and get a notification. Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
899426b3bd
commit
31cbc39b63
@@ -48,6 +48,8 @@ enum {
|
||||
/* Path to usermode spanning tree program */
|
||||
#define BR_STP_PROG "/sbin/bridge-stp"
|
||||
|
||||
#define BR_FDB_NOTIFY_SETTABLE_BITS (FDB_NOTIFY_BIT | FDB_NOTIFY_INACTIVE_BIT)
|
||||
|
||||
typedef struct bridge_id bridge_id;
|
||||
typedef struct mac_addr mac_addr;
|
||||
typedef __u16 port_id;
|
||||
@@ -184,6 +186,8 @@ enum {
|
||||
BR_FDB_ADDED_BY_USER,
|
||||
BR_FDB_ADDED_BY_EXT_LEARN,
|
||||
BR_FDB_OFFLOADED,
|
||||
BR_FDB_NOTIFY,
|
||||
BR_FDB_NOTIFY_INACTIVE
|
||||
};
|
||||
|
||||
struct net_bridge_fdb_key {
|
||||
|
||||
Reference in New Issue
Block a user