Jakub reports that some tests fail on netdev CI when executed in a debug
kernel.
Increase test timeout to 30m, this should hopefully be enough.
Also reduce test duration where possible for "slow" machines.
Signed-off-by: Florian Westphal <fw@strlen.de>
Link: https://lore.kernel.org/r/20240429105736.22677-1-fw@strlen.de
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        fromns="$1"
        dstip="$2"
 
-       for i in $(seq 1 500); do
+       local packets=500
+
+       [ "$KSFT_MACHINE_SLOW" = yes ] && packets=100
+
+       for i in $(seq 1 $packets); do
                if ! ip netns exec "$fromns" ping -q -f -b -c 1 -q "$dstip" > /dev/null 2>&1; then
                        echo "ERROR: ping -b from $fromns to $dstip"
                        ip netns exec "$ns0" nft list ruleset
 
 have_socat=0
 ret=0
 
+[ "$KSFT_MACHINE_SLOW" = yes ] && maxclients=40
 # client1---.
 #            veth1-.
 #                  |
 
 source lib.sh
 
 zones=2000
+[ "$KSFT_MACHINE_SLOW" = yes ] && zones=500
+
 have_ct_tool=0
 ret=0
 
                count=$(ip netns exec "$ns1" conntrack -C)
                duration=$((stop-outerstart))
 
-               if [ "$count" -eq "$max_zones" ]; then
+               if [ "$count" -ge "$max_zones" ]; then
                        echo "PASS: inserted $count entries from packet path in $duration ms total"
                else
                        ip netns exec "$ns1" conntrack -S 1>&2
 
-timeout=500
+timeout=1800