source: rtems/cpukit/include/rtems/score/mppkt.h @ 3da777e

5
Last change on this file since 3da777e was 3da777e, checked in by Andreas Dachsberger <andreas.dachsberger@…>, on 04/10/19 at 06:06:14

doxygen: score: adjust doc in mppkt.h to doxygen guidelines

Update #3706.

  • Property mode set to 100644
File size: 3.7 KB
Line 
1/**
2 * @file
3 *
4 * @ingroup RTEMSScoreMPPacket
5 *
6 * @brief Specification for the Packet Handler
7 *
8 * This package is the specification for the Packet Handler.
9 * This handler defines the basic packet and provides
10 * mechanisms to utilize packets based on this prefix.
11 * Packets are the fundamental basis for messages passed between
12 * nodes in an MP system.
13 */
14
15/*
16 *  COPYRIGHT (c) 1989-2011.
17 *  On-Line Applications Research Corporation (OAR).
18 *
19 *  The license and distribution terms for this file may be
20 *  found in the file LICENSE in this distribution or at
21 *  http://www.rtems.org/license/LICENSE.
22 */
23
24#ifndef _RTEMS_SCORE_MPPKT_H
25#define _RTEMS_SCORE_MPPKT_H
26
27#include <rtems/score/object.h>
28#include <rtems/score/priority.h>
29#include <rtems/score/watchdogticks.h>
30
31#ifdef __cplusplus
32extern "C" {
33#endif
34
35/**
36 * @defgroup RTEMSScoreMPPacket MP Packet Handler
37 *
38 * @ingroup RTEMSScore
39 *
40 * @brief MP Packte Handler
41 *
42 * This handler encapsulates the primary definition of MPCI packets.  This
43 * handler defines the part of the packet that is common to all remote
44 * operations.
45 *
46 * @{
47 */
48
49/**
50 *  The following enumerated type defines the packet classes.
51 *
52 *  @note  In general, each class corresponds to a manager
53 *         which supports global operations.  Each manager
54 *         defines the set of supported operations.
55 */
56typedef enum {
57  MP_PACKET_MPCI_INTERNAL    = 0,
58  MP_PACKET_TASKS            = 1,
59  MP_PACKET_MESSAGE_QUEUE    = 2,
60  MP_PACKET_SEMAPHORE        = 3,
61  MP_PACKET_PARTITION        = 4,
62  MP_PACKET_REGION           = 5,
63  MP_PACKET_EVENT            = 6,
64  MP_PACKET_SIGNAL           = 7
65}   MP_packet_Classes;
66
67/**
68 *  This constant defines the first entry in the MP_packet_Classes enumeration.
69 */
70#define MP_PACKET_CLASSES_FIRST  MP_PACKET_MPCI_INTERNAL
71
72/**
73 *  This constant defines the last entry in the MP_packet_Classes enumeration.
74 */
75#define MP_PACKET_CLASSES_LAST   MP_PACKET_SIGNAL
76
77/**
78 *  The following record contains the prefix for every packet
79 *  passed between nodes in an MP system.
80 *
81 *  @note This structure is padded to ensure that anything following it
82 *        is on a 16 byte boundary.  This is the most stringent structure
83 *        alignment rule encountered yet.
84 */
85typedef struct {
86  /** This field indicates the API class of the operation being performed. */
87  MP_packet_Classes       the_class;
88  /** This field is the id of the object to be acted upon. */
89  Objects_Id              id;
90  /** This field is the ID of the originating thread. */
91  Objects_Id              source_tid;
92  /** This field is the priority of the originating thread. */
93  uint32_t                source_priority;
94  /** This field is where the status of the operation will be returned. */
95  uint32_t                return_code;
96  /** This field is the length of the data following the prefix. */
97  uint32_t                length;
98  /** This field is the length of the data which required network conversion. */
99  uint32_t                to_convert;
100  /** This field is the requested timeout for this operation. */
101  Watchdog_Interval       timeout;
102}   MP_packet_Prefix;
103
104/**
105 *  An MPCI must support packets of at least this size.
106 */
107#define MP_PACKET_MINIMUM_PACKET_SIZE  64
108
109/**
110 *  The following constant defines the number of uint32_t's
111 *  in a packet which must be converted to native format in a
112 *  heterogeneous system.  In packets longer than
113 *  MP_PACKET_MINIMUN_HETERO_CONVERSION uint32_t's, some of the "extra" data
114 *  may a user message buffer which is not automatically endian swapped.
115 */
116#define MP_PACKET_MINIMUN_HETERO_CONVERSION  \
117  ( sizeof( MP_packet_Prefix ) / sizeof( uint32_t   ) )
118
119/** @} */
120
121#ifdef __cplusplus
122}
123#endif
124
125#endif
126/* end of include file */
Note: See TracBrowser for help on using the repository browser.