2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 14:25:26 +00:00

mirroring: Allow learning to be disabled on a VLAN.

RSPAN does not work properly unless MAC learning for the VLAN is
disabled on all switches between the origin and monitoring point.
This allows learning to be disabled on a given VLAN so vSwitch can
acts as an intermediate switch.

Feature #2136
This commit is contained in:
Jesse Gross
2009-11-06 17:13:51 -08:00
parent 93dfc06772
commit f2d7fd66cf
4 changed files with 65 additions and 4 deletions

View File

@@ -52,10 +52,13 @@ struct mac_learning {
struct list table[MAC_HASH_SIZE]; /* Hash table. */
struct mac_entry entries[MAC_MAX]; /* All entries. */
uint32_t secret; /* Secret for */
unsigned long *non_learning_vlans; /* Bitmap of learning disabled VLANs. */
};
struct mac_learning *mac_learning_create(void);
void mac_learning_destroy(struct mac_learning *);
bool mac_learning_set_disabled_vlans(struct mac_learning *,
unsigned long *bitmap);
tag_type mac_learning_learn(struct mac_learning *,
const uint8_t src[ETH_ADDR_LEN], uint16_t vlan,
uint16_t src_port);