RTEMS: cpukit/include/rtems/rtems/msgmp.h Source File

| RTEMS 5.4-rc2

Loading...
Searching...
No Matches
msgmp.h
Go to the documentation of this file.
1
10/* COPYRIGHT (c) 1989-2013.
11 * On-Line Applications Research Corporation (OAR).
12 *
13 * The license and distribution terms for this file may be
14 * found in the file LICENSE in this distribution or at
15 * http://www.rtems.org/license/LICENSE.
16 */
17
18#ifndef _RTEMS_RTEMS_MSGMP_H
19#define _RTEMS_RTEMS_MSGMP_H
20
21#ifndef _RTEMS_RTEMS_MESSAGEIMPL_H
22# error "Never use <rtems/rtems/msgmp.h> directly; include <rtems/rtems/messageimpl.h> instead."
23#endif
24
25#include <rtems/score/mpciimpl.h>
26
27#ifdef __cplusplus
28extern "C" {
29#endif
30
39/*{*/
40
45 typedef enum {
46 MESSAGE_QUEUE_MP_ANNOUNCE_CREATE = 0,
47 MESSAGE_QUEUE_MP_ANNOUNCE_DELETE = 1,
48 MESSAGE_QUEUE_MP_EXTRACT_PROXY = 2,
49 MESSAGE_QUEUE_MP_RECEIVE_REQUEST = 3,
50 MESSAGE_QUEUE_MP_RECEIVE_RESPONSE = 4,
51 MESSAGE_QUEUE_MP_SEND_REQUEST = 5,
52 MESSAGE_QUEUE_MP_SEND_RESPONSE = 6,
53 MESSAGE_QUEUE_MP_URGENT_REQUEST = 7,
54 MESSAGE_QUEUE_MP_URGENT_RESPONSE = 8,
55 MESSAGE_QUEUE_MP_BROADCAST_REQUEST = 9,
56 MESSAGE_QUEUE_MP_BROADCAST_RESPONSE = 10,
57 MESSAGE_QUEUE_MP_FLUSH_REQUEST = 11,
58 MESSAGE_QUEUE_MP_FLUSH_RESPONSE = 12,
59 MESSAGE_QUEUE_MP_GET_NUMBER_PENDING_REQUEST = 13,
60 MESSAGE_QUEUE_MP_GET_NUMBER_PENDING_RESPONSE = 14
61} Message_queue_MP_Remote_operations;
62
67 typedef struct {
68 rtems_packet_prefix Prefix;
69 Message_queue_MP_Remote_operations operation;
70 rtems_name name;
71 rtems_option option_set;
72 Objects_Id proxy_id;
73 uint32_t count;
74 size_t size;
75 uint32_t pad0;
76 CORE_message_queue_Buffer Buffer;
77} Message_queue_MP_Packet;
78
79#define MESSAGE_QUEUE_MP_PACKET_SIZE \
80 offsetof(Message_queue_MP_Packet, Buffer.buffer)
81
82 RTEMS_INLINE_ROUTINE bool _Message_queue_MP_Is_remote( Objects_Id id )
83{
84 return _Objects_MP_Is_remote( id, &_Message_queue_Information );
85}
86
96void _Message_queue_Core_message_queue_mp_support (
97 Thread_Control *the_thread,
98 rtems_id id
99);
100
107void _Message_queue_MP_Send_process_packet (
108 Message_queue_MP_Remote_operations operation,
109 Objects_Id message_queue_id,
110 rtems_name name,
111 Objects_Id proxy_id
112);
113
117 rtems_status_code _Message_queue_MP_Broadcast(
118 rtems_id id,
119 const void *buffer,
120 size_t size,
121 uint32_t *count
122);
123
127 rtems_status_code _Message_queue_MP_Flush(
128 rtems_id id,
129 uint32_t *count
130);
131
135 rtems_status_code _Message_queue_MP_Get_number_pending(
136 rtems_id id,
137 uint32_t *count
138);
139
143 rtems_status_code _Message_queue_MP_Receive(
144 rtems_id id,
145 void *buffer,
146 size_t *size,
147 rtems_option option_set,
148 rtems_interval timeout
149);
150
154 rtems_status_code _Message_queue_MP_Send(
155 rtems_id id,
156 const void *buffer,
157 size_t size
158);
159
163 rtems_status_code _Message_queue_MP_Urgent(
164 rtems_id id,
165 const void *buffer,
166 size_t size
167);
168
176void _Message_queue_MP_Send_object_was_deleted (
177 Thread_Control *the_proxy,
178 Objects_Id mp_id
179);
180
183#ifdef __cplusplus
184}
185#endif
186
187#endif
188/* end of file */
_Message_queue_Information
Objects_Information _Message_queue_Information
The Classic Message Queue objects information.
rtems_option
uint32_t rtems_option
Definition: options.h:42
rtems_status_code
rtems_status_code
Classic API Status.
Definition: status.h:43
rtems_name
uint32_t rtems_name
Classic API object name type.
Definition: types.h:77
rtems_id
Objects_Id rtems_id
Used to manage and manipulate RTEMS object identifiers.
Definition: types.h:83
rtems_interval
Watchdog_Interval rtems_interval
Used to manage and manipulate intervals specified by clock ticks.
Definition: types.h:127
RTEMS_INLINE_ROUTINE
#define RTEMS_INLINE_ROUTINE
Definition: basedefs.h:66
_Objects_MP_Is_remote
bool _Objects_MP_Is_remote(Objects_Id id, const Objects_Information *information)
Checks if the object identifier is in the global object identifier cache of the specified object info...
Definition: objectmp.c:338
Objects_Id
uint32_t Objects_Id
Definition: object.h:80
mpciimpl.h
MPCI Layer Implementation.
_Message_queue_MP_Send_object_was_deleted
void _Message_queue_MP_Send_object_was_deleted(Thread_Control *the_proxy, Objects_Id mp_id)
_Message_queue_MP_Send_object_was_deleted
Definition: msgmp.c:543
_Message_queue_Core_message_queue_mp_support
void _Message_queue_Core_message_queue_mp_support(Thread_Control *the_thread, rtems_id id)
Message_queue_Core_message_queue_mp_support.
Definition: msgmp.c:575
_Message_queue_MP_Receive
rtems_status_code _Message_queue_MP_Receive(rtems_id id, void *buffer, size_t *size, rtems_option option_set, rtems_interval timeout)
Issues a remote rtems_message_queue_receive() request.
Definition: msgmp.c:259
_Message_queue_MP_Send
rtems_status_code _Message_queue_MP_Send(rtems_id id, const void *buffer, size_t size)
Issues a remote rtems_message_queue_send() request.
Definition: msgmp.c:277
_Message_queue_MP_Send_process_packet
void _Message_queue_MP_Send_process_packet(Message_queue_MP_Remote_operations operation, Objects_Id message_queue_id, rtems_name name, Objects_Id proxy_id)
_Message_queue_MP_Send_process_packet
Definition: msgmp.c:46
_Message_queue_MP_Broadcast
rtems_status_code _Message_queue_MP_Broadcast(rtems_id id, const void *buffer, size_t size, uint32_t *count)
Issues a remote rtems_message_queue_broadcast() request.
Definition: msgmp.c:209
_Message_queue_MP_Flush
rtems_status_code _Message_queue_MP_Flush(rtems_id id, uint32_t *count)
Issues a remote rtems_message_queue_flush() request.
Definition: msgmp.c:227
_Message_queue_MP_Urgent
rtems_status_code _Message_queue_MP_Urgent(rtems_id id, const void *buffer, size_t size)
Issues a remote rtems_message_queue_urgent() request.
Definition: msgmp.c:293
Message_queue_MP_Remote_operations
Message_queue_MP_Remote_operations
Definition: msgmp.h:45
_Message_queue_MP_Get_number_pending
rtems_status_code _Message_queue_MP_Get_number_pending(rtems_id id, uint32_t *count)
Issues a remote rtems_message_queue_get_number_pending() request.
Definition: msgmp.c:243
CORE_message_queue_Buffer
Data types needed to manipulate the contents of message buffers.
Definition: coremsg.h:79
Message_queue_MP_Packet
Definition: msgmp.h:67
_Thread_Control
Definition: thread.h:732