kselftests: timers: Increase delay between suspends in alarmtimer-suspend
authorJohn Stultz <john.stultz@linaro.org>
Wed, 13 May 2015 22:13:03 +0000 (15:13 -0700)
committerShuah Khan <shuahkh@osg.samsung.com>
Tue, 26 May 2015 21:58:07 +0000 (15:58 -0600)
When testing on some hardware, waiting only a second before
re-triggering suspend can keep TCP connections from re-establishing
which after a number of cycles can cause TCP connections to close
while the test is running.

So extend the delay between suspend calls to 3 seconds to let
the connections stay alive.

Cc: Shuah Khan <shuahkh@osg.samsung.com>
Cc: Prarit Bhargava <prarit@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Richard Cochran <richardcochran@gmail.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
tools/testing/selftests/timers/alarmtimer-suspend.c

index aaffbde..99a1ad3 100644 (file)
@@ -172,7 +172,7 @@ int main(void)
                while (alarmcount < 10) {
                        int ret;
 
                while (alarmcount < 10) {
                        int ret;
 
-                       sleep(1);
+                       sleep(3);
                        ret = system("echo mem > /sys/power/state");
                        if (ret)
                                break;
                        ret = system("echo mem > /sys/power/state");
                        if (ret)
                                break;