summaryrefslogtreecommitdiffstats
path: root/testsuites/sptests/sp20
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2011-07-24 22:10:20 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2011-07-24 22:10:20 +0000
commit9e15e9bfbaf0947442289a2d422d95b71db36f58 (patch)
tree6a35849de7fa9a7671e76d396157457799abfa79 /testsuites/sptests/sp20
parentRegenerate. (diff)
downloadrtems-9e15e9bfbaf0947442289a2d422d95b71db36f58.tar.bz2
2011-07-24 Joel Sherrill <joel.sherrill@oarcorp.com>
* sp04/tswitch.c, sp07/task1.c, sp07/task2.c, sp09/screen07.c, sp11/task1.c, sp11/task2.c, sp12/pridrv.c, sp12/pritask.c, sp13/task1.c, sp14/asr.c, sp14/task1.c, sp19/first.c, sp19/fptask.c, sp19/inttest.h, sp19/task1.c, sp20/task1.c, sp25/task1.c, sp26/task1.c, sp28/init.c, sp29/init.c, sp31/task1.c, sp32/init.c, sp33/init.c, sp34/changepri.c, sp36/strict_order_mut.c, sp37/init.c, sp43/init.c, sp44/init.c, sp48/init.c, sp54/init.c, sp59/init.c, sp65/init.c, sp68/init.c, spchain/init.c, spclockget/init.c, spfatal03/testcase.h, spfatal07/testcase.h, spfatal_support/init.c: Do not line length exceed 80 columns.
Diffstat (limited to 'testsuites/sptests/sp20')
-rw-r--r--testsuites/sptests/sp20/task1.c47
1 files changed, 26 insertions, 21 deletions
diff --git a/testsuites/sptests/sp20/task1.c b/testsuites/sptests/sp20/task1.c
index e9de2658c6..44134622ba 100644
--- a/testsuites/sptests/sp20/task1.c
+++ b/testsuites/sptests/sp20/task1.c
@@ -1,14 +1,5 @@
-/* Task_1_through_5
- *
- * This routine serves as a test task for the period capabilities of the
- * Rate Monotonic Manager.
- *
- * Input parameters:
- * argument - task argument
- *
- * Output parameters: NONE
- *
- * COPYRIGHT (c) 1989-1999.
+/*
+ * COPYRIGHT (c) 1989-2011.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -53,15 +44,26 @@ rtems_task Task_1_through_6(
status = rtems_rate_monotonic_ident( argument, &test_rmid );
directive_failed( status, "rtems_rate_monotonic_ident" );
put_name( Task_name[ argument ], FALSE );
- printf( "- rtems_rate_monotonic_ident id = 0x%08" PRIxrtems_id "\n", test_rmid );
+ printf(
+ "- rtems_rate_monotonic_ident id = 0x%08" PRIxrtems_id "\n",
+ test_rmid
+ );
if ( rmid != test_rmid ) {
- printf( "RMID's DO NOT MATCH (0x%" PRIxrtems_id " and 0x%" PRIxrtems_id ")\n", rmid, test_rmid );
- rtems_test_exit( 0 );
+ printf(
+ "RMID's DO NOT MATCH (0x%" PRIxrtems_id " and 0x%" PRIxrtems_id ")\n",
+ rmid,
+ test_rmid
+ );
+ rtems_test_exit( 0 );
}
put_name( Task_name[ argument ], FALSE );
- printf( "- (0x%08" PRIxrtems_id ") period %" PRIu32 "\n", rmid, Periods[ argument ] );
+ printf(
+ "- (0x%08" PRIxrtems_id ") period %" PRIu32 "\n",
+ rmid,
+ Periods[ argument ]
+ );
status = rtems_task_wake_after( 2 );
directive_failed( status, "rtems_task_wake_after" );
@@ -134,8 +136,7 @@ rtems_task Task_1_through_6(
time[0] = _Watchdog_Ticks_since_boot; /* timestamp */
/*printf("%d - %d\n", period, time[0]);*/
- for (index = 1; index <= TA6_ITERATIONS; index++)
- {
+ for (index = 1; index <= TA6_ITERATIONS; index++) {
period = (index+1)*TA6_PERIOD_FACTOR;
status = rtems_rate_monotonic_period( rmid, period);
directive_failed( status, "rtems_rate_monotonic_period of TA6" );
@@ -143,13 +144,17 @@ rtems_task Task_1_through_6(
/*printf("%d - %d\n", period, time[index]);*/
}
- for (index = 1; index <= TA6_ITERATIONS; index++)
- {
+ for (index = 1; index <= TA6_ITERATIONS; index++) {
rtems_interval meas = time[index] - time[index-1];
period = index*TA6_PERIOD_FACTOR;
- printf("TA6 - Actual: %" PRIdrtems_interval " Expected: %" PRIdrtems_interval, meas, period);
+ printf(
+ "TA6 - Actual: %" PRIdrtems_interval
+ " Expected: %" PRIdrtems_interval,
+ meas,
+ period
+ );
if (period == meas) printf(" - OK\n");
- else printf(" - FAILED\n");
+ else printf(" - FAILED\n");
}
}
rtems_task_suspend(RTEMS_SELF);