From e051a388d951defabba84001c68bd5583e58495f Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser <kaspar@schleiser.de> Date: Fri, 20 Nov 2015 00:55:58 +0100 Subject: [PATCH] tests: adapt posix tests to xtimer sleep/usleep --- tests/posix_sleep/Makefile | 6 ------ tests/posix_sleep/main.c | 2 +- tests/pthread/Makefile | 2 -- tests/pthread_cooperation/Makefile | 2 -- tests/pthread_tls/Makefile | 2 -- 5 files changed, 1 insertion(+), 13 deletions(-) diff --git a/tests/posix_sleep/Makefile b/tests/posix_sleep/Makefile index 32fefc14e5..035d06fff2 100644 --- a/tests/posix_sleep/Makefile +++ b/tests/posix_sleep/Makefile @@ -1,12 +1,6 @@ APPLICATION = posix_sleep include ../Makefile.tests_common -BOARD_BLACKLIST := arduino-mega2560 -# arduino-mega2560: warning: iteration 2u invokes undefined behavior -# [-Waggressive-loop-optimizations] - USEMODULE += posix -DISABLE_MODULE += auto_init - include $(RIOTBASE)/Makefile.include diff --git a/tests/posix_sleep/main.c b/tests/posix_sleep/main.c index babb406cab..02c153766c 100644 --- a/tests/posix_sleep/main.c +++ b/tests/posix_sleep/main.c @@ -25,7 +25,7 @@ int main(void) { puts("usleep 1 x 1000*1000"); for (int i = 0; i < 10; i++) { - useconds_t us = i*1000*1000; + useconds_t us = i*1000u*1000u; printf("calling usleep(%u)\n", (unsigned int) us); usleep(us); puts("wake up"); diff --git a/tests/pthread/Makefile b/tests/pthread/Makefile index f94b94daf7..ba9e5aed56 100644 --- a/tests/pthread/Makefile +++ b/tests/pthread/Makefile @@ -7,6 +7,4 @@ BOARD_BLACKLIST := arduino-mega2560 USEMODULE += posix USEMODULE += pthread -DISABLE_MODULE += auto_init - include $(RIOTBASE)/Makefile.include diff --git a/tests/pthread_cooperation/Makefile b/tests/pthread_cooperation/Makefile index 996c3fa30e..e9f15d5469 100644 --- a/tests/pthread_cooperation/Makefile +++ b/tests/pthread_cooperation/Makefile @@ -7,6 +7,4 @@ BOARD_BLACKLIST := arduino-mega2560 USEMODULE += posix USEMODULE += pthread -DISABLE_MODULE += auto_init - include $(RIOTBASE)/Makefile.include diff --git a/tests/pthread_tls/Makefile b/tests/pthread_tls/Makefile index e4b10419fd..d30f9c0368 100644 --- a/tests/pthread_tls/Makefile +++ b/tests/pthread_tls/Makefile @@ -7,6 +7,4 @@ BOARD_BLACKLIST := arduino-mega2560 USEMODULE += posix USEMODULE += pthread -DISABLE_MODULE += auto_init - include $(RIOTBASE)/Makefile.include -- GitLab