summaryrefslogtreecommitdiffstats
path: root/testsuites/smptests/smp02
diff options
context:
space:
mode:
authorJennifer Averett <Jennifer.Averett@OARcorp.com>2011-07-29 12:29:34 +0000
committerJennifer Averett <Jennifer.Averett@OARcorp.com>2011-07-29 12:29:34 +0000
commitcf288c3898a5d7db53af312a67da4dca9f2e6045 (patch)
tree31eee4135aa35e8c0512a3f6fe79bf22b4c8c4b6 /testsuites/smptests/smp02
parent2011-07-28 Ricardo Aguirre <el.mastin@ymail.com> (diff)
downloadrtems-cf288c3898a5d7db53af312a67da4dca9f2e6045.tar.bz2
2011-07-29 Jennifer Averett <Jennifer.Averett@OARcorp.com>
* smp01/init.c, smp02/init.c, smp02/tasks.c, smp03/init.c, smp03/tasks.c, smp04/Makefile.am, smp04/init.c, smp05/init.c, smp06/init.c, smp07/init.c, smp08/init.c: Cleaned up tests and fixed some print statement problems. * smp04/tasks.c: Removed.
Diffstat (limited to 'testsuites/smptests/smp02')
-rw-r--r--testsuites/smptests/smp02/init.c3
-rw-r--r--testsuites/smptests/smp02/tasks.c8
2 files changed, 3 insertions, 8 deletions
diff --git a/testsuites/smptests/smp02/init.c b/testsuites/smptests/smp02/init.c
index ad9974a0a7..0da90924cd 100644
--- a/testsuites/smptests/smp02/init.c
+++ b/testsuites/smptests/smp02/init.c
@@ -47,7 +47,7 @@ rtems_task Init(
status = rtems_semaphore_obtain( Semaphore, RTEMS_WAIT, 0);
directive_failed( status,"rtems_semaphore_obtain of SEM1\n");
- for ( i=1; i < CONFIGURE_SMP_MAXIMUM_PROCESSORS; i++ ){
+ for ( i=1; i < rtems_smp_get_number_of_processors(); i++ ){
/* Create and start tasks for each CPU */
ch = '0' + i;
@@ -64,7 +64,6 @@ rtems_task Init(
cpu_num = bsp_smp_processor_id();
locked_printf(" CPU %d start task TA%c\n", cpu_num, ch);
status = rtems_task_start( id, Test_task, i+1 );
- locked_printf(str, "rtems_task_start TA%d", i+1);
directive_failed( status, str );
}
diff --git a/testsuites/smptests/smp02/tasks.c b/testsuites/smptests/smp02/tasks.c
index 01b24c472e..e972f1f5d2 100644
--- a/testsuites/smptests/smp02/tasks.c
+++ b/testsuites/smptests/smp02/tasks.c
@@ -15,7 +15,7 @@
#include "system.h"
-void Loop() {
+void Loop(void) {
volatile int i;
for (i=0; i<300000; i++);
@@ -26,8 +26,6 @@ void LogSemaphore(
int cpu_num,
uint32_t task_index
){
- int i;
-
if (Log_index < LOG_SIZE) {
/* Log the information */
Log[ Log_index ].IsLocked = obtained;
@@ -57,7 +55,5 @@ rtems_task Test_task(
LogSemaphore(false, cpu_num, task_index);
rtems_semaphore_release( Semaphore );
- }
-
- while(1);
+ } while(1);
}