summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoel Sherrill <joel@rtems.org>2022-02-23 16:16:59 -0600
committerJoel Sherrill <joel@rtems.org>2022-02-23 16:17:54 -0600
commit57a074b7952fc0221473717d1b7f51db9b2e6825 (patch)
tree27e38927cf6564d053c83ed7430d666a9383d858
parentticker/low_ticker: Fix warnings (diff)
downloadrtems-examples-57a074b7952fc0221473717d1b7f51db9b2e6825.tar.bz2
ticker/low_ticker1: Fix warnings
-rw-r--r--ticker/low_ticker1/init.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/ticker/low_ticker1/init.c b/ticker/low_ticker1/init.c
index 61bdcc6..f80961e 100644
--- a/ticker/low_ticker1/init.c
+++ b/ticker/low_ticker1/init.c
@@ -16,27 +16,26 @@ rtems_task Test_task(
rtems_task_argument task_index
)
{
- rtems_status_code status;
rtems_id period_id;
rtems_interval ticks;
struct timespec uptime;
- status = rtems_rate_monotonic_create(
+ (void) rtems_rate_monotonic_create(
rtems_build_name( 'P', 'E', 'R', 0x30+task_index ),
&period_id
);
ticks = task_index * 5 * rtems_clock_get_ticks_per_second();
for ( ; ; ) {
- status = rtems_rate_monotonic_period( period_id, ticks );
+ (void) rtems_rate_monotonic_period( period_id, ticks );
- status = rtems_clock_get_uptime( &uptime );
+ (void) rtems_clock_get_uptime( &uptime );
if ( uptime.tv_sec >= 35 ) {
printk( "*** END OF LOW MEMORY CLOCK TICK TEST (PERIODs) ***\n" );
rtems_shutdown_executive( 0 );
}
- printk( "TA%d - rtems_clock_uptime - %d:%d\n",
- task_index, uptime.tv_sec, uptime.tv_nsec
+ printk( "TA%d - rtems_clock_uptime - %lld:%ld\n",
+ task_index, (long long) uptime.tv_sec, uptime.tv_nsec
);
}
}
@@ -45,22 +44,24 @@ static void *Init(
uintptr_t ignored
)
{
- rtems_status_code status;
rtems_id id;
int i;
printk( "\n\n*** LOW MEMORY CLOCK TICK TEST (PERIODs) ***\n" );
for (i=1 ; i<=3 ; i++ ) {
- status = rtems_task_create(
+ (void) rtems_task_create(
rtems_build_name( 'T', 'A', 0x30+1, ' ' ), 1, 0, RTEMS_DEFAULT_MODES,
RTEMS_DEFAULT_ATTRIBUTES, &id
);
- status = rtems_task_start( id, Test_task, i );
+ (void) rtems_task_start( id, Test_task, i );
}
- while( 1 )
+ while( 1 ) {
;
+ }
+
+ return NULL;
}
/**************** START OF CONFIGURATION INFORMATION ****************/