[4c98a3e] | 1 | /** |
---|
| 2 | * @file |
---|
[962c9b65] | 3 | * |
---|
[4c98a3e] | 4 | * @brief Initialize POSIX API |
---|
[962c9b65] | 5 | * |
---|
[4c98a3e] | 6 | * @ingroup ClassicRTEMS |
---|
| 7 | */ |
---|
| 8 | |
---|
| 9 | /* |
---|
[71c012af] | 10 | * COPYRIGHT (c) 1989-2010. |
---|
[962c9b65] | 11 | * On-Line Applications Research Corporation (OAR). |
---|
| 12 | * |
---|
[98e4ebf5] | 13 | * The license and distribution terms for this file may be |
---|
| 14 | * found in the file LICENSE in this distribution or at |
---|
[2ba508b] | 15 | * http://www.rtems.com/license/LICENSE. |
---|
[962c9b65] | 16 | */ |
---|
| 17 | |
---|
[16351f7a] | 18 | #if HAVE_CONFIG_H |
---|
| 19 | #include "config.h" |
---|
| 20 | #endif |
---|
| 21 | |
---|
[c627b2a3] | 22 | #define POSIX_API_INIT |
---|
[962c9b65] | 23 | |
---|
[f7e46cf0] | 24 | #include <rtems/system.h> /* include this before checking RTEMS_POSIX_API */ |
---|
| 25 | #ifdef RTEMS_POSIX_API |
---|
[c627b2a3] | 26 | |
---|
| 27 | #include <sys/types.h> |
---|
[3f421dab] | 28 | #include <mqueue.h> |
---|
[c627b2a3] | 29 | #include <rtems/config.h> |
---|
[f39b01e] | 30 | #include <rtems/score/object.h> |
---|
[6b4a3770] | 31 | #include <rtems/posix/barrierimpl.h> |
---|
[962c9b65] | 32 | #include <rtems/posix/cond.h> |
---|
| 33 | #include <rtems/posix/config.h> |
---|
| 34 | #include <rtems/posix/key.h> |
---|
[972a5c5f] | 35 | #include <rtems/posix/mqueueimpl.h> |
---|
[f9d533a5] | 36 | #include <rtems/posix/muteximpl.h> |
---|
[aac75d3b] | 37 | #include <rtems/posix/posixapi.h> |
---|
[962c9b65] | 38 | #include <rtems/posix/priority.h> |
---|
[5f745464] | 39 | #include <rtems/posix/psignalimpl.h> |
---|
[962c9b65] | 40 | #include <rtems/posix/pthread.h> |
---|
[047d67a] | 41 | #include <rtems/posix/rwlock.h> |
---|
[0243b0d] | 42 | #include <rtems/posix/timer.h> |
---|
[9c743e8e] | 43 | #include <rtems/posix/semaphoreimpl.h> |
---|
[047d67a] | 44 | #include <rtems/posix/spinlock.h> |
---|
[962c9b65] | 45 | #include <rtems/posix/time.h> |
---|
| 46 | |
---|
[0577ec1d] | 47 | Objects_Information *_POSIX_Objects[ OBJECTS_POSIX_CLASSES_LAST + 1 ]; |
---|
| 48 | |
---|
[aac75d3b] | 49 | void _POSIX_API_Initialize(void) |
---|
[962c9b65] | 50 | { |
---|
[3507c6df] | 51 | /* |
---|
| 52 | * If there are any type size assumptions in the POSIX API, this is |
---|
| 53 | * the appropriate place to place them. |
---|
| 54 | * |
---|
| 55 | * Currently, there are no none type size assumptions. |
---|
| 56 | */ |
---|
[f39b01e] | 57 | |
---|
[aac75d3b] | 58 | /* |
---|
| 59 | * Install our API Object Management Table and initialize the |
---|
| 60 | * various managers. |
---|
| 61 | */ |
---|
[0577ec1d] | 62 | _Objects_Information_table[OBJECTS_POSIX_API] = _POSIX_Objects; |
---|
| 63 | |
---|
[309e2f6] | 64 | _POSIX_signals_Manager_Initialization(); |
---|
| 65 | _POSIX_Threads_Manager_initialization(); |
---|
| 66 | _POSIX_Condition_variables_Manager_initialization(); |
---|
| 67 | _POSIX_Key_Manager_initialization(); |
---|
| 68 | _POSIX_Mutex_Manager_initialization(); |
---|
| 69 | _POSIX_Message_queue_Manager_initialization(); |
---|
| 70 | _POSIX_Semaphore_Manager_initialization(); |
---|
| 71 | _POSIX_Timer_Manager_initialization(); |
---|
| 72 | _POSIX_Barrier_Manager_initialization(); |
---|
| 73 | _POSIX_RWLock_Manager_initialization(); |
---|
| 74 | _POSIX_Spinlock_Manager_initialization(); |
---|
[962c9b65] | 75 | } |
---|
| 76 | |
---|
[c627b2a3] | 77 | #endif |
---|