Changeset edde99b in rtems


Ignore:
Timestamp:
Jun 14, 2013, 12:26:34 PM (6 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
477259c
Parents:
5c78940d
git-author:
Sebastian Huber <sebastian.huber@…> (06/14/13 12:26:34)
git-committer:
Sebastian Huber <sebastian.huber@…> (06/14/13 14:26:07)
Message:

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.

Files:
28 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/sparc/leon3/smp/smp_leon3.c

    r5c78940d redde99b  
    131131
    132132  cpu = bsp_smp_processor_id();
    133   max_cpus = rtems_smp_get_number_of_processors();
     133  max_cpus = rtems_smp_get_processor_count();
    134134
    135135  for ( dest_cpu=0 ; dest_cpu < max_cpus ; dest_cpu++ ) {
  • cpukit/libmisc/cpuuse/cpuusagereport.c

    r5c78940d redde99b  
    4040    #else
    4141      int  cpu;
    42       for ( cpu=0 ; cpu < rtems_smp_get_number_of_processors() ; cpu++ ) {
     42      for ( cpu=0 ; cpu < rtems_smp_get_processor_count() ; cpu++ ) {
    4343        Per_CPU_Control *p = &_Per_CPU_Information[cpu];
    4444        if ( p->executing->Object.id == the_thread->Object.id ) {
  • cpukit/rtems/Makefile.am

    r5c78940d redde99b  
    3535include_rtems_rtems_HEADERS += include/rtems/rtems/sem.h
    3636include_rtems_rtems_HEADERS += include/rtems/rtems/signal.h
     37include_rtems_rtems_HEADERS += include/rtems/rtems/smp.h
    3738include_rtems_rtems_HEADERS += include/rtems/rtems/status.h
    3839include_rtems_rtems_HEADERS += include/rtems/rtems/support.h
     
    5354include_rtems_rtems_HEADERS += include/rtems/rtems/signalmp.h
    5455include_rtems_rtems_HEADERS += include/rtems/rtems/taskmp.h
    55 endif
    56 
    57 if HAS_SMP
    58 include_rtems_rtems_HEADERS += include/rtems/rtems/smp.h
    5956endif
    6057
  • cpukit/rtems/include/rtems.h

    r5c78940d redde99b  
    7474#include <rtems/rtems/mp.h>
    7575#endif
    76 #if defined(RTEMS_SMP)
    7776#include <rtems/rtems/smp.h>
    78 #endif
    7977
    8078
  • cpukit/rtems/include/rtems/rtems/smp.h

    r5c78940d redde99b  
    11/**
    2  * @file rtems/rtems/smp.h
     2 * @file
    33 *
    4  * @defgroup ClassicSMP Classic API SMP Services
     4 * @ingroup ClassicSMP
    55 *
    6  * @ingroup ClassicRTEMS
    7  * @brief SMP information and services.
    8  *
    9  * Most of the SMP interface is hidden from the application
    10  * and exists between the BSP and RTEMS.
     6 * @brief SMP Services API
    117 */
    128
    13 /* COPYRIGHT (c) 1989-2011.
     9/*
     10 * COPYRIGHT (c) 1989-2011.
    1411 * On-Line Applications Research Corporation (OAR).
    1512 *
     
    2926
    3027/**
    31  *  @defgroup ClassicSMP Classic API SMP Services
     28 * @defgroup ClassicSMP SMP Services
    3229 *
    33  *  @ingroup ClassicRTEMS
     30 * @ingroup ClassicRTEMS
    3431 *
    35  *  This encapsulates functionality which is useful for SMP applications.
     32 * This encapsulates functionality which is useful for SMP applications.
     33 *
     34 * This API is also available on uni-processor configurations.  Here compile
     35 * time constants are used whenever possible.
     36 *
     37 * @{
    3638 */
    37 /**@{*/
    3839
    3940/**
    40  * @brief Obtain Number of Cores in System
     41 * @brief Returns the count of processors in the system.
    4142 *
    42  * This method returns the number of CPU cores that are currently in
    43  * the system. This will always be less than or equal to the number
    44  * of maximum number of cores which were configured.
     43 * On uni-processor configurations this is a compile time constant and defined
     44 * to be one.
    4545 *
    46  * @retval This method returns the number of cores in this system.
     46 * On SMP configurations this returns the value of a global variable set during
     47 * system initialization to indicate the count of processors.  The processor
     48 * count depends on the hardware and application configuration.  The value will
     49 * always be less than or equal to the maximum count of application configured
     50 * processors.
     51 *
     52 * @return The count of processors in the system.
    4753 */
    48 #define rtems_smp_get_number_of_processors() \
    49     (_SMP_Processor_count)
     54#define rtems_smp_get_processor_count() \
     55  _SMP_Get_processor_count()
    5056
    5157/**
     
    5965    bsp_smp_processor_id()
    6066
    61 /**@}*/
     67/** @} */
    6268
    6369#ifdef __cplusplus
  • cpukit/rtems/preinstall.am

    r5c78940d redde99b  
    108108PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/rtems/signal.h
    109109
     110$(PROJECT_INCLUDE)/rtems/rtems/smp.h: include/rtems/rtems/smp.h $(PROJECT_INCLUDE)/rtems/rtems/$(dirstamp)
     111        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/rtems/smp.h
     112PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/rtems/smp.h
     113
    110114$(PROJECT_INCLUDE)/rtems/rtems/status.h: include/rtems/rtems/status.h $(PROJECT_INCLUDE)/rtems/rtems/$(dirstamp)
    111115        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/rtems/status.h
     
    169173PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/rtems/taskmp.h
    170174endif
    171 if HAS_SMP
    172 $(PROJECT_INCLUDE)/rtems/rtems/smp.h: include/rtems/rtems/smp.h $(PROJECT_INCLUDE)/rtems/rtems/$(dirstamp)
    173         $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/rtems/smp.h
    174 PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/rtems/smp.h
    175 endif
    176175$(PROJECT_INCLUDE)/rtems/rtems/asr.inl: inline/rtems/rtems/asr.inl $(PROJECT_INCLUDE)/rtems/rtems/$(dirstamp)
    177176        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/rtems/asr.inl
  • cpukit/score/Makefile.am

    r5c78940d redde99b  
    4141include_rtems_score_HEADERS += include/rtems/score/schedulerpriority.h
    4242include_rtems_score_HEADERS += include/rtems/score/schedulersimple.h
     43include_rtems_score_HEADERS += include/rtems/score/smp.h
    4344include_rtems_score_HEADERS += include/rtems/score/smplock.h
    4445include_rtems_score_HEADERS += include/rtems/score/stack.h
     
    6364include_rtems_score_HEADERS += include/rtems/score/genericcpuatomic.h
    6465include_rtems_score_HEADERS += include/rtems/score/genericatomicops.h
    65 if HAS_SMP
    66 include_rtems_score_HEADERS += include/rtems/score/smp.h
    67 endif
    6866
    6967if HAS_PTHREADS
  • cpukit/score/include/rtems/score/smp.h

    r5c78940d redde99b  
    11/**
    2  *  @file  rtems/score/smp.h
     2 * @file
    33 *
    4  *  @brief Interface to the SuperCore SMP Support used Internally to RTEMS
     4 * @ingroup ScoreSMP
    55 *
    6  *  This include file defines the interface to the SuperCore
    7  *  SMP support that is used internally to RTEMS.
     6 * @brief SuperCore SMP Support API
    87 */
    98
     
    2019#define _RTEMS_SCORE_SMP_H
    2120
    22 #if defined (RTEMS_SMP)
    23 #include <rtems/score/percpu.h>
    24 
    25 /**
    26  *  @defgroup SuperCoreSMP SMP Support
    27  *
    28  *  @ingroup Score
    29  *
    30  *  This defines the interface of the SuperCore support
    31  *  code for SMP support.
    32  */
    33 
    34 /**@{*/
     21#include <rtems/score/cpu.h>
    3522
    3623#ifdef __cplusplus
    3724extern "C" {
    3825#endif
     26
     27/**
     28 * @defgroup ScoreSMP SMP Support
     29 *
     30 * @ingroup Score
     31 *
     32 * This defines the interface of the SuperCore SMP support.
     33 *
     34 * @{
     35 */
    3936
    4037/**
     
    5956#define RTEMS_BSP_SMP_SHUTDOWN                  0x04
    6057
    61 #ifndef ASM
    62 /**
    63  *  @brief Number of CPUs in a SMP system.
    64  *
    65  *  This variable is set during the SMP initialization sequence to
    66  *  indicate the number of CPUs in this system.
    67  */
    68 SCORE_EXTERN uint32_t _SMP_Processor_count;
     58#if !defined( ASM )
     59
     60#if defined( RTEMS_SMP )
     61  SCORE_EXTERN uint32_t _SMP_Processor_count;
     62
     63  static inline uint32_t _SMP_Get_processor_count( void )
     64  {
     65    return _SMP_Processor_count;
     66  }
     67#else
     68  #define _SMP_Get_processor_count() ( ( uint32_t ) 1 )
     69#endif
     70
     71#if defined( RTEMS_SMP )
    6972
    7073/**
     
    115118void _SMP_Request_other_cores_to_shutdown(void);
    116119
    117 #endif
     120#endif /* defined( RTEMS_SMP ) */
     121
     122#endif /* !defined( ASM ) */
     123
     124/** @} */
    118125
    119126#ifdef __cplusplus
     
    122129
    123130#endif
    124 
    125 /**@}*/
    126 #endif
    127131/* end of include file */
  • cpukit/score/preinstall.am

    r5c78940d redde99b  
    144144PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/schedulersimple.h
    145145
     146$(PROJECT_INCLUDE)/rtems/score/smp.h: include/rtems/score/smp.h $(PROJECT_INCLUDE)/rtems/score/$(dirstamp)
     147        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/score/smp.h
     148PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/smp.h
     149
    146150$(PROJECT_INCLUDE)/rtems/score/smplock.h: include/rtems/score/smplock.h $(PROJECT_INCLUDE)/rtems/score/$(dirstamp)
    147151        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/score/smplock.h
     
    232236PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/genericatomicops.h
    233237
    234 if HAS_SMP
    235 $(PROJECT_INCLUDE)/rtems/score/smp.h: include/rtems/score/smp.h $(PROJECT_INCLUDE)/rtems/score/$(dirstamp)
    236         $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/score/smp.h
    237 PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/smp.h
    238 endif
    239238if HAS_PTHREADS
    240239$(PROJECT_INCLUDE)/rtems/score/corespinlock.h: include/rtems/score/corespinlock.h $(PROJECT_INCLUDE)/rtems/score/$(dirstamp)
  • cpukit/score/src/smp.c

    r5c78940d redde99b  
    127127{
    128128  int self = bsp_smp_processor_id();
    129   int ncpus = _SMP_Processor_count;
     129  int ncpus = _SMP_Get_processor_count();
    130130  int cpu;
    131131
     
    147147{
    148148  int self = bsp_smp_processor_id();
    149   int ncpus = _SMP_Processor_count;
     149  int ncpus = _SMP_Get_processor_count();
    150150  int cpu;
    151151
     
    166166  if ( _System_state_Is_up( _System_state_Get() ) ) {
    167167    int self = bsp_smp_processor_id();
    168     int ncpus = _SMP_Processor_count;
     168    int ncpus = _SMP_Get_processor_count();
    169169    int cpu;
    170170
     
    186186{
    187187  int self = bsp_smp_processor_id();
    188   int ncpus = _SMP_Processor_count;
     188  int ncpus = _SMP_Get_processor_count();
    189189  int cpu;
    190190
  • cpukit/score/src/threadcreateidle.c

    r5c78940d redde99b  
    9090    int cpu;
    9191
    92     for ( cpu=0 ; cpu < _SMP_Processor_count ; cpu++ ) {
     92    for ( cpu=0 ; cpu < _SMP_Get_processor_count() ; cpu++ ) {
    9393      _Thread_Create_idle_helper(
    9494        _Objects_Build_name( 'I', 'D', 'L', 'E' ),
  • testsuites/smptests/smp01/init.c

    r5c78940d redde99b  
    4545
    4646  /* Initialize the TaskRan array */
    47   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     47  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    4848    TaskRan[i] = false;
    4949  }
    5050
    5151  /* Create and start tasks for each processor */
    52   for ( i=0; i< rtems_smp_get_number_of_processors() ; i++ ) {
     52  for ( i=0; i< rtems_smp_get_processor_count() ; i++ ) {
    5353    if ( i != cpu_self ) {
    5454      ch = '0' + i;
     
    7575  while (1) {
    7676    allDone = true;
    77     for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     77    for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    7878      if ( i != cpu_self && TaskRan[i] == false)
    7979        allDone = false;
  • testsuites/smptests/smp02/init.c

    r5c78940d redde99b  
    4646  directive_failed( status,"rtems_semaphore_obtain of SEM1\n");
    4747
    48   for ( i=1; i < rtems_smp_get_number_of_processors(); i++ ){
     48  for ( i=1; i < rtems_smp_get_processor_count(); i++ ){
    4949
    5050    /* Create and start tasks for each CPU */
  • testsuites/smptests/smp03/init.c

    r5c78940d redde99b  
    5050  /* Initialize the TaskRan array */
    5151  TaskRan[0] = true;
    52   for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     52  for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    5353    TaskRan[i] = false;
    5454  }
     
    5858
    5959  /* for each remaining cpu create and start a task */
    60   for ( i=1; i < rtems_smp_get_number_of_processors(); i++ ){
     60  for ( i=1; i < rtems_smp_get_processor_count(); i++ ){
    6161
    6262    ch = '0' + i;
     
    8888    &id
    8989  );
    90   status = rtems_task_start(id,Test_task,rtems_smp_get_number_of_processors());
     90  status = rtems_task_start(id,Test_task,rtems_smp_get_processor_count());
    9191
    9292  /* Wait on all tasks to run */
    9393  while (1) {
    9494    TestFinished = true;
    95     for ( i=1; i < (rtems_smp_get_number_of_processors()+1) ; i++ ) {
     95    for ( i=1; i < (rtems_smp_get_processor_count()+1) ; i++ ) {
    9696      if (TaskRan[i] == false)
    9797        TestFinished = false;
  • testsuites/smptests/smp04/init.c

    r5c78940d redde99b  
    5959  /* Set all Tasks to not ran except for the init task */
    6060  TaskRan[0] = true;
    61   for ( i=1; i <= rtems_smp_get_number_of_processors() ; i++ )
     61  for ( i=1; i <= rtems_smp_get_processor_count() ; i++ )
    6262    TaskRan[i] = false;
    6363 
     
    6767   * between  RTEMS_PREEMPT and RTEMS_NO_PREEMPT.
    6868   */
    69   for ( i=1; i < rtems_smp_get_number_of_processors() ; i++ ){
     69  for ( i=1; i < rtems_smp_get_processor_count() ; i++ ){
    7070
    7171    /* Create and start tasks for each CPU */
     
    8080      rtems_build_name( 'T', 'A', ch, ' ' ),
    8181      CONFIGURE_INIT_TASK_PRIORITY +
    82         (2*rtems_smp_get_number_of_processors()) - (2*i),
     82        (2*rtems_smp_get_processor_count()) - (2*i),
    8383      RTEMS_MINIMUM_STACK_SIZE,
    8484      ((i%2) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT),
     
    107107   * task and run on that cpu.
    108108   */
    109   ch = '0' + rtems_smp_get_number_of_processors() ;
     109  ch = '0' + rtems_smp_get_processor_count() ;
    110110  locked_printf(
    111111    "Create a TA%c a %s task\n",
     
    129129    id,
    130130    Test_task,
    131     rtems_smp_get_number_of_processors()
     131    rtems_smp_get_processor_count()
    132132  );
    133133 
     
    137137  while (1) {
    138138    allDone = true;
    139     for ( i=1; i<=rtems_smp_get_number_of_processors() ; i++ ) {
     139    for ( i=1; i<=rtems_smp_get_processor_count() ; i++ ) {
    140140      if (TaskRan[i] == false)
    141141        allDone = false;
  • testsuites/smptests/smp05/init.c

    r5c78940d redde99b  
    3737  locked_printf( "\n\n*** TEST SMP05 ***\n" );
    3838
    39   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     39  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    4040    ch = '1' + i;
    4141
  • testsuites/smptests/smp06/init.c

    r5c78940d redde99b  
    5555  directive_failed( status, "clock tick" );
    5656
    57   rtems_test_assert( rtems_smp_get_number_of_processors()  > 1 );
     57  rtems_test_assert( rtems_smp_get_processor_count()  > 1 );
    5858
    5959  cpu_num = bsp_smp_processor_id();
  • testsuites/smptests/smp08/init.c

    r5c78940d redde99b  
    7474  PrintTaskInfo( "Init", &time );
    7575
    76   for ( i=1; i <= rtems_smp_get_number_of_processors() *3; i++ ) {
     76  for ( i=1; i <= rtems_smp_get_processor_count() *3; i++ ) {
    7777
    7878    sprintf(ch, "%02" PRId32, i );
  • testsuites/smptests/smp09/init.c

    r5c78940d redde99b  
    4343    ;
    4444 
    45   for ( i=0; i<rtems_smp_get_number_of_processors() -1; i++ ) {
     45  for ( i=0; i<rtems_smp_get_processor_count() -1; i++ ) {
    4646    ch = '1' + i;
    4747
  • testsuites/smptests/smpatomic01/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smpatomic02/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smpatomic03/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smpatomic04/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smpatomic05/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smpatomic06/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smpatomic07/init.c

    r5c78940d redde99b  
    3636
    3737  /* Initialize the TaskRan array */
    38   for ( i=0; i<rtems_smp_get_number_of_processors() ; i++ ) {
     38  for ( i=0; i<rtems_smp_get_processor_count() ; i++ ) {
    3939    TaskRan[i] = false;
    4040  }
    4141
    4242  /* Create and start tasks for each processor */
    43   for ( i=1; i< rtems_smp_get_number_of_processors() ; i++ ) {
     43  for ( i=1; i< rtems_smp_get_processor_count() ; i++ ) {
    4444    ch = '0' + i;
    4545
     
    6161  while (1) {
    6262    allDone = true;
    63     for ( i=1; i<rtems_smp_get_number_of_processors() ; i++ ) {
     63    for ( i=1; i<rtems_smp_get_processor_count() ; i++ ) {
    6464      if (TaskRan[i] == false)
    6565        allDone = false;
  • testsuites/smptests/smplock01/init.c

    r5c78940d redde99b  
    299299{
    300300  global_context *ctx = (global_context *) arg;
    301   int cpu_count = (int) rtems_smp_get_number_of_processors();
     301  int cpu_count = (int) rtems_smp_get_processor_count();
    302302  int cpu_self = rtems_smp_get_current_processor();
    303303  rtems_status_code sc;
     
    313313{
    314314  global_context *ctx = &context;
    315   int cpu_count = (int) rtems_smp_get_number_of_processors();
     315  int cpu_count = (int) rtems_smp_get_processor_count();
    316316  int cpu_self = rtems_smp_get_current_processor();
    317317  int cpu;
  • testsuites/sptests/spsize/size.c

    r5c78940d redde99b  
    342342#endif
    343343
    344 #if defined(RTEMS_SMP)
    345 /*percpu.h*/    (_SMP_Processor_count * sizeof(Per_CPU_Control))  +
    346 #else
    347 /*percpu.h*/    (sizeof (Per_CPU_Control) )                       +
    348 #endif
     344/*percpu.h*/    (_SMP_Get_processor_count() * sizeof(Per_CPU_Control))  +
    349345
    350346/*ratemon.h*/   (sizeof _Rate_monotonic_Information)      +
Note: See TracChangeset for help on using the changeset viewer.