forked from openvswitch/ovs
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix bug that causes the static-mac-move test to fail (#128)
Problem: The [static-mac mac moves] test fails against a P4-enabled OVS build because the mac_learning_static_none_move counter is 2 instead of 1. Analysis: is_mac_learning_update_needed() increments the counter in addition to determining whether an update needs to be made. The P4 code adds a second call to this function, resulting in the counter being incremented twice for the same packet. Solution: - Removed the counter increment from is_mac_learning_update_needed() and modified the function to return a Boolean parameter indicating whether the event is a static mac move. - Modified mac_learning_update() to supply the new parameter and increment the counter if its returned value is True. - Modified xlate_normal() to supply the new parameter and ignore the returned value Outcome: With this change in place, the test no longer fails. Signed-off-by: Derek Foster <[email protected]>
- Loading branch information
Showing
3 changed files
with
46 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters