Chameleon

Chameleon Svn Source Tree

Root/tags/2.0/i386/include/mach/lock_set.h

Source at commit 1808 created 12 years 4 months ago.
By blackosx, Revise layout of package installer 'Welcome' file so it looks cleaner. Change the copyright notice to begin from 2009 as seen in the Chameleon 2.0 r431 installer. Should this date be set earlier?
1#ifndef_lock_set_user_
2#define_lock_set_user_
3
4/* Module lock_set */
5
6#include <string.h>
7#include <mach/ndr.h>
8#include <mach/boolean.h>
9#include <mach/kern_return.h>
10#include <mach/notify.h>
11#include <mach/mach_types.h>
12#include <mach/message.h>
13#include <mach/mig_errors.h>
14#include <mach/port.h>
15
16#ifdef AUTOTEST
17#ifndef FUNCTION_PTR_T
18#define FUNCTION_PTR_T
19typedef void (*function_ptr_t)(mach_port_t, char *, mach_msg_type_number_t);
20typedef struct {
21 char *name;
22 function_ptr_t function;
23} function_table_entry;
24typedef function_table_entry *function_table_t;
25#endif /* FUNCTION_PTR_T */
26#endif /* AUTOTEST */
27
28#ifndeflock_set_MSG_COUNT
29#definelock_set_MSG_COUNT6
30#endif/* lock_set_MSG_COUNT */
31
32#include <mach/std_types.h>
33#include <mach/mig.h>
34#include <mach/mach_types.h>
35
36#ifdef __BeforeMigUserHeader
37__BeforeMigUserHeader
38#endif /* __BeforeMigUserHeader */
39
40#include <sys/cdefs.h>
41__BEGIN_DECLS
42
43
44/* Routine lock_acquire */
45#ifdefmig_external
46mig_external
47#else
48extern
49#endif/* mig_external */
50kern_return_t lock_acquire
51(
52lock_set_t lock_set,
53int lock_id
54);
55
56/* Routine lock_release */
57#ifdefmig_external
58mig_external
59#else
60extern
61#endif/* mig_external */
62kern_return_t lock_release
63(
64lock_set_t lock_set,
65int lock_id
66);
67
68/* Routine lock_try */
69#ifdefmig_external
70mig_external
71#else
72extern
73#endif/* mig_external */
74kern_return_t lock_try
75(
76lock_set_t lock_set,
77int lock_id
78);
79
80/* Routine lock_make_stable */
81#ifdefmig_external
82mig_external
83#else
84extern
85#endif/* mig_external */
86kern_return_t lock_make_stable
87(
88lock_set_t lock_set,
89int lock_id
90);
91
92/* Routine lock_handoff */
93#ifdefmig_external
94mig_external
95#else
96extern
97#endif/* mig_external */
98kern_return_t lock_handoff
99(
100lock_set_t lock_set,
101int lock_id
102);
103
104/* Routine lock_handoff_accept */
105#ifdefmig_external
106mig_external
107#else
108extern
109#endif/* mig_external */
110kern_return_t lock_handoff_accept
111(
112lock_set_t lock_set,
113int lock_id
114);
115
116__END_DECLS
117
118/********************** Caution **************************/
119/* The following data types should be used to calculate */
120/* maximum message sizes only. The actual message may be */
121/* smaller, and the position of the arguments within the */
122/* message layout may vary from what is presented here. */
123/* For example, if any of the arguments are variable- */
124/* sized, and less than the maximum is sent, the data */
125/* will be packed tight in the actual message to reduce */
126/* the presence of holes. */
127/********************** Caution **************************/
128
129/* typedefs for all requests */
130
131#ifndef __Request__lock_set_subsystem__defined
132#define __Request__lock_set_subsystem__defined
133
134#ifdef __MigPackStructs
135#pragma pack(4)
136#endif
137typedef struct {
138mach_msg_header_t Head;
139NDR_record_t NDR;
140int lock_id;
141} __Request__lock_acquire_t;
142#ifdef __MigPackStructs
143#pragma pack()
144#endif
145
146#ifdef __MigPackStructs
147#pragma pack(4)
148#endif
149typedef struct {
150mach_msg_header_t Head;
151NDR_record_t NDR;
152int lock_id;
153} __Request__lock_release_t;
154#ifdef __MigPackStructs
155#pragma pack()
156#endif
157
158#ifdef __MigPackStructs
159#pragma pack(4)
160#endif
161typedef struct {
162mach_msg_header_t Head;
163NDR_record_t NDR;
164int lock_id;
165} __Request__lock_try_t;
166#ifdef __MigPackStructs
167#pragma pack()
168#endif
169
170#ifdef __MigPackStructs
171#pragma pack(4)
172#endif
173typedef struct {
174mach_msg_header_t Head;
175NDR_record_t NDR;
176int lock_id;
177} __Request__lock_make_stable_t;
178#ifdef __MigPackStructs
179#pragma pack()
180#endif
181
182#ifdef __MigPackStructs
183#pragma pack(4)
184#endif
185typedef struct {
186mach_msg_header_t Head;
187NDR_record_t NDR;
188int lock_id;
189} __Request__lock_handoff_t;
190#ifdef __MigPackStructs
191#pragma pack()
192#endif
193
194#ifdef __MigPackStructs
195#pragma pack(4)
196#endif
197typedef struct {
198mach_msg_header_t Head;
199NDR_record_t NDR;
200int lock_id;
201} __Request__lock_handoff_accept_t;
202#ifdef __MigPackStructs
203#pragma pack()
204#endif
205#endif /* !__Request__lock_set_subsystem__defined */
206
207/* union of all requests */
208
209#ifndef __RequestUnion__lock_set_subsystem__defined
210#define __RequestUnion__lock_set_subsystem__defined
211union __RequestUnion__lock_set_subsystem {
212__Request__lock_acquire_t Request_lock_acquire;
213__Request__lock_release_t Request_lock_release;
214__Request__lock_try_t Request_lock_try;
215__Request__lock_make_stable_t Request_lock_make_stable;
216__Request__lock_handoff_t Request_lock_handoff;
217__Request__lock_handoff_accept_t Request_lock_handoff_accept;
218};
219#endif /* !__RequestUnion__lock_set_subsystem__defined */
220/* typedefs for all replies */
221
222#ifndef __Reply__lock_set_subsystem__defined
223#define __Reply__lock_set_subsystem__defined
224
225#ifdef __MigPackStructs
226#pragma pack(4)
227#endif
228typedef struct {
229mach_msg_header_t Head;
230NDR_record_t NDR;
231kern_return_t RetCode;
232} __Reply__lock_acquire_t;
233#ifdef __MigPackStructs
234#pragma pack()
235#endif
236
237#ifdef __MigPackStructs
238#pragma pack(4)
239#endif
240typedef struct {
241mach_msg_header_t Head;
242NDR_record_t NDR;
243kern_return_t RetCode;
244} __Reply__lock_release_t;
245#ifdef __MigPackStructs
246#pragma pack()
247#endif
248
249#ifdef __MigPackStructs
250#pragma pack(4)
251#endif
252typedef struct {
253mach_msg_header_t Head;
254NDR_record_t NDR;
255kern_return_t RetCode;
256} __Reply__lock_try_t;
257#ifdef __MigPackStructs
258#pragma pack()
259#endif
260
261#ifdef __MigPackStructs
262#pragma pack(4)
263#endif
264typedef struct {
265mach_msg_header_t Head;
266NDR_record_t NDR;
267kern_return_t RetCode;
268} __Reply__lock_make_stable_t;
269#ifdef __MigPackStructs
270#pragma pack()
271#endif
272
273#ifdef __MigPackStructs
274#pragma pack(4)
275#endif
276typedef struct {
277mach_msg_header_t Head;
278NDR_record_t NDR;
279kern_return_t RetCode;
280} __Reply__lock_handoff_t;
281#ifdef __MigPackStructs
282#pragma pack()
283#endif
284
285#ifdef __MigPackStructs
286#pragma pack(4)
287#endif
288typedef struct {
289mach_msg_header_t Head;
290NDR_record_t NDR;
291kern_return_t RetCode;
292} __Reply__lock_handoff_accept_t;
293#ifdef __MigPackStructs
294#pragma pack()
295#endif
296#endif /* !__Reply__lock_set_subsystem__defined */
297
298/* union of all replies */
299
300#ifndef __ReplyUnion__lock_set_subsystem__defined
301#define __ReplyUnion__lock_set_subsystem__defined
302union __ReplyUnion__lock_set_subsystem {
303__Reply__lock_acquire_t Reply_lock_acquire;
304__Reply__lock_release_t Reply_lock_release;
305__Reply__lock_try_t Reply_lock_try;
306__Reply__lock_make_stable_t Reply_lock_make_stable;
307__Reply__lock_handoff_t Reply_lock_handoff;
308__Reply__lock_handoff_accept_t Reply_lock_handoff_accept;
309};
310#endif /* !__RequestUnion__lock_set_subsystem__defined */
311
312#ifndef subsystem_to_name_map_lock_set
313#define subsystem_to_name_map_lock_set \
314 { "lock_acquire", 617000 },\
315 { "lock_release", 617001 },\
316 { "lock_try", 617002 },\
317 { "lock_make_stable", 617003 },\
318 { "lock_handoff", 617004 },\
319 { "lock_handoff_accept", 617005 }
320#endif
321
322#ifdef __AfterMigUserHeader
323__AfterMigUserHeader
324#endif /* __AfterMigUserHeader */
325
326#endif /* _lock_set_user_ */
327

Archive Download this file

Revision: 1808