Changeset 6bf44a5 in rtems for cpukit/sapi


Ignore:
Timestamp:
Jan 26, 2016, 8:28:11 AM (3 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
8ca372e
Parents:
ca4602e
git-author:
Sebastian Huber <sebastian.huber@…> (01/26/16 08:28:11)
git-committer:
Sebastian Huber <sebastian.huber@…> (02/03/16 09:00:57)
Message:

Use linker set for driver manager initialization

Update #2408.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/sapi/src/exinit.c

    rca4602e r6bf44a5  
    5252#include <rtems/sptables.h>
    5353
    54 #ifdef RTEMS_DRVMGR_STARTUP
    55   #include <drvmgr/drvmgr.h>
    56 #endif
    57 
    5854static Objects_Information *
    5955_Internal_Objects[ OBJECTS_INTERNAL_CLASSES_LAST + 1 ];
     
    130126static void rtems_initialize_before_drivers(void)
    131127{
    132   #ifdef RTEMS_DRVMGR_STARTUP
    133   _DRV_Manager_initialization();
    134   #endif
    135 
    136128  #if defined(RTEMS_MULTIPROCESSING)
    137129    _MPCI_Create_server();
     
    146138   *  NOTE:  The MPCI may be build upon a device driver.
    147139   */
    148 
    149   #ifdef RTEMS_DRVMGR_STARTUP
    150   /* BSPs has already registered their "root bus" driver in the
    151    * bsp_predriver hook or so.
    152    *
    153    * Init Drivers to Level 1, constraints:
    154    *   - Interrupts and system clock timer does not work.
    155    *   - malloc() work, however other memory services may not
    156    *     have been initialized yet.
    157    *   - initializes most basic stuff
    158    *
    159    * Typical setup in Level 1:
    160    *   - Find most devices in system, do PCI scan and configuration.
    161    *   - Reset hardware if needed.
    162    *   - Install IRQ driver
    163    *   - Install Timer driver
    164    *   - Install console driver and debug printk()
    165    *   - Install extra memory.
    166    */
    167   _DRV_Manager_init_level(1);
    168   bsp_driver_level_hook(1);
    169   #endif
    170140
    171141  /* Initialize I/O drivers.
     
    176146   */
    177147  _IO_Initialize_all_drivers();
    178 
    179   #ifdef RTEMS_DRVMGR_STARTUP
    180   /* Init Drivers to Level 2, constraints:
    181    *  - Interrupts can be registered and enabled.
    182    *  - System Clock is running
    183    *  - Console may be used.
    184    *
    185    * This is typically where drivers are initialized
    186    * for the first time.
    187    */
    188   _DRV_Manager_init_level(2);
    189   bsp_driver_level_hook(2);
    190 
    191   /* Init Drivers to Level 3
    192    *
    193    * This is typically where normal drivers are initialized
    194    * for the second time, they may depend on other drivers
    195    * API inited in level 2
    196    */
    197   _DRV_Manager_init_level(3);
    198   bsp_driver_level_hook(3);
    199 
    200   /* Init Drivers to Level 4,
    201    * Init drivers that depend on services initialized in Level 3
    202    */
    203   _DRV_Manager_init_level(4);
    204   bsp_driver_level_hook(4);
    205   #endif
    206148
    207149  #if defined(RTEMS_MULTIPROCESSING)
Note: See TracChangeset for help on using the changeset viewer.