diff options
Diffstat (limited to 'testsuites/samples/nsecs/init.c')
-rw-r--r-- | testsuites/samples/nsecs/init.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/testsuites/samples/nsecs/init.c b/testsuites/samples/nsecs/init.c index f94c672d0c..fe5390dc38 100644 --- a/testsuites/samples/nsecs/init.c +++ b/testsuites/samples/nsecs/init.c @@ -23,6 +23,7 @@ #include <string.h> #include <stdlib.h> #include <unistd.h> +#include <time.h> #include <sys/time.h> #define CONFIGURE_INIT @@ -81,13 +82,9 @@ rtems_task Init( for (index=0 ; index <10 ; index++ ) { struct timespec start, stop; struct timespec diff; -#if 0 + clock_gettime( CLOCK_REALTIME, &start ); clock_gettime( CLOCK_REALTIME, &stop ); -#else - _TOD_Get( &start ); - _TOD_Get( &stop ); -#endif subtract_em( &start, &stop, &diff ); printf( "Start: %s:%ld\nStop : %s:%ld", |