Changeset 790b50b in rtems


Ignore:
Timestamp:
Dec 17, 2008, 10:46:05 PM (10 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, master
Children:
1fae1c6b
Parents:
e06ecec5
Message:

2008-12-17 Joel Sherrill <joel.sherrill@…>

  • sapi/include/rtems/extension.h, sapi/include/rtems/io.h, sapi/src/exinit.c, sapi/src/extension.c, sapi/src/io.c, score/include/rtems/score/mpci.h, score/include/rtems/score/object.h, score/include/rtems/score/thread.h, score/include/rtems/score/tod.h, score/include/rtems/score/userext.h, score/include/rtems/score/wkspace.h, score/src/coretod.c, score/src/mpci.c, score/src/object.c, score/src/thread.c, score/src/userext.c, score/src/wkspace.c: Convert SAPI manager and SuperCore? Handler initialization routines to directly pull parameters from configuration table.
Location:
cpukit
Files:
18 edited

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    re06ecec5 r790b50b  
     12008-12-17      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * sapi/include/rtems/extension.h, sapi/include/rtems/io.h,
     4        sapi/src/exinit.c, sapi/src/extension.c, sapi/src/io.c,
     5        score/include/rtems/score/mpci.h, score/include/rtems/score/object.h,
     6        score/include/rtems/score/thread.h, score/include/rtems/score/tod.h,
     7        score/include/rtems/score/userext.h,
     8        score/include/rtems/score/wkspace.h, score/src/coretod.c,
     9        score/src/mpci.c, score/src/object.c, score/src/thread.c,
     10        score/src/userext.c, score/src/wkspace.c: Convert SAPI manager and
     11        SuperCore Handler initialization routines to directly pull parameters
     12        from configuration table.
     13
    1142008-12-17      Joel Sherrill <joel.sherrill@oarcorp.com>
    215
  • cpukit/sapi/include/rtems/extension.h

    re06ecec5 r790b50b  
    1414 *     + delete user extension set
    1515 *
    16  *  COPYRIGHT (c) 1989-2007.
     16 *  COPYRIGHT (c) 1989-2008.
    1717 *  On-Line Applications Research Corporation (OAR).
    1818 *
     
    8383 */
    8484
    85 void _Extension_Manager_initialization(
    86   uint32_t   maximum_extensions
    87 );
     85void _Extension_Manager_initialization(void);
    8886
    8987/*
  • cpukit/sapi/include/rtems/io.h

    re06ecec5 r790b50b  
    1818 
    1919/*
    20  *  COPYRIGHT (c) 1989-1999.
     20 *  COPYRIGHT (c) 1989-2008.
    2121 *  On-Line Applications Research Corporation (OAR).
    2222 *
     
    104104 */
    105105
    106 void _IO_Manager_initialization(
    107   rtems_driver_address_table *driver_table,
    108   uint32_t                    drivers_in_table,
    109   uint32_t                    number_of_drivers
    110 );
     106void _IO_Manager_initialization(void);
    111107
    112108/*
  • cpukit/sapi/src/exinit.c

    re06ecec5 r790b50b  
    112112   *  from the Workspace because it is not initialized.
    113113   */
    114   _Workspace_Handler_initialization(
    115     Configuration.work_space_start,
    116     Configuration.work_space_size
    117   );
    118 
    119   _User_extensions_Handler_initialization(
    120     Configuration.number_of_initial_extensions,
    121     Configuration.User_extension_table
    122   );
    123 
     114  _Workspace_Handler_initialization();
     115
     116  _User_extensions_Handler_initialization();
    124117  _ISR_Handler_initialization();
    125 
    126   _Objects_Handler_initialization(
    127     #if defined(RTEMS_MULTIPROCESSING)
    128       _Configuration_MP_table->node,
    129       _Configuration_MP_table->maximum_nodes,
    130       _Configuration_MP_table->maximum_global_objects
    131     #endif
    132   );
    133 
     118  _Objects_Handler_initialization();
     119
     120  /*
     121   * Initialize the internal support API and allocator Mutex
     122   */
    134123  _Objects_Information_table[OBJECTS_INTERNAL_API] = _Internal_Objects;
    135124
    136   /*
    137    * Initialize the internal allocator Mutex
    138    */
    139125  _API_Mutex_Initialization( 1 );
    140126  _API_Mutex_Allocate( &_RTEMS_Allocator_Mutex );
    141127
    142128  _Priority_Handler_initialization();
    143 
    144129  _Watchdog_Handler_initialization();
    145 
    146   _TOD_Handler_initialization( Configuration.microseconds_per_tick );
    147 
    148   _Thread_Handler_initialization(
    149     Configuration.ticks_per_timeslice,
    150     Configuration.maximum_extensions
    151     #if defined(RTEMS_MULTIPROCESSING)
    152       ,
    153       _Configuration_MP_table->maximum_proxies
    154     #endif
    155   );
    156 
    157   #if defined(RTEMS_MULTIPROCESSING)
    158     _MPCI_Handler_initialization(
    159       _Configuration_MP_table->User_mpci_table,
    160       RTEMS_TIMEOUT
    161     );
     130  _TOD_Handler_initialization();
     131
     132  _Thread_Handler_initialization();
     133
     134  #if defined(RTEMS_MULTIPROCESSING)
     135    _MPCI_Handler_initialization( RTEMS_TIMEOUT );
    162136  #endif
    163137
     
    166140  _RTEMS_API_Initialize();
    167141
    168   _Extension_Manager_initialization( Configuration.maximum_extensions );
    169 
    170   _IO_Manager_initialization(
    171     Configuration.Device_driver_table,
    172     Configuration.number_of_device_drivers,
    173     Configuration.maximum_drivers
    174   );
     142  _Extension_Manager_initialization();
     143
     144  _IO_Manager_initialization();
    175145
    176146  #ifdef RTEMS_POSIX_API
  • cpukit/sapi/src/extension.c

    re06ecec5 r790b50b  
    22 *  Extension Manager
    33 *
    4  *  COPYRIGHT (c) 1989-2007.
     4 *  COPYRIGHT (c) 1989-2008.
    55 *  On-Line Applications Research Corporation (OAR).
    66 *
     
    1717
    1818#include <rtems/system.h>
     19#include <rtems/config.h>
    1920#include <rtems/rtems/support.h>
    2021#include <rtems/score/object.h>
     
    2829 *  This routine initializes all extension manager related data structures.
    2930 *
    30  *  Input parameters:
    31  *    maximum_extensions - number of extensions to initialize
     31 *  Input parameters:   NONE
    3232 *
    3333 *  Output parameters:  NONE
    3434 */
    3535
    36 void _Extension_Manager_initialization(
    37   uint32_t   maximum_extensions
    38 )
     36void _Extension_Manager_initialization(void)
    3937{
    4038  _Objects_Initialize_information(
     
    4240    OBJECTS_CLASSIC_API,                 /* object API */
    4341    OBJECTS_RTEMS_EXTENSIONS,
    44     maximum_extensions,
     42    Configuration.maximum_extensions,
    4543    sizeof( Extension_Control ),
    4644    false,                     /* true if the name is a string */
  • cpukit/sapi/src/io.c

    re06ecec5 r790b50b  
    22 *  Input/Output Manager - Initialize Device Driver Subsystem
    33 *
    4  *  COPYRIGHT (c) 1989-2007.
     4 *  COPYRIGHT (c) 1989-2008.
    55 *  On-Line Applications Research Corporation (OAR).
    66 *
     
    1717
    1818#include <rtems/system.h>
     19#include <rtems/config.h>
    1920#include <rtems/io.h>
    2021#include <rtems/score/isr.h>
     
    3334 */
    3435
    35 void _IO_Manager_initialization(
    36   rtems_driver_address_table *driver_table,
    37   uint32_t                    drivers_in_table,
    38   uint32_t                    number_of_drivers
    39 )
     36void _IO_Manager_initialization(void)
    4037{
    41   uint32_t index;
     38  uint32_t                    index;
     39  rtems_driver_address_table *driver_table;
     40  uint32_t                    drivers_in_table;
     41  uint32_t                    number_of_drivers;
     42
     43  driver_table      = Configuration.Device_driver_table;
     44  drivers_in_table  = Configuration.number_of_device_drivers;
     45  number_of_drivers = Configuration.maximum_drivers;
    4246
    4347  /*
  • cpukit/score/include/rtems/score/mpci.h

    re06ecec5 r790b50b  
    77
    88/*
    9  *  COPYRIGHT (c) 1989-2006.
     9 *  COPYRIGHT (c) 1989-2008.
    1010 *  On-Line Applications Research Corporation (OAR).
    1111 *
     
    198198 *  This routine performs the initialization necessary for this handler.
    199199 *
    200  *  @param[in] users_mpci_table is a pointer to the application configured
    201  *             MPCI Table.  This table contains pointers to the MPCI Layers
    202  *             entry points.
    203200 *  @param[in] timeout_status is the value which should be returned to
    204201 *             blocking threads when they timeout on a remote operation.
    205202 */
    206203void _MPCI_Handler_initialization(
    207   MPCI_Control            *users_mpci_table,
    208   uint32_t                 timeout_status
     204  uint32_t   timeout_status
    209205);
    210206
  • cpukit/score/include/rtems/score/object.h

    re06ecec5 r790b50b  
    435435#define OBJECTS_ID_FINAL           ((Objects_Id)~0)
    436436
    437 #if defined(RTEMS_MULTIPROCESSING)
    438437/**
    439438 *  This function performs the initialization necessary for this handler.
    440  *
    441  *  @param[in] node indicates the identifying number of this node.
    442  *  @param[in] maximum_nodes is the maximum number of nodes in this system.
    443  *  @param[in] maximum_global_objects is maximum number of global objects
    444  *             concurrently offered in the system.
    445  */
    446 void _Objects_Handler_initialization(
    447   uint32_t   node,
    448   uint32_t   maximum_nodes,
    449   uint32_t   maximum_global_objects
    450 );
    451 #else
    452 /**
    453  *  This function performs the initialization necessary for this handler.
    454439 */
    455440void _Objects_Handler_initialization(void);
    456 #endif
    457441
    458442/**
  • cpukit/score/include/rtems/score/thread.h

    re06ecec5 r790b50b  
    507507 *  This routine performs the initialization necessary for this handler.
    508508 */
    509 void _Thread_Handler_initialization (
    510   uint32_t     ticks_per_timeslice,
    511   uint32_t     maximum_extensions
    512 #if defined(RTEMS_MULTIPROCESSING)
    513   ,
    514   uint32_t     maximum_proxies
    515 #endif
    516 );
     509void _Thread_Handler_initialization(void);
    517510
    518511/**
     
    521514 *  @warning No thread should be created before this one.
    522515 */
    523 void _Thread_Create_idle( void );
     516void _Thread_Create_idle(void);
    524517
    525518/**
  • cpukit/score/include/rtems/score/tod.h

    re06ecec5 r790b50b  
    145145 *  This routine performs the initialization necessary for this handler.
    146146 */
    147 void _TOD_Handler_initialization(
    148   uint32_t   microseconds_per_tick
    149 );
     147void _TOD_Handler_initialization(void);
    150148
    151149/** @brief _TOD_Set
  • cpukit/score/include/rtems/score/userext.h

    re06ecec5 r790b50b  
    88
    99/*
    10  *  COPYRIGHT (c) 1989-2006.
     10 *  COPYRIGHT (c) 1989-2008.
    1111 *  On-Line Applications Research Corporation (OAR).
    1212 *
     
    206206 *
    207207 *  This routine performs the initialization necessary for this handler.
    208  *
    209  *  @param[in] number_of_extensions is the number of extensions
    210  *  @param[in] initial_extensions is the initial extension set
    211  */
    212 void _User_extensions_Handler_initialization (
    213   uint32_t                number_of_extensions,
    214   User_extensions_Table  *initial_extensions
    215 );
     208 */
     209void _User_extensions_Handler_initialization(void);
    216210
    217211/** @brief User extensions Add to API extension set
  • cpukit/score/include/rtems/score/wkspace.h

    re06ecec5 r790b50b  
    88
    99/*
    10  *  COPYRIGHT (c) 1989-2006.
     10 *  COPYRIGHT (c) 1989-2008.
    1111 *  On-Line Applications Research Corporation (OAR).
    1212 *
     
    4646 *
    4747 *  This routine performs the initialization necessary for this handler.
    48  *
    49  *  @param[in] starting_address is the base address of the RTEMS Executive
    50  *         Workspace
    51  *  @param[in] size is the number of bytes in the RTEMS Executive Workspace
    5248 */
    53 void _Workspace_Handler_initialization(
    54   void       *starting_address,
    55   size_t      size
    56 );
     49void _Workspace_Handler_initialization(void);
    5750
    5851/** @brief Allocate Memory from Workspace
  • cpukit/score/src/coretod.c

    re06ecec5 r790b50b  
    33 */
    44
    5 /*  COPYRIGHT (c) 1989-2007.
     5/*  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    2929 *  This routine initializes the time of day handler.
    3030 *
    31  *  Input parameters:
    32  *    microseconds_per_tick - microseconds between clock ticks
     31 *  Input parameters:  NONE
    3332 *
    3433 *  Output parameters: NONE
    3534 */
    3635
    37 void _TOD_Handler_initialization(
    38   uint32_t   microseconds_per_tick
    39 )
     36void _TOD_Handler_initialization(void)
    4037{
    4138  /* POSIX format TOD (timespec) */
  • cpukit/score/src/mpci.c

    re06ecec5 r790b50b  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-2007.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    2222#include <rtems/score/mppkt.h>
    2323#endif
     24#include <rtems/config.h>
    2425#include <rtems/score/cpu.h>
    2526#include <rtems/score/interr.h>
     
    4748
    4849void _MPCI_Handler_initialization(
    49   MPCI_Control            *users_mpci_table,
    50   uint32_t                 timeout_status
    51 )
    52 {
    53   CORE_semaphore_Attributes    attributes;
     50  uint32_t   timeout_status
     51)
     52{
     53  CORE_semaphore_Attributes   attributes;
     54  MPCI_Control               *users_mpci_table;
     55
     56  users_mpci_table = _Configuration_MP_table->User_mpci_table;
    5457
    5558  if ( _System_state_Is_multiprocessing && !users_mpci_table )
  • cpukit/score/src/object.c

    re06ecec5 r790b50b  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-2007.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    1818
    1919#include <rtems/system.h>
     20#include <rtems/config.h>
    2021#include <rtems/score/address.h>
    2122#include <rtems/score/chain.h>
     
    3536 *  This routine initializes the object handler.
    3637 *
    37  *  Input parameters:
    38  *    node                   - local node
    39  *    maximum_nodes          - number of nodes in the system
    40  *    maximum_global_objects - number of configured global objects
     38 *  Input parameters:   NONE
    4139 *
    4240 *  Output parameters:  NONE
    4341 */
    4442
    45 #if defined(RTEMS_MULTIPROCESSING)
    46 void _Objects_Handler_initialization(
    47   uint32_t   node,
    48   uint32_t   maximum_nodes,
    49   uint32_t   maximum_global_objects )
    50 #else
    5143void _Objects_Handler_initialization(void)
    52 #endif
    5344{
    5445#if defined(RTEMS_MULTIPROCESSING)
     46  uint32_t   node;
     47  uint32_t   maximum_nodes;
     48  uint32_t   maximum_global_objects;
     49
     50  node                   = _Configuration_MP_table->node;
     51  maximum_nodes          = _Configuration_MP_table->maximum_nodes;
     52  maximum_global_objects = _Configuration_MP_table->maximum_global_objects;
     53 
    5554  if ( node < 1 || node > maximum_nodes )
    5655    _Internal_error_Occurred(
  • cpukit/score/src/thread.c

    re06ecec5 r790b50b  
    1818
    1919#include <rtems/system.h>
     20#include <rtems/config.h>
    2021#include <rtems/score/apiext.h>
    2122#include <rtems/score/context.h>
     
    3839 *  This routine initializes all thread manager related data structures.
    3940 *
    40  *  Input parameters:
    41  *    ticks_per_timeslice - clock ticks per quantum
    42  *    maximum_proxies     - number of proxies to initialize
     41 *  Input parameters:   NONE
    4342 *
    4443 *  Output parameters:  NONE
    4544 */
    4645
    47 void _Thread_Handler_initialization(
    48   uint32_t     ticks_per_timeslice,
    49   uint32_t     maximum_extensions
    50 #if defined(RTEMS_MULTIPROCESSING)
    51   ,
    52   uint32_t     maximum_proxies
    53 #endif
    54 )
     46void _Thread_Handler_initialization(void)
    5547{
    56   uint32_t        index;
     48  uint32_t     index;
     49  uint32_t     ticks_per_timeslice;
     50  uint32_t     maximum_extensions;
     51  #if defined(RTEMS_MULTIPROCESSING)
     52    uint32_t   maximum_proxies;
     53  #endif
    5754
     55  ticks_per_timeslice = Configuration.ticks_per_timeslice;
     56  maximum_extensions  = Configuration.maximum_extensions;
     57  #if defined(RTEMS_MULTIPROCESSING)
     58    maximum_proxies   =  _Configuration_MP_table->maximum_proxies;
     59  #endif
    5860  /*
    5961   * BOTH stacks hooks must be set or both must be NULL.
  • cpukit/score/src/userext.c

    re06ecec5 r790b50b  
    11/*
    2  *  COPYRIGHT (c) 1989-2007.
     2 *  COPYRIGHT (c) 1989-2008.
    33 *  On-Line Applications Research Corporation (OAR).
    44 *
     
    1515
    1616#include <rtems/system.h>
     17#include <rtems/config.h>
    1718#include <rtems/score/userext.h>
    1819#include <rtems/score/wkspace.h>
     
    2324 */
    2425
    25 void _User_extensions_Handler_initialization (
    26   uint32_t                number_of_extensions,
    27   User_extensions_Table  *initial_extensions
    28 )
     26void _User_extensions_Handler_initialization(void)
    2927{
    3028  User_extensions_Control *extension;
    3129  uint32_t                 i;
     30  uint32_t                 number_of_extensions;
     31  User_extensions_Table   *initial_extensions;
     32
     33  number_of_extensions = Configuration.number_of_initial_extensions;
     34  initial_extensions   = Configuration.User_extension_table;
    3235
    3336  _Chain_Initialize_empty( &_User_extensions_List );
  • cpukit/score/src/wkspace.c

    re06ecec5 r790b50b  
    1717
    1818#include <rtems/system.h>
     19#include <rtems/config.h>
    1920#include <rtems/score/wkspace.h>
    2021#include <rtems/score/interr.h>
     
    2627 *  _Workspace_Handler_initialization
    2728 */
    28 void _Workspace_Handler_initialization(
    29   void       *starting_address,
    30   size_t      size
    31 )
     29void _Workspace_Handler_initialization(void)
    3230{
    3331  uint32_t    memory_available;
     32  void       *starting_address;
     33  size_t      size;
     34
     35  starting_address = Configuration.work_space_start;
     36  size             = Configuration.work_space_size;
    3437
    3538  if ( !starting_address || !_Addresses_Is_aligned( starting_address ) )
Note: See TracChangeset for help on using the changeset viewer.