2 * (c) Copyright 1990-1996 OPEN SOFTWARE FOUNDATION, INC.
3 * (c) Copyright 1990-1996 HEWLETT-PACKARD COMPANY
4 * (c) Copyright 1990-1996 DIGITAL EQUIPMENT CORPORATION
5 * (c) Copyright 1991, 1992 Siemens-Nixdorf Information Systems
6 * To anyone who acknowledges that this file is provided "AS IS" without
7 * any express or implied warranty: permission to use, copy, modify, and
8 * distribute this file for any purpose is hereby granted without fee,
9 * provided that the above copyright notices and this notice appears in
10 * all source code copies, and that none of the names listed above be used
11 * in advertising or publicity pertaining to distribution of the software
12 * without specific, written prior permission. None of these organizations
13 * makes any representations about the suitability of this software for
17 * Header file for handles
31 * CONSTANTS AND MACROS
34 #define cma__validate_attr(handle) \
35 ((cma__t_int_attr *)cma__validate_handle ( \
36 (cma_t_handle *)(handle), \
39 #define cma__validate_cv(handle) \
40 ((cma__t_int_cv *)cma__validate_handle ( \
41 (cma_t_handle *)(handle), \
44 #define cma__validate_mutex(handle) \
45 ((cma__t_int_mutex *)cma__validate_handle ( \
46 (cma_t_handle *)(handle), \
49 #define cma__validate_tcb(handle) \
50 ((cma__t_int_tcb *)cma__validate_handle ( \
51 (cma_t_handle *)(handle), \
54 #define cma__validate_stack(handle) \
55 ((cma__t_int_stack *)cma__validate_handle ( \
56 (cma_t_handle *)(handle), \
59 #define cma__validate_null_attr(handle) \
60 ((cma__t_int_attr *)cma__validate_handle_null ( \
61 (cma_t_handle *)(handle), \
64 #define cma__validate_null_cv(handle) \
65 ((cma__t_int_cv *)cma__validate_handle_null ( \
66 (cma_t_handle *)(handle), \
69 #define cma__validate_null_mutex(handle) \
70 ((cma__t_int_mutex *)cma__validate_handle_null ( \
71 (cma_t_handle *)(handle), \
74 #define cma__validate_null_tcb(handle) \
75 ((cma__t_int_tcb *)cma__validate_handle_null ( \
76 (cma_t_handle *)(handle), \
79 #define cma__validate_null_stack(handle) \
80 ((cma__t_int_stack *)cma__validate_handle_null ( \
81 (cma_t_handle *)(handle), \
84 #define cma__val_attr_stat(handle,obj) \
85 cma__val_hand_stat ( \
86 (cma_t_handle *)(handle), \
88 (cma__t_object **)obj)
90 #define cma__val_cv_stat(handle,obj) \
91 cma__val_hand_stat ( \
92 (cma_t_handle *)(handle), \
94 (cma__t_object **)obj)
96 #define cma__val_mutex_stat(handle,obj) \
97 cma__val_hand_stat ( \
98 (cma_t_handle *)(handle), \
100 (cma__t_object **)obj)
102 #define cma__val_tcb_stat(handle) \
103 cma__val_hand_stat ( \
104 (cma_t_handle *)(handle), \
106 (cma__t_object **)obj)
108 #define cma__val_stack_stat(handle,obj) \
109 cma__val_hand_stat ( \
110 (cma_t_handle *)(handle), \
112 (cma__t_object **)obj)
114 #define cma__val_nullattr_stat(handle,obj) \
115 cma__val_handnull_stat ( \
116 (cma_t_handle *)(handle), \
118 (cma__t_object **)obj)
120 #define cma__val_nullcv_stat(handle,obj) \
121 cma__val_handnull_stat ( \
122 (cma_t_handle *)(handle), \
124 (cma__t_object **)obj)
126 #define cma__val_nullmutex_stat(handle,obj) \
127 cma__val_handnull_stat ( \
128 (cma_t_handle *)(handle), \
130 (cma__t_object **)obj)
132 #define cma__val_nulltcb_stat(handle,obj) \
133 cma__val_handnull_stat ( \
134 (cma_t_handle *)(handle), \
136 (cma__t_object **)obj)
138 #define cma__val_nullstack_stat(handle) \
139 cma__val_handnull_stat ( \
140 (cma_t_handle *)(handle), \
142 (cma__t_object **)obj)
149 * Internal format of a handle (to the outside world it's an array of two
150 * addresses, but we know better).
152 typedef struct CMA__T_INT_HANDLE
{
153 cma__t_object
*pointer
; /* Address of internal structure */
154 cma__t_short sequence
; /* Sequence number of object */
155 cma__t_short type
; /* Type code of object */
163 * INTERNAL INTERFACES
166 extern void cma__clear_handle (cma_t_handle
*);
168 extern void cma__object_to_handle (cma__t_object
*, cma_t_handle
*);
170 extern cma__t_int_attr
* cma__validate_default_attr (cma_t_handle
*);
172 extern cma_t_status
cma__val_defattr_stat (cma_t_handle
*, cma__t_int_attr
**);
174 extern cma__t_object
* cma__validate_handle (cma_t_handle
*, cma_t_natural
);
176 extern cma_t_status
cma__val_hand_stat (cma_t_handle
*,
177 cma_t_natural
, cma__t_object
**);
179 extern cma__t_object
*cma__validate_handle_null (cma_t_handle
*,
182 extern cma_t_status
cma__val_handnull_stat (cma_t_handle
*,
183 cma_t_natural
, cma__t_object
**);
This page took 0.032476 seconds and 4 git commands to generate.