Occasionally, this test would fail, with some of the ports reporting
"may_enable: false" in the bond/show output. This commit fixes the race
condition by waiting for may_enable to be true for all bond ports.

Signed-off-by: Joe Stringer <joestrin...@nicira.com>
---
Running the test in a tight loop could cause this failure to happen
after about 5 runs. I'm guessing that the LACP negotiation doesn't
finish before we start sending packets.
---
 tests/ofproto-dpif.at |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/ofproto-dpif.at b/tests/ofproto-dpif.at
index 5451b90..038eb07 100644
--- a/tests/ofproto-dpif.at
+++ b/tests/ofproto-dpif.at
@@ -125,7 +125,7 @@ AT_CHECK([ovs-ofctl add-flow br0 action=normal])
 AT_CHECK([ovs-ofctl add-flow br1 action=normal])
 AT_CHECK([ovs-appctl upcall/disable-megaflows], [0], [megaflows disabled
 ], [])
-WAIT_FOR_DUMMY_PORTS([p4], [p5], [p6])
+OVS_WAIT_WHILE([ovs-appctl bond/show | grep "may_enable: false"])
 ovs-appctl time/stop
 ovs-appctl time/warp 100
 ovs-appctl lacp/show > lacp.txt
-- 
1.7.10.4

_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to