1 | /** |
---|
2 | * @file rtems/rtems/attr.h |
---|
3 | * |
---|
4 | * @defgroup ClassicAttributes Attributes |
---|
5 | * |
---|
6 | * @ingroup ClassicRTEMS |
---|
7 | * @brief Object Attributes Handler |
---|
8 | * |
---|
9 | * This include file contains all information about the Object Attributes |
---|
10 | * Handler. |
---|
11 | */ |
---|
12 | |
---|
13 | /* COPYRIGHT (c) 1989-2008. |
---|
14 | * On-Line Applications Research Corporation (OAR). |
---|
15 | * |
---|
16 | * The license and distribution terms for this file may be |
---|
17 | * found in the file LICENSE in this distribution or at |
---|
18 | * http://www.rtems.org/license/LICENSE. |
---|
19 | */ |
---|
20 | |
---|
21 | #ifndef _RTEMS_RTEMS_ATTR_H |
---|
22 | #define _RTEMS_RTEMS_ATTR_H |
---|
23 | |
---|
24 | #include <rtems/score/basedefs.h> |
---|
25 | |
---|
26 | #ifdef __cplusplus |
---|
27 | extern "C" { |
---|
28 | #endif |
---|
29 | |
---|
30 | /** |
---|
31 | * @defgroup ClassicAttributes Attributes |
---|
32 | * |
---|
33 | * @ingroup ClassicRTEMS |
---|
34 | * |
---|
35 | * This encapsulates functionality which defines and manages the |
---|
36 | * set of Classic API object attributes. |
---|
37 | */ |
---|
38 | /**@{*/ |
---|
39 | |
---|
40 | /** |
---|
41 | * This defines the type used to contain Classic API attributes. These |
---|
42 | * are primarily used when creating objects. |
---|
43 | */ |
---|
44 | typedef uint32_t rtems_attribute; |
---|
45 | |
---|
46 | /** This is the default value for an attribute set. */ |
---|
47 | |
---|
48 | #define RTEMS_DEFAULT_ATTRIBUTES 0x00000000 |
---|
49 | |
---|
50 | /** |
---|
51 | * This is the attribute constant to indicate local resource. |
---|
52 | */ |
---|
53 | #define RTEMS_LOCAL 0x00000000 |
---|
54 | |
---|
55 | /** |
---|
56 | * This is the attribute constant to indicate global resource. |
---|
57 | */ |
---|
58 | #define RTEMS_GLOBAL 0x00000002 |
---|
59 | |
---|
60 | /** |
---|
61 | * This is the attribute constant which reflects that blocking |
---|
62 | * tasks will be managed using FIFO discipline. |
---|
63 | */ |
---|
64 | #define RTEMS_FIFO 0x00000000 |
---|
65 | |
---|
66 | /** |
---|
67 | * This is the attribute constant which reflects that blocking |
---|
68 | * tasks will be managed using task priority discipline. |
---|
69 | */ |
---|
70 | #define RTEMS_PRIORITY 0x00000004 |
---|
71 | |
---|
72 | /******************** RTEMS Task Specific Attributes *********************/ |
---|
73 | |
---|
74 | /** |
---|
75 | * This attribute constant indicates that the task will not use the |
---|
76 | * floating point hardware. If the architecture permits it, then |
---|
77 | * the FPU will be disabled when the task is executing. |
---|
78 | */ |
---|
79 | #define RTEMS_NO_FLOATING_POINT 0x00000000 |
---|
80 | |
---|
81 | /** |
---|
82 | * This attribute constant indicates that the task will use the |
---|
83 | * floating point hardware. There will be a floating point |
---|
84 | * context associated with this task. |
---|
85 | */ |
---|
86 | #define RTEMS_FLOATING_POINT 0x00000001 |
---|
87 | |
---|
88 | /***************** RTEMS Semaphore Specific Attributes ********************/ |
---|
89 | |
---|
90 | /** |
---|
91 | * This is the mask for the attribute bits associated with the |
---|
92 | * Classic API Semaphore Manager. |
---|
93 | */ |
---|
94 | #define RTEMS_SEMAPHORE_CLASS 0x00000030 |
---|
95 | |
---|
96 | /** |
---|
97 | * This attribute constant indicates that the Classic API Semaphore |
---|
98 | * instance created will be a counting semaphore. |
---|
99 | */ |
---|
100 | #define RTEMS_COUNTING_SEMAPHORE 0x00000000 |
---|
101 | |
---|
102 | /** |
---|
103 | * This attribute constant indicates that the Classic API Semaphore |
---|
104 | * instance created will be a proper binary semaphore or mutex. |
---|
105 | */ |
---|
106 | #define RTEMS_BINARY_SEMAPHORE 0x00000010 |
---|
107 | |
---|
108 | /** |
---|
109 | * This attribute constant indicates that the Classic API Semaphore |
---|
110 | * instance created will be a simple binary semaphore. |
---|
111 | */ |
---|
112 | #define RTEMS_SIMPLE_BINARY_SEMAPHORE 0x00000020 |
---|
113 | |
---|
114 | /** |
---|
115 | * This attribute constant indicates that the Classic API Semaphore |
---|
116 | * instance created will NOT use the Priority Inheritance Protocol. |
---|
117 | */ |
---|
118 | #define RTEMS_NO_INHERIT_PRIORITY 0x00000000 |
---|
119 | |
---|
120 | /** |
---|
121 | * This attribute constant indicates that the Classic API Semaphore |
---|
122 | * instance created will use the Priority Inheritance Protocol. |
---|
123 | * |
---|
124 | * @note The semaphore instance must be a binary semaphore. |
---|
125 | */ |
---|
126 | #define RTEMS_INHERIT_PRIORITY 0x00000040 |
---|
127 | |
---|
128 | /** |
---|
129 | * This attribute constant indicates that the Classic API Semaphore |
---|
130 | * instance created will NOT use the Priority Ceiling Protocol. |
---|
131 | */ |
---|
132 | #define RTEMS_NO_PRIORITY_CEILING 0x00000000 |
---|
133 | |
---|
134 | /** |
---|
135 | * This attribute constant indicates that the Classic API Semaphore |
---|
136 | * instance created will use the Priority Ceiling Protocol. |
---|
137 | * |
---|
138 | * @note The semaphore instance must be a binary semaphore. |
---|
139 | */ |
---|
140 | #define RTEMS_PRIORITY_CEILING 0x00000080 |
---|
141 | |
---|
142 | /** |
---|
143 | * This attribute constant indicates that the Classic API Semaphore instance |
---|
144 | * created will NOT use the Multiprocessor Resource Sharing Protocol. |
---|
145 | */ |
---|
146 | #define RTEMS_NO_MULTIPROCESSOR_RESOURCE_SHARING 0x00000000 |
---|
147 | |
---|
148 | /** |
---|
149 | * This attribute constant indicates that the Classic API Semaphore instance |
---|
150 | * created will use the Multiprocessor Resource Sharing Protocol. |
---|
151 | * |
---|
152 | * @note The semaphore instance must be a binary semaphore. |
---|
153 | */ |
---|
154 | #define RTEMS_MULTIPROCESSOR_RESOURCE_SHARING 0x00000100 |
---|
155 | |
---|
156 | /******************** RTEMS Barrier Specific Attributes ********************/ |
---|
157 | |
---|
158 | /** |
---|
159 | * This attribute constant indicates that the Classic API Barrier |
---|
160 | * instance created will use an automatic release protocol. |
---|
161 | */ |
---|
162 | #define RTEMS_BARRIER_AUTOMATIC_RELEASE 0x00000010 |
---|
163 | |
---|
164 | /** |
---|
165 | * This attribute constant indicates that the Classic API Barrier |
---|
166 | * instance created will use the manual release protocol. |
---|
167 | */ |
---|
168 | #define RTEMS_BARRIER_MANUAL_RELEASE 0x00000000 |
---|
169 | |
---|
170 | /**************** RTEMS Internal Task Specific Attributes ****************/ |
---|
171 | |
---|
172 | /** |
---|
173 | * This attribute constant indicates that the task was created |
---|
174 | * by the application using normal Classic API methods. |
---|
175 | */ |
---|
176 | #define RTEMS_APPLICATION_TASK 0x00000000 |
---|
177 | |
---|
178 | /** |
---|
179 | * This attribute constant indicates that the task was created |
---|
180 | * by RTEMS as a support task. |
---|
181 | */ |
---|
182 | #define RTEMS_SYSTEM_TASK 0x00008000 |
---|
183 | |
---|
184 | /**@}*/ |
---|
185 | |
---|
186 | #ifdef __cplusplus |
---|
187 | } |
---|
188 | #endif |
---|
189 | |
---|
190 | #endif |
---|
191 | /* end of include file */ |
---|