1 | /* |
---|
2 | * ITRON API Initialization Support |
---|
3 | * |
---|
4 | * NOTE: |
---|
5 | * |
---|
6 | * COPYRIGHT (c) 1989-2008. |
---|
7 | * On-Line Applications Research Corporation (OAR). |
---|
8 | * |
---|
9 | * The license and distribution terms for this file may be |
---|
10 | * found in the file LICENSE in this distribution or at |
---|
11 | * http://www.rtems.com/license/LICENSE. |
---|
12 | * |
---|
13 | * $Id$ |
---|
14 | */ |
---|
15 | |
---|
16 | #if HAVE_CONFIG_H |
---|
17 | #include "config.h" |
---|
18 | #endif |
---|
19 | |
---|
20 | #include <assert.h> |
---|
21 | |
---|
22 | /* |
---|
23 | * ITRON_API_INIT is defined so all of the ITRON API |
---|
24 | * data will be included in this object file. |
---|
25 | */ |
---|
26 | |
---|
27 | #define ITRON_API_INIT |
---|
28 | |
---|
29 | #include <rtems/system.h> /* include this before checking RTEMS_ITRON_API */ |
---|
30 | #ifdef RTEMS_ITRON_API |
---|
31 | |
---|
32 | #include <rtems/itron.h> |
---|
33 | |
---|
34 | #include <sys/types.h> |
---|
35 | #include <rtems/config.h> |
---|
36 | #include <rtems/score/object.h> |
---|
37 | |
---|
38 | #include <rtems/itron/eventflags.h> |
---|
39 | #include <rtems/itron/fmempool.h> |
---|
40 | #include <rtems/itron/itronapi.h> |
---|
41 | #include <rtems/itron/mbox.h> |
---|
42 | #include <rtems/itron/msgbuffer.h> |
---|
43 | #include <rtems/itron/port.h> |
---|
44 | #include <rtems/itron/semaphore.h> |
---|
45 | #include <rtems/itron/task.h> |
---|
46 | #include <rtems/itron/vmempool.h> |
---|
47 | |
---|
48 | /*PAGE |
---|
49 | * |
---|
50 | * _ITRON_API_Initialize |
---|
51 | * |
---|
52 | * XXX |
---|
53 | */ |
---|
54 | |
---|
55 | Objects_Information *_ITRON_Objects[ OBJECTS_ITRON_CLASSES_LAST + 1 ]; |
---|
56 | |
---|
57 | void _ITRON_API_Initialize(void) |
---|
58 | { |
---|
59 | /* XXX need to assert here based on size assumptions */ |
---|
60 | |
---|
61 | assert( sizeof(ID) == sizeof(Objects_Id) ); |
---|
62 | |
---|
63 | /* |
---|
64 | * Install our API Object Management Table and initialize the |
---|
65 | * various managers. |
---|
66 | */ |
---|
67 | _Objects_Information_table[OBJECTS_ITRON_API] = _ITRON_Objects; |
---|
68 | |
---|
69 | _ITRON_Task_Manager_initialization(); |
---|
70 | _ITRON_Semaphore_Manager_initialization(); |
---|
71 | _ITRON_Eventflags_Manager_initialization(); |
---|
72 | _ITRON_Fixed_memory_pool_Manager_initialization(); |
---|
73 | _ITRON_Mailbox_Manager_initialization(); |
---|
74 | _ITRON_Message_buffer_Manager_initialization(); |
---|
75 | _ITRON_Port_Manager_initialization(); |
---|
76 | _ITRON_Variable_memory_pool_Manager_initialization(); |
---|
77 | } |
---|
78 | |
---|
79 | #endif |
---|
80 | /* end of file */ |
---|