Changeset 365456cc in rtems


Ignore:
Timestamp:
Dec 14, 2015, 2:10:32 PM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
af12278
Parents:
fd3cc36f
git-author:
Sebastian Huber <sebastian.huber@…> (12/14/15 14:10:32)
git-committer:
Sebastian Huber <sebastian.huber@…> (02/03/16 09:00:53)
Message:

Optional Classic Region initialization

Update #2408.

Files:
1 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • cpukit/rtems/Makefile.am

    rfd3cc36f r365456cc  
    222222librtems_a_SOURCES += src/regionresizesegment.c
    223223librtems_a_SOURCES += src/regionprocessqueue.c
    224 librtems_a_SOURCES += src/regiondata.c
    225224
    226225## PARTITION_C_FILES
  • cpukit/rtems/include/rtems/rtems/regionimpl.h

    rfd3cc36f r365456cc  
    3636
    3737/**
    38  *  @brief Instantiate RTEMS Region Data
    39  *
    40  *  Region Manager -- Instantiate Data
    41  *
    42  *  This constant is defined to extern most of the time when using
    43  *  this header file.  However by defining it to nothing, the data
    44  *  declared in this header file can be instantiated.  This is done
    45  *  in a single per manager file.
    46  */
    47 #ifndef RTEMS_REGION_EXTERN
    48 #define RTEMS_REGION_EXTERN extern
    49 #endif
    50 
    51 /**
    5238 *  The following defines the information control block used to
    5339 *  manage this class of objects.
    5440 */
    55 RTEMS_REGION_EXTERN Objects_Information _Region_Information;
    56 
    57 /**
    58  *  @brief _Region_Manager_initialization
    59  *
    60  *  Region Manager
    61  *
    62  *  This routine performs the initialization necessary for this manager.
    63  */
    64 void _Region_Manager_initialization(void);
     41extern Objects_Information _Region_Information;
    6542
    6643/**
  • cpukit/rtems/src/region.c

    rfd3cc36f r365456cc  
    2121#include <rtems/system.h>
    2222#include <rtems/config.h>
     23#include <rtems/sysinit.h>
    2324#include <rtems/rtems/status.h>
    2425#include <rtems/rtems/support.h>
    2526#include <rtems/rtems/options.h>
    2627#include <rtems/rtems/regionimpl.h>
    27 #include <rtems/score/thread.h>
    28 #include <rtems/score/apimutex.h>
     28
     29Objects_Information _Region_Information;
    2930
    3031/*
     
    3839 */
    3940
    40 void _Region_Manager_initialization(void)
     41static void _Region_Manager_initialization(void)
    4142{
    4243  _Objects_Initialize_information(
     
    6869
    6970}
     71
     72RTEMS_SYSINIT_ITEM(
     73  _Region_Manager_initialization,
     74  RTEMS_SYSINIT_CLASSIC_REGION,
     75  RTEMS_SYSINIT_ORDER_MIDDLE
     76);
  • cpukit/sapi/src/rtemsapi.c

    rfd3cc36f r365456cc  
    3131#include <rtems/rtems/dpmemimpl.h>
    3232#include <rtems/rtems/ratemonimpl.h>
    33 #include <rtems/rtems/regionimpl.h>
    3433
    3534void _RTEMS_API_Initialize(void)
    3635{
    37   _Region_Manager_initialization();
    3836  _Dual_ported_memory_Manager_initialization();
    3937  _Rate_monotonic_Manager_initialization();
  • cpukit/score/include/rtems/sysinit.h

    rfd3cc36f r365456cc  
    3939#define RTEMS_SYSINIT_CLASSIC_SEMAPHORE          000345
    4040#define RTEMS_SYSINIT_CLASSIC_PARTITION          000346
     41#define RTEMS_SYSINIT_CLASSIC_REGION             000347
    4142#define RTEMS_SYSINIT_IDLE_THREADS               000380
    4243#define RTEMS_SYSINIT_BSP_LIBC                   000400
  • testsuites/sptests/spsysinit01/init.c

    rfd3cc36f r365456cc  
    2828#include <rtems/rtems/messageimpl.h>
    2929#include <rtems/rtems/partimpl.h>
     30#include <rtems/rtems/regionimpl.h>
    3031#include <rtems/rtems/semimpl.h>
    3132#include <rtems/rtems/tasksimpl.h>
     
    6364  CLASSIC_PARTITION_PRE,
    6465  CLASSIC_PARTITION_POST,
     66  CLASSIC_REGION_PRE,
     67  CLASSIC_REGION_POST,
    6568  IDLE_THREADS_PRE,
    6669  IDLE_THREADS_POST,
     
    250253}
    251254
     255FIRST(RTEMS_SYSINIT_CLASSIC_REGION)
     256{
     257  assert(_Region_Information.maximum == 0);
     258  next_step(CLASSIC_REGION_PRE);
     259}
     260
     261LAST(RTEMS_SYSINIT_CLASSIC_REGION)
     262{
     263  assert(_Region_Information.maximum != 0);
     264  next_step(CLASSIC_REGION_POST);
     265}
     266
    252267FIRST(RTEMS_SYSINIT_IDLE_THREADS)
    253268{
     
    339354#define CONFIGURE_MAXIMUM_PARTITIONS 1
    340355
     356#define CONFIGURE_MAXIMUM_REGIONS 1
     357
    341358#define CONFIGURE_MAXIMUM_SEMAPHORES 1
    342359
Note: See TracChangeset for help on using the changeset viewer.