diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-06-14 14:26:34 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-06-14 16:26:07 +0200 |
commit | edde99bd213d20c55430dd29089e0d8a807ab6d8 (patch) | |
tree | 186fbfb97c296606a1584fd224777b3f6ed5f98e /testsuites/smptests/smp03 | |
parent | score: Add and use _Thread_Dispatch_if_necessary() (diff) | |
download | rtems-edde99bd213d20c55430dd29089e0d8a807ab6d8.tar.bz2 |
score: Rename rtems_smp_get_number_of_processors()
Rename in rtems_smp_get_processor_count(). Always provide
<rtems/score/smp.h> and <rtems/rtems/smp.h>. Add
_SMP_Get_processor_count(). This function will be a compile time
constant defined to be one on uni-processor configurations. This allows
iterations over all processors without overhead on uni-processor
configurations.
Diffstat (limited to 'testsuites/smptests/smp03')
-rw-r--r-- | testsuites/smptests/smp03/init.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/testsuites/smptests/smp03/init.c b/testsuites/smptests/smp03/init.c index 5371d49018..47441b3eec 100644 --- a/testsuites/smptests/smp03/init.c +++ b/testsuites/smptests/smp03/init.c @@ -49,7 +49,7 @@ rtems_task Init( /* Initialize the TaskRan array */ TaskRan[0] = true; - for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) { + for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) { TaskRan[i] = false; } @@ -57,7 +57,7 @@ rtems_task Init( PrintTaskInfo( "Init" ); /* for each remaining cpu create and start a task */ - for ( i=1; i < rtems_smp_get_number_of_processors(); i++ ){ + for ( i=1; i < rtems_smp_get_processor_count(); i++ ){ ch = '0' + i; @@ -87,12 +87,12 @@ rtems_task Init( RTEMS_DEFAULT_ATTRIBUTES, &id ); - status = rtems_task_start(id,Test_task,rtems_smp_get_number_of_processors()); + status = rtems_task_start(id,Test_task,rtems_smp_get_processor_count()); /* Wait on all tasks to run */ while (1) { TestFinished = true; - for ( i=1; i < (rtems_smp_get_number_of_processors()+1) ; i++ ) { + for ( i=1; i < (rtems_smp_get_processor_count()+1) ; i++ ) { if (TaskRan[i] == false) TestFinished = false; } |