source: rtems/c/src/exec/rtems/headers/attr.h @ 7f6a24ab

4.104.114.84.95
Last change on this file since 7f6a24ab was 7f6a24ab, checked in by Joel Sherrill <joel.sherrill@…>, on 08/28/95 at 15:30:29

Added unused priority ceiling parameter to rtems_semaphore_create.

Rearranged code to created thread handler routines to initialize,
start, restart, and "close/delete" a thread.

Made internal threads their own object class. This now uses the
thread support routines for starting and initializing a thread.

Insured deleted tasks are freed to the Inactive pool associated with the
correct Information block.

Added an RTEMS API specific data area to the thread control block.

Beginnings of removing the word "rtems" from the core.

  • Property mode set to 100644
File size: 4.1 KB
Line 
1/*  attr.h
2 *
3 *  This include file contains all information about the Object Attributes
4 *  Handler.
5 *
6 *  COPYRIGHT (c) 1989, 1990, 1991, 1992, 1993, 1994.
7 *  On-Line Applications Research Corporation (OAR).
8 *  All rights assigned to U.S. Government, 1994.
9 *
10 *  This material may be reproduced by or for the U.S. Government pursuant
11 *  to the copyright license under the clause at DFARS 252.227-7013.  This
12 *  notice must appear in all copies of this file and its derivatives.
13 *
14 *  $Id$
15 */
16
17#ifndef __RTEMS_ATTRIBUTES_h
18#define __RTEMS_ATTRIBUTES_h
19
20#ifdef __cplusplus
21extern "C" {
22#endif
23
24/* types */
25
26typedef unsigned32 rtems_attribute;
27
28/* constants */
29
30#define RTEMS_DEFAULT_ATTRIBUTES  0x00000000
31
32#define RTEMS_NO_FLOATING_POINT   0x00000000 /* don't use FP HW */
33#define RTEMS_FLOATING_POINT      0x00000001 /* utilize coprocessor */
34
35#define RTEMS_LOCAL               0x00000000 /* local resource */
36#define RTEMS_GLOBAL              0x00000002 /* global resource */
37
38#define RTEMS_FIFO                0x00000000 /* process RTEMS_FIFO */
39#define RTEMS_PRIORITY            0x00000004 /* process by priority */
40
41#define RTEMS_COUNTING_SEMAPHORE  0x00000000
42#define RTEMS_BINARY_SEMAPHORE    0x00000010
43
44#define RTEMS_NO_INHERIT_PRIORITY 0x00000000
45#define RTEMS_INHERIT_PRIORITY    0x00000020
46
47#if ( CPU_HARDWARE_FP == TRUE )
48#define ATTRIBUTES_NOT_SUPPORTED       0
49#else
50#define ATTRIBUTES_NOT_SUPPORTED       RTEMS_FLOATING_POINT
51#endif
52
53#if ( CPU_ALL_TASKS_ARE_FP == TRUE )
54#define ATTRIBUTES_REQUIRED            RTEMS_FLOATING_POINT
55#else
56#define ATTRIBUTES_REQUIRED            0
57#endif
58
59/*
60 *  _Attributes_Handler_initialization
61 *
62 *  DESCRIPTION:
63 *
64 *  This routine performs initialization for this handler.
65 *
66 *  NOTE: There is no initialization required in C.  Conditional compilation
67 *        takes care of this in C.
68 */
69
70#define _Attributes_Handler_initialization()
71
72/*
73 *  _Attributes_Set
74 *
75 *  DESCRIPTION:
76 *
77 *  This function sets the requested new_attributes in the attribute_set
78 *  passed in.  The result is returned to the user.
79 */
80
81STATIC INLINE rtems_attribute _Attributes_Set (
82   rtems_attribute new_attributes,
83   rtems_attribute attribute_set
84);
85
86/*
87 *  _Attributes_Clear
88 *
89 *  DESCRIPTION:
90 *
91 *  This function clears the requested new_attributes in the attribute_set
92 *  passed in.  The result is returned to the user.
93 */
94
95STATIC INLINE rtems_attribute _Attributes_Clear (
96   rtems_attribute attribute_set,
97   rtems_attribute mask
98);
99
100/*
101 *  _Attributes_Is_floating_point
102 *
103 *  DESCRIPTION:
104 *
105 *  This function returns TRUE if the floating point attribute is
106 *  enabled in the attribute_set and FALSE otherwise.
107 */
108
109STATIC INLINE boolean _Attributes_Is_floating_point(
110  rtems_attribute attribute_set
111);
112
113/*
114 *  _Attributes_Is_global
115 *
116 *  DESCRIPTION:
117 *
118 *  This function returns TRUE if the global object attribute is
119 *  enabled in the attribute_set and FALSE otherwise.
120 */
121
122STATIC INLINE boolean _Attributes_Is_global(
123  rtems_attribute attribute_set
124);
125
126/*
127 *  _Attributes_Is_priority
128 *
129 *  DESCRIPTION:
130 *
131 *  This function returns TRUE if the priority attribute is
132 *  enabled in the attribute_set and FALSE otherwise.
133 */
134
135STATIC INLINE boolean _Attributes_Is_priority(
136  rtems_attribute attribute_set
137);
138
139#if 0
140/*
141 *  _Attributes_Is_limit
142 *
143 *  DESCRIPTION:
144 *
145 *  This function returns TRUE if the limited attribute is
146 *  enabled in the attribute_set and FALSE otherwise.
147 */
148
149STATIC INLINE boolean _Attributes_Is_limit(
150  rtems_attribute attribute_set
151);
152#endif
153
154/*
155 *  _Attributes_Is_binary_semaphore
156 *
157 *  DESCRIPTION:
158 *
159 *  This function returns TRUE if the binary semaphore attribute is
160 *  enabled in the attribute_set and FALSE otherwise.
161 */
162
163STATIC INLINE boolean _Attributes_Is_binary_semaphore(
164  rtems_attribute attribute_set
165);
166
167/*
168 *  _Attributes_Is_inherit_priority
169 *
170 *  DESCRIPTION:
171 *
172 *  This function returns TRUE if the priority inheritance attribute
173 *  is enabled in the attribute_set and FALSE otherwise.
174 */
175
176STATIC INLINE boolean _Attributes_Is_inherit_priority(
177  rtems_attribute attribute_set
178);
179
180#include <rtems/attr.inl>
181
182#ifdef __cplusplus
183}
184#endif
185
186#endif
187/* end of include file */
Note: See TracBrowser for help on using the repository browser.