diff --git a/SOURCES/openvswitch-2.15.0.patch b/SOURCES/openvswitch-2.15.0.patch index a9123ea..b7d4b75 100644 --- a/SOURCES/openvswitch-2.15.0.patch +++ b/SOURCES/openvswitch-2.15.0.patch @@ -25508,9 +25508,133 @@ index 199db8ed0f..59093c03c9 100644 bad_action 'fin_timeout(foo=bar)' "invalid key 'foo' in 'fin_timeout' argument" diff --git a/tests/ofproto-dpif.at b/tests/ofproto-dpif.at -index 31064ed95e..d6de714971 100644 +index 31064ed95e..c0217de004 100644 --- a/tests/ofproto-dpif.at +++ b/tests/ofproto-dpif.at +@@ -81,11 +81,12 @@ recirc_id(0),in_port(4),packet_type(ns=0,id=0),eth(src=50:54:00:00:00:0b,dst=ff: + + ovs-appctl netdev-dummy/set-admin-state p1 up + ovs-appctl time/warp 100 +-OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ++OVS_WAIT_UNTIL_EQUAL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [dnl + ---- bond0 ---- + bond_mode: active-backup + bond may use recirculation: no, + bond-hash-basis: 0 ++lb_output action: disabled, bond-id: -1 + updelay: 0 ms + downdelay: 0 ms + lacp_status: off +@@ -99,7 +100,6 @@ member p1: enabled + + member p2: enabled + may_enable: true +- + ]) + + OVS_VSWITCHD_STOP +@@ -129,11 +129,12 @@ ovs-appctl time/warp 100 + OVS_WAIT_UNTIL([test -n "`ovs-appctl bond/show | fgrep 'member p1: disabled'`"]) + ovs-appctl netdev-dummy/set-admin-state p1 up + ovs-appctl time/warp 100 +-OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ++OVS_WAIT_UNTIL_EQUAL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [dnl + ---- bond0 ---- + bond_mode: active-backup + bond may use recirculation: no, + bond-hash-basis: 0 ++lb_output action: disabled, bond-id: -1 + updelay: 0 ms + downdelay: 0 ms + lacp_status: off +@@ -150,7 +151,6 @@ member p2: enabled + + member p3: enabled + may_enable: true +- + ]) + + dnl Now delete the primary and verify that the output shows that the +@@ -171,11 +171,12 @@ ovs-vsctl \ + --id=@p1 create Interface name=p1 type=dummy options:pstream=punix:$OVS_RUNDIR/p1.sock ofport_request=1 -- \ + set Port bond0 interfaces="$uuids, @p1]" + ovs-appctl time/warp 100 +-OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ++OVS_WAIT_UNTIL_EQUAL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [dnl + ---- bond0 ---- + bond_mode: active-backup + bond may use recirculation: no, + bond-hash-basis: 0 ++lb_output action: disabled, bond-id: -1 + updelay: 0 ms + downdelay: 0 ms + lacp_status: off +@@ -192,17 +193,17 @@ member p2: enabled + + member p3: enabled + may_enable: true +- + ]) + + dnl Switch to another primary + ovs-vsctl set port bond0 other_config:bond-primary=p2 + ovs-appctl time/warp 100 +-OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ++OVS_WAIT_UNTIL_EQUAL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [dnl + ---- bond0 ---- + bond_mode: active-backup + bond may use recirculation: no, + bond-hash-basis: 0 ++lb_output action: disabled, bond-id: -1 + updelay: 0 ms + downdelay: 0 ms + lacp_status: off +@@ -211,25 +212,25 @@ active-backup primary: p2 + + + member p1: enabled +- active member + may_enable: true + + member p2: enabled ++ active member + may_enable: true + + member p3: enabled + may_enable: true +- + ]) + + dnl Remove the "bond-primary" config directive from the bond. + AT_CHECK([ovs-vsctl remove Port bond0 other_config bond-primary]) + ovs-appctl time/warp 100 +-OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ++OVS_WAIT_UNTIL_EQUAL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [dnl + ---- bond0 ---- + bond_mode: active-backup + bond may use recirculation: no, + bond-hash-basis: 0 ++lb_output action: disabled, bond-id: -1 + updelay: 0 ms + downdelay: 0 ms + lacp_status: off +@@ -238,15 +239,14 @@ active-backup primary: + + + member p1: enabled +- active member + may_enable: true + + member p2: enabled ++ active member + may_enable: true + + member p3: enabled + may_enable: true +- + ]) + + OVS_VSWITCHD_STOP @@ -342,6 +342,22 @@ AT_CHECK([test `egrep 'in_port\(6\)' br1_flows.txt |wc -l` -gt 3]) OVS_VSWITCHD_STOP AT_CLEANUP @@ -25854,6 +25978,44 @@ index 31064ed95e..d6de714971 100644 OVS_VSWITCHD_STOP AT_CLEANUP +diff --git a/tests/ovs-macros.at b/tests/ovs-macros.at +index 66545da572..e6c5bc6e94 100644 +--- a/tests/ovs-macros.at ++++ b/tests/ovs-macros.at +@@ -259,7 +259,20 @@ dnl Executes shell COMMAND in a loop until it returns zero. If COMMAND does + dnl not return zero within a reasonable time limit, executes the commands + dnl in IF-FAILED (if provided) and fails the test. + m4_define([OVS_WAIT_UNTIL], +- [OVS_WAIT([$1], [$2], [AT_LINE], [until $1])]) ++ [AT_FAIL_IF([test "$#" -ge 3]) ++ dnl The second argument should not be a number (confused with AT_CHECK ?). ++ AT_FAIL_IF([test "$#" -eq 2 && test "$2" -eq "$2" 2>/dev/null]) ++ OVS_WAIT([$1], [$2], [AT_LINE], [until $1])]) ++ ++dnl OVS_WAIT_UNTIL_EQUAL(COMMAND, OUTPUT) ++dnl ++dnl Executes shell COMMAND in a loop until it returns zero and the output ++dnl equals OUTPUT. If COMMAND does not return zero or a desired output within ++dnl a reasonable time limit, fails the test. ++m4_define([OVS_WAIT_UNTIL_EQUAL], ++ [AT_FAIL_IF([test "$#" -ge 3]) ++ echo "$2" > wait_until_expected ++ OVS_WAIT_UNTIL([$1 | diff -u wait_until_expected - ])]) + + dnl OVS_WAIT_WHILE(COMMAND, [IF-FAILED]) + dnl +@@ -267,7 +280,10 @@ dnl Executes shell COMMAND in a loop until it returns nonzero. If COMMAND does + dnl not return nonzero within a reasonable time limit, executes the commands + dnl in IF-FAILED (if provided) and fails the test. + m4_define([OVS_WAIT_WHILE], +- [OVS_WAIT([if $1; then return 1; else return 0; fi], [$2], ++ [AT_FAIL_IF([test "$#" -ge 3]) ++ dnl The second argument should not be a number (confused with AT_CHECK ?). ++ AT_FAIL_IF([test "$#" -eq 2 && test "$2" -eq "$2" 2>/dev/null]) ++ OVS_WAIT([if $1; then return 1; else return 0; fi], [$2], + [AT_LINE], [while $1])]) + + dnl OVS_APP_EXIT_AND_WAIT(DAEMON) diff --git a/tests/ovs-ofctl.at b/tests/ovs-ofctl.at index 5ddca67e71..c93cb9f16c 100644 --- a/tests/ovs-ofctl.at @@ -27596,6 +27758,24 @@ index 4f601ef939..c8e4c68fae 100644 +]) +OVS_TRAFFIC_VSWITCHD_STOP +AT_CLEANUP +diff --git a/tests/system-route.at b/tests/system-route.at +index 1714273e35..270956d13f 100644 +--- a/tests/system-route.at ++++ b/tests/system-route.at +@@ -14,10 +14,9 @@ dnl Add ip address. + AT_CHECK([ip addr add 10.0.0.17/24 dev p1-route], [0], [stdout]) + + dnl Check that OVS catches route updates. +-OVS_WAIT_UNTIL([ovs-appctl ovs/route/show | grep 'p1-route' | sort], [0], [dnl +-Cached: 10.0.0.17/24 dev p1-route SRC 10.0.0.17 +-Cached: 10.0.0.17/32 dev p1-route SRC 10.0.0.17 local +-]) ++OVS_WAIT_UNTIL_EQUAL([ovs-appctl ovs/route/show | grep 'p1-route' | sort], [dnl ++Cached: 10.0.0.0/24 dev p1-route SRC 10.0.0.17 ++Cached: 10.0.0.17/32 dev p1-route SRC 10.0.0.17 local]) + + dnl Delete ip address. + AT_CHECK([ip addr del 10.0.0.17/24 dev p1-route], [0], [stdout]) diff --git a/tests/system-traffic.at b/tests/system-traffic.at index fb5b9a36d2..8347090f84 100644 --- a/tests/system-traffic.at diff --git a/SPECS/openvswitch2.15.spec b/SPECS/openvswitch2.15.spec index f3c2aa2..dcc221a 100644 --- a/SPECS/openvswitch2.15.spec +++ b/SPECS/openvswitch2.15.spec @@ -57,7 +57,7 @@ Summary: Open vSwitch Group: System Environment/Daemons daemon/database/utilities URL: http://www.openvswitch.org/ Version: 2.15.0 -Release: 85%{?dist} +Release: 86%{?dist} # Nearly all of openvswitch is ASL 2.0. The bugtool is LGPLv2+, and the # lib/sflow*.[ch] files are SISSL @@ -702,6 +702,12 @@ exit 0 %endif %changelog +* Wed Mar 23 2022 Open vSwitch CI - 2.15.0-86 +- Merging upstream branch-2.15 [RH git: 68ea3ca4b4] + Commit list: + 25dab05c39 tests: Fix incorrect usage of OVS_WAIT_UNTIL. + + * Mon Mar 21 2022 Open vSwitch CI - 2.15.0-85 - Merging upstream branch-2.15 [RH git: 7b1d494b1f] Commit list: