1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @brief Message Queue Manager Initialization |
---|
5 | * @ingroup ClassicMessageQueue |
---|
6 | */ |
---|
7 | |
---|
8 | /* |
---|
9 | * COPYRIGHT (c) 1989-2008. |
---|
10 | * On-Line Applications Research Corporation (OAR). |
---|
11 | * |
---|
12 | * The license and distribution terms for this file may be |
---|
13 | * found in the file LICENSE in this distribution or at |
---|
14 | * http://www.rtems.org/license/LICENSE. |
---|
15 | */ |
---|
16 | |
---|
17 | #if HAVE_CONFIG_H |
---|
18 | #include "config.h" |
---|
19 | #endif |
---|
20 | |
---|
21 | #include <rtems/system.h> |
---|
22 | #include <rtems/config.h> |
---|
23 | #include <rtems/score/chain.h> |
---|
24 | #include <rtems/score/isr.h> |
---|
25 | #include <rtems/score/coremsgimpl.h> |
---|
26 | #include <rtems/score/thread.h> |
---|
27 | #include <rtems/score/wkspace.h> |
---|
28 | #include <rtems/rtems/status.h> |
---|
29 | #include <rtems/rtems/attrimpl.h> |
---|
30 | #include <rtems/rtems/messageimpl.h> |
---|
31 | #include <rtems/rtems/options.h> |
---|
32 | #include <rtems/rtems/support.h> |
---|
33 | |
---|
34 | void _Message_queue_Manager_initialization(void) |
---|
35 | { |
---|
36 | _Objects_Initialize_information( |
---|
37 | &_Message_queue_Information, /* object information table */ |
---|
38 | OBJECTS_CLASSIC_API, /* object API */ |
---|
39 | OBJECTS_RTEMS_MESSAGE_QUEUES, /* object class */ |
---|
40 | Configuration_RTEMS_API.maximum_message_queues, |
---|
41 | /* maximum objects of this class */ |
---|
42 | sizeof( Message_queue_Control ), |
---|
43 | /* size of this object's control block */ |
---|
44 | false, /* true if names of this object are strings */ |
---|
45 | RTEMS_MAXIMUM_NAME_LENGTH /* maximum length of each object's name */ |
---|
46 | #if defined(RTEMS_MULTIPROCESSING) |
---|
47 | , |
---|
48 | true, /* true if this is a global object class */ |
---|
49 | _Message_queue_MP_Send_extract_proxy |
---|
50 | /* Proxy extraction support callout */ |
---|
51 | #endif |
---|
52 | ); |
---|
53 | |
---|
54 | /* |
---|
55 | * Register the MP Process Packet routine. |
---|
56 | */ |
---|
57 | |
---|
58 | #if defined(RTEMS_MULTIPROCESSING) |
---|
59 | _MPCI_Register_packet_processor( |
---|
60 | MP_PACKET_MESSAGE_QUEUE, |
---|
61 | _Message_queue_MP_Process_packet |
---|
62 | ); |
---|
63 | #endif |
---|
64 | |
---|
65 | } |
---|