Skip to content

Commit 56cef47

Browse files
edumazetkuba-moo
authored andcommitted
selftests/net: packetdrill: unflake tcp_user_timeout_user-timeout-probe.pkt
This test fails the first time I am running it after a fresh virtme-ng boot. tcp_user_timeout_user-timeout-probe.pkt:33: runtime error in write call: Expected result -1 but got 24 with errno 2 (No such file or directory) Tweaks the timings a bit, to reduce flakiness. Signed-off-by: Eric Dumazet <[email protected]> Cc: Soham Chakradeo <[email protected]> Cc: Willem de Bruijn <[email protected]> Reviewed-by: Kuniyuki Iwashima <[email protected]> Tested-by: Jamal Hadi Salim <[email protected]> Acked-by: Jamal Hadi Salim <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 01b6aca commit 56cef47

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tools/testing/selftests/net/packetdrill/tcp_user_timeout_user-timeout-probe.pkt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,16 @@
2323

2424
// install a qdisc dropping all packets
2525
+0 `tc qdisc delete dev tun0 root 2>/dev/null ; tc qdisc add dev tun0 root pfifo limit 0`
26+
2627
+0 write(4, ..., 24) = 24
2728
// When qdisc is congested we retry every 500ms
2829
// (TCP_RESOURCE_PROBE_INTERVAL) and therefore
2930
// we retry 6 times before hitting 3s timeout.
3031
// First verify that the connection is alive:
31-
+3.250 write(4, ..., 24) = 24
32+
+3 write(4, ..., 24) = 24
33+
3234
// Now verify that shortly after that the socket is dead:
33-
+.100 write(4, ..., 24) = -1 ETIMEDOUT (Connection timed out)
35+
+1 write(4, ..., 24) = -1 ETIMEDOUT (Connection timed out)
3436

3537
+0 %{ assert tcpi_probes == 6, tcpi_probes; \
3638
assert tcpi_backoff == 0, tcpi_backoff }%

0 commit comments

Comments
 (0)