diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2008-12-14 18:36:00 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2008-12-14 18:36:00 +0000 |
commit | a986c0757ad4c5f843502bcea0a5e7211368444e (patch) | |
tree | efc60f55510c7b0e92a056550e139e96ae6b2f70 /testsuites/sptests/sp35 | |
parent | 2008-12-14 Joel Sherrill <joel.sherrill@oarcorp.com> (diff) | |
download | rtems-a986c0757ad4c5f843502bcea0a5e7211368444e.tar.bz2 |
2008-12-14 Joel Sherrill <joel.sherrill@oarcorp.com>
* sp07/init.c, sp12/init.c, sp12/pridrv.c, sp12/pritask.c,
sp12/system.h, sp16/system.h, sp25/system.h, sp26/task1.c,
sp28/init.c, sp29/init.c, sp35/priinv.c, sp42/init.c: Run all tests
successfully with maxixum number of priorities as 16 instead of 256.
This was done by temporarily modifying the score priority.h maximum.
This allowed testing of all API code to ensure that it worked
properly with a reduced number of priorities. Most modifications were
to switch from hard-coded maximum to using the API provided methods
to determine maximum number of priority levels.
Diffstat (limited to 'testsuites/sptests/sp35')
-rw-r--r-- | testsuites/sptests/sp35/priinv.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/testsuites/sptests/sp35/priinv.c b/testsuites/sptests/sp35/priinv.c index ec677c33e0..6d1e4506cb 100644 --- a/testsuites/sptests/sp35/priinv.c +++ b/testsuites/sptests/sp35/priinv.c @@ -410,9 +410,10 @@ rtems_task Init(rtems_task_argument ignored) /* -- Medium-prio Test Tasks --- */ for (i = 0; i < NofMediumTask_C; i++) { +#define MEDIUM_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2) + 1) status = rtems_task_create( rtems_build_name('M','E','D','0'+i), /* Name */ - 100, /* Priority */ + MEDIUM_PRIORITY, /* Priority */ RTEMS_MINIMUM_STACK_SIZE*2, /* Stack size (8KB) */ RTEMS_DEFAULT_MODES | RTEMS_NO_ASR, /* Mode */ RTEMS_DEFAULT_ATTRIBUTES | RTEMS_FLOATING_POINT, /* Attributes */ @@ -425,9 +426,10 @@ rtems_task Init(rtems_task_argument ignored) } /* -- High-prio Test Task --- */ +#define HIGH_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2)) status = rtems_task_create( rtems_build_name('H','I','G','H'), /* Name */ - 10, /* Priority */ + HIGH_PRIORITY, /* Priority */ RTEMS_MINIMUM_STACK_SIZE*2, /* Stack size (8KB) */ RTEMS_DEFAULT_MODES | RTEMS_NO_ASR, /* Mode */ RTEMS_DEFAULT_ATTRIBUTES | RTEMS_FLOATING_POINT, /* Attributes */ @@ -439,9 +441,10 @@ rtems_task Init(rtems_task_argument ignored) directive_failed( status, "rtems_task_start (HIGH)" ); /* -- Low-prio Test Task --- */ +#define LOW_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 1) status = rtems_task_create( rtems_build_name('L','O','W',' '), /* Name */ - 200, /* Priority */ + LOW_PRIORITY, /* Priority */ RTEMS_MINIMUM_STACK_SIZE*2, /* Stack size (8KB) */ RTEMS_DEFAULT_MODES | RTEMS_NO_ASR, /* Mode */ RTEMS_DEFAULT_ATTRIBUTES | RTEMS_FLOATING_POINT, /* Attributes */ @@ -453,9 +456,10 @@ rtems_task Init(rtems_task_argument ignored) directive_failed( status, "rtems_task_start (LOW)" ); /* -- HW Simulator Task --- */ +#define HWTASK_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 2) status = rtems_task_create( rtems_build_name('H','W','S','M'), /* Name */ - 240, /* Priority */ + HWTASK_PRIORITY, /* Priority */ RTEMS_MINIMUM_STACK_SIZE*2, /* Stack size (8KB) */ RTEMS_DEFAULT_MODES | RTEMS_NO_ASR, /* Mode */ RTEMS_DEFAULT_ATTRIBUTES | RTEMS_FLOATING_POINT, /* Attributes */ |