Changeset 0f5b2c09 in rtems for cpukit


Ignore:
Timestamp:
Dec 10, 2018, 11:51:33 AM (10 months ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
21275b58
Parents:
8b0e752
git-author:
Sebastian Huber <sebastian.huber@…> (12/10/18 11:51:33)
git-committer:
Sebastian Huber <sebastian.huber@…> (12/14/18 05:57:55)
Message:

rtems: Use object information to get config max

Use functions instead of macros. Add missing
rtems_configuration_get_maximum_*() functions.

Update #3621.

Location:
cpukit
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • cpukit/Makefile.am

    r8b0e752 r0f5b2c09  
    10211021librtemscpu_a_SOURCES += sapi/src/fatal.c
    10221022librtemscpu_a_SOURCES += sapi/src/fatalsrctext.c
     1023librtemscpu_a_SOURCES += sapi/src/getconfigmax.c
    10231024librtemscpu_a_SOURCES += sapi/src/getversionstring.c
    10241025librtemscpu_a_SOURCES += sapi/src/interrtext.c
  • cpukit/include/rtems/config.h

    r8b0e752 r0f5b2c09  
    277277            0 : rtems_configuration_get_stack_space_size()))
    278278
    279 #define rtems_configuration_get_maximum_extensions() \
    280         (Configuration.maximum_extensions)
     279uint32_t rtems_configuration_get_maximum_extensions( void );
    281280
    282281#define rtems_configuration_get_microseconds_per_tick() \
  • cpukit/include/rtems/rtems/config.h

    r8b0e752 r0f5b2c09  
    127127/**@}*/
    128128
    129 /**
    130  *  This macro returns the number of Classic API semaphores configured.
    131  */
    132 #define rtems_configuration_get_maximum_semaphores() \
    133         rtems_configuration_get_rtems_api_configuration()->maximum_semaphores
     129uint32_t rtems_configuration_get_maximum_barriers( void );
     130
     131uint32_t rtems_configuration_get_maximum_message_queues( void );
     132
     133uint32_t rtems_configuration_get_maximum_partitions( void );
     134
     135uint32_t rtems_configuration_get_maximum_periods( void );
     136
     137uint32_t rtems_configuration_get_maximum_ports( void );
     138
     139uint32_t rtems_configuration_get_maximum_regions( void );
     140
     141uint32_t rtems_configuration_get_maximum_semaphores( void );
     142
     143uint32_t rtems_configuration_get_maximum_timers( void );
     144
     145uint32_t rtems_configuration_get_maximum_tasks( void );
    134146
    135147#ifdef __cplusplus
  • cpukit/libmisc/monitor/mon-config.c

    r8b0e752 r0f5b2c09  
    3535
    3636    canonical_config->work_space_size = c->work_space_size;
    37     canonical_config->maximum_tasks = r->maximum_tasks;
    38     canonical_config->maximum_timers = r->maximum_timers;
    39     canonical_config->maximum_semaphores = r->maximum_semaphores;
    40     canonical_config->maximum_message_queues = r->maximum_message_queues;
    41     canonical_config->maximum_partitions = r->maximum_partitions;
    42     canonical_config->maximum_regions = r->maximum_regions;
    43     canonical_config->maximum_ports = r->maximum_ports;
    44     canonical_config->maximum_periods = r->maximum_periods;
    45     canonical_config->maximum_extensions = c->maximum_extensions;
     37    canonical_config->maximum_tasks = rtems_configuration_get_maximum_tasks();
     38    canonical_config->maximum_timers = rtems_configuration_get_maximum_timers();
     39    canonical_config->maximum_semaphores = rtems_configuration_get_maximum_semaphores();
     40    canonical_config->maximum_message_queues = rtems_configuration_get_maximum_message_queues();
     41    canonical_config->maximum_partitions = rtems_configuration_get_maximum_partitions();
     42    canonical_config->maximum_regions = rtems_configuration_get_maximum_regions();
     43    canonical_config->maximum_ports = rtems_configuration_get_maximum_ports();
     44    canonical_config->maximum_periods = rtems_configuration_get_maximum_periods();
     45    canonical_config->maximum_extensions = rtems_configuration_get_maximum_extensions();
    4646    canonical_config->microseconds_per_tick = c->microseconds_per_tick;
    4747    canonical_config->ticks_per_timeslice = c->ticks_per_timeslice;
  • cpukit/sapi/src/extension.c

    r8b0e752 r0f5b2c09  
    3434    OBJECTS_CLASSIC_API,                 /* object API */
    3535    OBJECTS_RTEMS_EXTENSIONS,
    36     rtems_configuration_get_maximum_extensions(),
     36    Configuration.maximum_extensions,
    3737    sizeof( Extension_Control ),
    3838    OBJECTS_NO_STRING_NAME,    /* maximum length of an object name */
Note: See TracChangeset for help on using the changeset viewer.