Debian Codegraph @

third_party/rust/libc/src/unix/nto/neutrino.rs

raw
1 use crate::prelude::*;
2
3 pub type nto_job_t = crate::sync_t;
4
5 s! {
6 pub struct syspage_entry_info {
7 pub entry_off: u16,
8 pub entry_size: u16,
9 }
10 pub struct syspage_array_info {
11 entry_off: u16,
12 entry_size: u16,
13 element_size: u16,
14 }
15
16 pub struct intrspin {
17 pub value: c_uint, // volatile
18 }
19
20 pub struct iov_t {
21 pub iov_base: *mut c_void, // union
22 pub iov_len: size_t,
23 }
24
25 pub struct _itimer {
26 pub nsec: u64,
27 pub interval_nsec: u64,
28 }
29
30 pub struct _msg_info64 {
31 pub nd: u32,
32 pub srcnd: u32,
33 pub pid: crate::pid_t,
34 pub tid: i32,
35 pub chid: i32,
36 pub scoid: i32,
37 pub coid: i32,
38 pub priority: i16,
39 pub flags: i16,
40 pub msglen: isize,
41 pub srcmsglen: isize,
42 pub dstmsglen: isize,
43 pub type_id: u32,
44 reserved: u32,
45 }
46
47 pub struct _cred_info {
48 pub ruid: crate::uid_t,
49 pub euid: crate::uid_t,
50 pub suid: crate::uid_t,
51 pub rgid: crate::gid_t,
52 pub egid: crate::gid_t,
53 pub sgid: crate::gid_t,
54 pub ngroups: u32,
55 pub grouplist: [crate::gid_t; 8],
56 }
57
58 pub struct _client_info {
59 pub nd: u32,
60 pub pid: crate::pid_t,
61 pub sid: crate::pid_t,
62 pub flags: u32,
63 pub cred: crate::_cred_info,
64 }
65
66 pub struct _client_able {
67 pub ability: u32,
68 pub flags: u32,
69 pub range_lo: u64,
70 pub range_hi: u64,
71 }
72
73 pub struct nto_channel_config {
74 pub event: crate::sigevent,
75 pub num_pulses: c_uint,
76 pub rearm_threshold: c_uint,
77 pub options: c_uint,
78 reserved: [c_uint; 3],
79 }
80
81 // TODO: The following structures are defined in a header file which doesn't
82 // appear as part of the default headers found in a standard installation
83 // of Neutrino 7.1 SDP. Commented out for now.
84 //pub struct _asyncmsg_put_header {
85 // pub err: c_int,
86 // pub iov: *mut crate::iov_t,
87 // pub parts: c_int,
88 // pub handle: c_uint,
89 // pub cb: Option<
90 // unsafe extern "C" fn(
91 // err: c_int,
92 // buf: *mut c_void,
93 // handle: c_uint,
94 // ) -> c_int>,
95 // pub put_hdr_flags: c_uint,
96 //}
97
98 //pub struct _asyncmsg_connection_attr {
99 // pub call_back: Option<
100 // unsafe extern "C" fn(
101 // err: c_int,
102 // buff: *mut c_void,
103 // handle: c_uint,
104 // ) -> c_int>,
105 // pub buffer_size: size_t,
106 // pub max_num_buffer: c_uint,
107 // pub trigger_num_msg: c_uint,
108 // pub trigger_time: crate::_itimer,
109 // reserve: c_uint,
110 //}
111
112 //pub struct _asyncmsg_connection_descriptor {
113 // pub flags: c_uint,
114 // pub sendq_size: c_uint,
115 // pub sendq_head: c_uint,
116 // pub sendq_tail: c_uint,
117 // pub sendq_free: c_uint,
118 // pub err: c_int,
119 // pub ev: crate::sigevent,
120 // pub num_curmsg: c_uint,
121 // pub ttimer: crate::timer_t,
122 // pub block_con: crate::pthread_cond_t,
123 // pub mu: crate::pthread_mutex_t,
124 // reserved: c_uint,
125 // pub attr: crate::_asyncmsg_connection_attr,
126 // pub reserves: [c_uint; 3],
127 // pub sendq: [crate::_asyncmsg_put_header; 1], // flexarray
128 //}
129
130 pub struct __c_anonymous_struct_ev {
131 pub event: crate::sigevent,
132 pub coid: c_int,
133 }
134
135 pub struct _channel_connect_attr {
136 // union
137 pub ev: crate::__c_anonymous_struct_ev,
138 }
139
140 pub struct _sighandler_info {
141 pub siginfo: crate::siginfo_t,
142 pub handler: Option<unsafe extern "C" fn(value: c_int)>,
143 pub context: *mut c_void,
144 }
145
146 pub struct __c_anonymous_struct_time {
147 pub length: c_uint,
148 pub scale: c_uint,
149 }
150
151 pub struct _idle_hook {
152 pub hook_size: c_uint,
153 pub cmd: c_uint,
154 pub mode: c_uint,
155 pub latency: c_uint,
156 pub next_fire: u64,
157 pub curr_time: u64,
158 pub tod_adjust: u64,
159 pub resp: c_uint,
160 pub time: __c_anonymous_struct_time,
161 pub trigger: crate::sigevent,
162 pub intrs: *mut c_uint,
163 pub block_stack_size: c_uint,
164 }
165
166 pub struct _clockadjust {
167 pub tick_count: u32,
168 pub tick_nsec_inc: i32,
169 }
170
171 pub struct qtime_entry {
172 pub cycles_per_sec: u64,
173 pub nsec_tod_adjust: u64, // volatile
174 pub nsec: u64, // volatile
175 pub nsec_inc: u32,
176 pub boot_time: u32,
177 pub adjust: _clockadjust,
178 pub timer_rate: u32,
179 pub timer_scale: i32,
180 pub timer_load: u32,
181 pub intr: i32,
182 pub epoch: u32,
183 pub flags: u32,
184 pub rr_interval_mul: u32,
185 pub timer_load_hi: u32,
186 pub nsec_stable: u64, // volatile
187 pub timer_load_max: u64,
188 pub timer_prog_time: u32,
189 spare: [u32; 7],
190 }
191
192 pub struct _sched_info {
193 pub priority_min: c_int,
194 pub priority_max: c_int,
195 pub interval: u64,
196 pub priority_priv: c_int,
197 reserved: [c_int; 11],
198 }
199
200 pub struct _timer_info {
201 pub itime: crate::_itimer,
202 pub otime: crate::_itimer,
203 pub flags: u32,
204 pub tid: i32,
205 pub notify: i32,
206 pub clockid: crate::clockid_t,
207 pub overruns: u32,
208 pub event: crate::sigevent, // union
209 }
210
211 pub struct _clockperiod {
212 pub nsec: u32,
213 pub fract: i32,
214 }
215 }
216
217 s_no_extra_traits! {
218 #[repr(align(8))]
219 pub struct syspage_entry {
220 pub size: u16,
221 pub total_size: u16,
222 pub type_: u16,
223 pub num_cpu: u16,
224 pub system_private: syspage_entry_info,
225 pub old_asinfo: syspage_entry_info,
226 pub __mangle_name_to_cause_compilation_errs_meminfo: syspage_entry_info,
227 pub hwinfo: syspage_entry_info,
228 pub old_cpuinfo: syspage_entry_info,
229 pub old_cacheattr: syspage_entry_info,
230 pub qtime: syspage_entry_info,
231 pub callout: syspage_entry_info,
232 pub callin: syspage_entry_info,
233 pub typed_strings: syspage_entry_info,
234 pub strings: syspage_entry_info,
235 pub old_intrinfo: syspage_entry_info,
236 pub smp: syspage_entry_info,
237 pub pminfo: syspage_entry_info,
238 pub old_mdriver: syspage_entry_info,
239 spare0: [u32; 1],
240 __reserved: [u8; 160], // anonymous union with architecture dependent structs
241 pub new_asinfo: syspage_array_info,
242 pub new_cpuinfo: syspage_array_info,
243 pub new_cacheattr: syspage_array_info,
244 pub new_intrinfo: syspage_array_info,
245 pub new_mdriver: syspage_array_info,
246 }
247 }
248
249 pub const SYSMGR_PID: u32 = 1;
250 pub const SYSMGR_CHID: u32 = 1;
251 pub const SYSMGR_COID: u32 = _NTO_SIDE_CHANNEL;
252 pub const SYSMGR_HANDLE: u32 = 0;
253
254 pub const STATE_DEAD: c_int = 0x00;
255 pub const STATE_RUNNING: c_int = 0x01;
256 pub const STATE_READY: c_int = 0x02;
257 pub const STATE_STOPPED: c_int = 0x03;
258 pub const STATE_SEND: c_int = 0x04;
259 pub const STATE_RECEIVE: c_int = 0x05;
260 pub const STATE_REPLY: c_int = 0x06;
261 pub const STATE_STACK: c_int = 0x07;
262 pub const STATE_WAITTHREAD: c_int = 0x08;
263 pub const STATE_WAITPAGE: c_int = 0x09;
264 pub const STATE_SIGSUSPEND: c_int = 0x0a;
265 pub const STATE_SIGWAITINFO: c_int = 0x0b;
266 pub const STATE_NANOSLEEP: c_int = 0x0c;
267 pub const STATE_MUTEX: c_int = 0x0d;
268 pub const STATE_CONDVAR: c_int = 0x0e;
269 pub const STATE_JOIN: c_int = 0x0f;
270 pub const STATE_INTR: c_int = 0x10;
271 pub const STATE_SEM: c_int = 0x11;
272 pub const STATE_WAITCTX: c_int = 0x12;
273 pub const STATE_NET_SEND: c_int = 0x13;
274 pub const STATE_NET_REPLY: c_int = 0x14;
275 pub const STATE_MAX: c_int = 0x18;
276
277 pub const _NTO_TIMEOUT_RECEIVE: i32 = 1 << STATE_RECEIVE;
278 pub const _NTO_TIMEOUT_SEND: i32 = 1 << STATE_SEND;
279 pub const _NTO_TIMEOUT_REPLY: i32 = 1 << STATE_REPLY;
280 pub const _NTO_TIMEOUT_SIGSUSPEND: i32 = 1 << STATE_SIGSUSPEND;
281 pub const _NTO_TIMEOUT_SIGWAITINFO: i32 = 1 << STATE_SIGWAITINFO;
282 pub const _NTO_TIMEOUT_NANOSLEEP: i32 = 1 << STATE_NANOSLEEP;
283 pub const _NTO_TIMEOUT_MUTEX: i32 = 1 << STATE_MUTEX;
284 pub const _NTO_TIMEOUT_CONDVAR: i32 = 1 << STATE_CONDVAR;
285 pub const _NTO_TIMEOUT_JOIN: i32 = 1 << STATE_JOIN;
286 pub const _NTO_TIMEOUT_INTR: i32 = 1 << STATE_INTR;
287 pub const _NTO_TIMEOUT_SEM: i32 = 1 << STATE_SEM;
288
289 pub const _NTO_MI_ENDIAN_BIG: u32 = 1;
290 pub const _NTO_MI_ENDIAN_DIFF: u32 = 2;
291 pub const _NTO_MI_UNBLOCK_REQ: u32 = 256;
292 pub const _NTO_MI_NET_CRED_DIRTY: u32 = 512;
293 pub const _NTO_MI_CONSTRAINED: u32 = 1024;
294 pub const _NTO_MI_CHROOT: u32 = 2048;
295 pub const _NTO_MI_BITS_64: u32 = 4096;
296 pub const _NTO_MI_BITS_DIFF: u32 = 8192;
297 pub const _NTO_MI_SANDBOX: u32 = 16384;
298
299 pub const _NTO_CI_ENDIAN_BIG: u32 = 1;
300 pub const _NTO_CI_BKGND_PGRP: u32 = 4;
301 pub const _NTO_CI_ORPHAN_PGRP: u32 = 8;
302 pub const _NTO_CI_STOPPED: u32 = 128;
303 pub const _NTO_CI_UNABLE: u32 = 256;
304 pub const _NTO_CI_TYPE_ID: u32 = 512;
305 pub const _NTO_CI_CHROOT: u32 = 2048;
306 pub const _NTO_CI_BITS_64: u32 = 4096;
307 pub const _NTO_CI_SANDBOX: u32 = 16384;
308 pub const _NTO_CI_LOADER: u32 = 32768;
309 pub const _NTO_CI_FULL_GROUPS: u32 = 2147483648;
310
311 pub const _NTO_TI_ACTIVE: u32 = 1;
312 pub const _NTO_TI_ABSOLUTE: u32 = 2;
313 pub const _NTO_TI_EXPIRED: u32 = 4;
314 pub const _NTO_TI_TOD_BASED: u32 = 8;
315 pub const _NTO_TI_TARGET_PROCESS: u32 = 16;
316 pub const _NTO_TI_REPORT_TOLERANCE: u32 = 32;
317 pub const _NTO_TI_PRECISE: u32 = 64;
318 pub const _NTO_TI_TOLERANT: u32 = 128;
319 pub const _NTO_TI_WAKEUP: u32 = 256;
320 pub const _NTO_TI_PROCESS_TOLERANT: u32 = 512;
321 pub const _NTO_TI_HIGH_RESOLUTION: u32 = 1024;
322
323 pub const _PULSE_TYPE: u32 = 0;
324 pub const _PULSE_SUBTYPE: u32 = 0;
325 pub const _PULSE_CODE_UNBLOCK: i32 = -32;
326 pub const _PULSE_CODE_DISCONNECT: i32 = -33;
327 pub const _PULSE_CODE_THREADDEATH: i32 = -34;
328 pub const _PULSE_CODE_COIDDEATH: i32 = -35;
329 pub const _PULSE_CODE_NET_ACK: i32 = -36;
330 pub const _PULSE_CODE_NET_UNBLOCK: i32 = -37;
331 pub const _PULSE_CODE_NET_DETACH: i32 = -38;
332 pub const _PULSE_CODE_RESTART: i32 = -39;
333 pub const _PULSE_CODE_NORESTART: i32 = -40;
334 pub const _PULSE_CODE_UNBLOCK_RESTART: i32 = -41;
335 pub const _PULSE_CODE_UNBLOCK_TIMER: i32 = -42;
336 pub const _PULSE_CODE_MINAVAIL: u32 = 0;
337 pub const _PULSE_CODE_MAXAVAIL: u32 = 127;
338
339 pub const _NTO_HARD_FLAGS_END: u32 = 1;
340
341 pub const _NTO_PULSE_IF_UNIQUE: u32 = 4096;
342 pub const _NTO_PULSE_REPLACE: u32 = 8192;
343
344 pub const _NTO_PF_NOCLDSTOP: u32 = 1;
345 pub const _NTO_PF_LOADING: u32 = 2;
346 pub const _NTO_PF_TERMING: u32 = 4;
347 pub const _NTO_PF_ZOMBIE: u32 = 8;
348 pub const _NTO_PF_NOZOMBIE: u32 = 16;
349 pub const _NTO_PF_FORKED: u32 = 32;
350 pub const _NTO_PF_ORPHAN_PGRP: u32 = 64;
351 pub const _NTO_PF_STOPPED: u32 = 128;
352 pub const _NTO_PF_DEBUG_STOPPED: u32 = 256;
353 pub const _NTO_PF_BKGND_PGRP: u32 = 512;
354 pub const _NTO_PF_NOISYNC: u32 = 1024;
355 pub const _NTO_PF_CONTINUED: u32 = 2048;
356 pub const _NTO_PF_CHECK_INTR: u32 = 4096;
357 pub const _NTO_PF_COREDUMP: u32 = 8192;
358 pub const _NTO_PF_RING0: u32 = 32768;
359 pub const _NTO_PF_SLEADER: u32 = 65536;
360 pub const _NTO_PF_WAITINFO: u32 = 131072;
361 pub const _NTO_PF_DESTROYALL: u32 = 524288;
362 pub const _NTO_PF_NOCOREDUMP: u32 = 1048576;
363 pub const _NTO_PF_WAITDONE: u32 = 4194304;
364 pub const _NTO_PF_TERM_WAITING: u32 = 8388608;
365 pub const _NTO_PF_ASLR: u32 = 16777216;
366 pub const _NTO_PF_EXECED: u32 = 33554432;
367 pub const _NTO_PF_APP_STOPPED: u32 = 67108864;
368 pub const _NTO_PF_64BIT: u32 = 134217728;
369 pub const _NTO_PF_NET: u32 = 268435456;
370 pub const _NTO_PF_NOLAZYSTACK: u32 = 536870912;
371 pub const _NTO_PF_NOEXEC_STACK: u32 = 1073741824;
372 pub const _NTO_PF_LOADER_PERMS: u32 = 2147483648;
373
374 pub const _NTO_TF_INTR_PENDING: u32 = 65536;
375 pub const _NTO_TF_DETACHED: u32 = 131072;
376 pub const _NTO_TF_SHR_MUTEX: u32 = 262144;
377 pub const _NTO_TF_SHR_MUTEX_EUID: u32 = 524288;
378 pub const _NTO_TF_THREADS_HOLD: u32 = 1048576;
379 pub const _NTO_TF_UNBLOCK_REQ: u32 = 4194304;
380 pub const _NTO_TF_ALIGN_FAULT: u32 = 16777216;
381 pub const _NTO_TF_SSTEP: u32 = 33554432;
382 pub const _NTO_TF_ALLOCED_STACK: u32 = 67108864;
383 pub const _NTO_TF_NOMULTISIG: u32 = 134217728;
384 pub const _NTO_TF_LOW_LATENCY: u32 = 268435456;
385 pub const _NTO_TF_IOPRIV: u32 = 2147483648;
386
387 pub const _NTO_TCTL_IO_PRIV: u32 = 1;
388 pub const _NTO_TCTL_THREADS_HOLD: u32 = 2;
389 pub const _NTO_TCTL_THREADS_CONT: u32 = 3;
390 pub const _NTO_TCTL_RUNMASK: u32 = 4;
391 pub const _NTO_TCTL_ALIGN_FAULT: u32 = 5;
392 pub const _NTO_TCTL_RUNMASK_GET_AND_SET: u32 = 6;
393 pub const _NTO_TCTL_PERFCOUNT: u32 = 7;
394 pub const _NTO_TCTL_ONE_THREAD_HOLD: u32 = 8;
395 pub const _NTO_TCTL_ONE_THREAD_CONT: u32 = 9;
396 pub const _NTO_TCTL_RUNMASK_GET_AND_SET_INHERIT: u32 = 10;
397 pub const _NTO_TCTL_NAME: u32 = 11;
398 pub const _NTO_TCTL_RCM_GET_AND_SET: u32 = 12;
399 pub const _NTO_TCTL_SHR_MUTEX: u32 = 13;
400 pub const _NTO_TCTL_IO: u32 = 14;
401 pub const _NTO_TCTL_NET_KIF_GET_AND_SET: u32 = 15;
402 pub const _NTO_TCTL_LOW_LATENCY: u32 = 16;
403 pub const _NTO_TCTL_ADD_EXIT_EVENT: u32 = 17;
404 pub const _NTO_TCTL_DEL_EXIT_EVENT: u32 = 18;
405 pub const _NTO_TCTL_IO_LEVEL: u32 = 19;
406 pub const _NTO_TCTL_RESERVED: u32 = 2147483648;
407 pub const _NTO_TCTL_IO_LEVEL_INHERIT: u32 = 1073741824;
408 pub const _NTO_IO_LEVEL_NONE: u32 = 1;
409 pub const _NTO_IO_LEVEL_1: u32 = 2;
410 pub const _NTO_IO_LEVEL_2: u32 = 3;
411
412 pub const _NTO_THREAD_NAME_MAX: u32 = 100;
413
414 pub const _NTO_CHF_FIXED_PRIORITY: u32 = 1;
415 pub const _NTO_CHF_UNBLOCK: u32 = 2;
416 pub const _NTO_CHF_THREAD_DEATH: u32 = 4;
417 pub const _NTO_CHF_DISCONNECT: u32 = 8;
418 pub const _NTO_CHF_NET_MSG: u32 = 16;
419 pub const _NTO_CHF_SENDER_LEN: u32 = 32;
420 pub const _NTO_CHF_COID_DISCONNECT: u32 = 64;
421 pub const _NTO_CHF_REPLY_LEN: u32 = 128;
422 pub const _NTO_CHF_PULSE_POOL: u32 = 256;
423 pub const _NTO_CHF_ASYNC_NONBLOCK: u32 = 512;
424 pub const _NTO_CHF_ASYNC: u32 = 1024;
425 pub const _NTO_CHF_GLOBAL: u32 = 2048;
426 pub const _NTO_CHF_PRIVATE: u32 = 4096;
427 pub const _NTO_CHF_MSG_PAUSING: u32 = 8192;
428 pub const _NTO_CHF_INHERIT_RUNMASK: u32 = 16384;
429 pub const _NTO_CHF_UNBLOCK_TIMER: u32 = 32768;
430
431 pub const _NTO_CHO_CUSTOM_EVENT: u32 = 1;
432
433 pub const _NTO_COF_CLOEXEC: u32 = 1;
434 pub const _NTO_COF_DEAD: u32 = 2;
435 pub const _NTO_COF_NOSHARE: u32 = 64;
436 pub const _NTO_COF_NETCON: u32 = 128;
437 pub const _NTO_COF_NONBLOCK: u32 = 256;
438 pub const _NTO_COF_ASYNC: u32 = 512;
439 pub const _NTO_COF_GLOBAL: u32 = 1024;
440 pub const _NTO_COF_NOEVENT: u32 = 2048;
441 pub const _NTO_COF_INSECURE: u32 = 4096;
442 pub const _NTO_COF_REG_EVENTS: u32 = 8192;
443 pub const _NTO_COF_UNREG_EVENTS: u32 = 16384;
444 pub const _NTO_COF_MASK: u32 = 65535;
445
446 pub const _NTO_SIDE_CHANNEL: u32 = 1073741824;
447
448 pub const _NTO_CONNECTION_SCOID: u32 = 65536;
449 pub const _NTO_GLOBAL_CHANNEL: u32 = 1073741824;
450
451 pub const _NTO_TIMEOUT_MASK: u32 = (1 << STATE_MAX) - 1;
452 pub const _NTO_TIMEOUT_ACTIVE: u32 = 1 << STATE_MAX;
453 pub const _NTO_TIMEOUT_IMMEDIATE: u32 = 1 << (STATE_MAX + 1);
454
455 pub const _NTO_IC_LATENCY: u32 = 0;
456
457 pub const _NTO_INTR_FLAGS_END: u32 = 1;
458 pub const _NTO_INTR_FLAGS_NO_UNMASK: u32 = 2;
459 pub const _NTO_INTR_FLAGS_PROCESS: u32 = 4;
460 pub const _NTO_INTR_FLAGS_TRK_MSK: u32 = 8;
461 pub const _NTO_INTR_FLAGS_ARRAY: u32 = 16;
462 pub const _NTO_INTR_FLAGS_EXCLUSIVE: u32 = 32;
463 pub const _NTO_INTR_FLAGS_FPU: u32 = 64;
464
465 pub const _NTO_INTR_CLASS_EXTERNAL: u32 = 0;
466 pub const _NTO_INTR_CLASS_SYNTHETIC: u32 = 2147418112;
467
468 pub const _NTO_INTR_SPARE: u32 = 2147483647;
469
470 pub const _NTO_HOOK_IDLE: u32 = 2147418113;
471 pub const _NTO_HOOK_OVERDRIVE: u32 = 2147418114;
472 pub const _NTO_HOOK_LAST: u32 = 2147418114;
473 pub const _NTO_HOOK_IDLE2_FLAG: u32 = 32768;
474
475 pub const _NTO_IH_CMD_SLEEP_SETUP: u32 = 1;
476 pub const _NTO_IH_CMD_SLEEP_BLOCK: u32 = 2;
477 pub const _NTO_IH_CMD_SLEEP_WAKEUP: u32 = 4;
478 pub const _NTO_IH_CMD_SLEEP_ONLINE: u32 = 8;
479 pub const _NTO_IH_RESP_NEEDS_BLOCK: u32 = 1;
480 pub const _NTO_IH_RESP_NEEDS_WAKEUP: u32 = 2;
481 pub const _NTO_IH_RESP_NEEDS_ONLINE: u32 = 4;
482 pub const _NTO_IH_RESP_SYNC_TIME: u32 = 16;
483 pub const _NTO_IH_RESP_SYNC_TLB: u32 = 32;
484 pub const _NTO_IH_RESP_SUGGEST_OFFLINE: u32 = 256;
485 pub const _NTO_IH_RESP_SLEEP_MODE_REACHED: u32 = 512;
486 pub const _NTO_IH_RESP_DELIVER_INTRS: u32 = 1024;
487
488 pub const _NTO_READIOV_SEND: u32 = 0;
489 pub const _NTO_READIOV_REPLY: u32 = 1;
490
491 pub const _NTO_KEYDATA_VTID: u32 = 2147483648;
492
493 pub const _NTO_KEYDATA_PATHSIGN: u32 = 32768;
494 pub const _NTO_KEYDATA_OP_MASK: u32 = 255;
495 pub const _NTO_KEYDATA_VERIFY: u32 = 0;
496 pub const _NTO_KEYDATA_CALCULATE: u32 = 1;
497 pub const _NTO_KEYDATA_CALCULATE_REUSE: u32 = 2;
498 pub const _NTO_KEYDATA_PATHSIGN_VERIFY: u32 = 32768;
499 pub const _NTO_KEYDATA_PATHSIGN_CALCULATE: u32 = 32769;
500 pub const _NTO_KEYDATA_PATHSIGN_CALCULATE_REUSE: u32 = 32770;
501
502 pub const _NTO_SCTL_SETPRIOCEILING: u32 = 1;
503 pub const _NTO_SCTL_GETPRIOCEILING: u32 = 2;
504 pub const _NTO_SCTL_SETEVENT: u32 = 3;
505 pub const _NTO_SCTL_MUTEX_WAKEUP: u32 = 4;
506 pub const _NTO_SCTL_MUTEX_CONSISTENT: u32 = 5;
507 pub const _NTO_SCTL_SEM_VALUE: u32 = 6;
508
509 pub const _NTO_CLIENTINFO_GETGROUPS: u32 = 1;
510 pub const _NTO_CLIENTINFO_GETTYPEID: u32 = 2;
511
512 extern "C" {
513 pub fn ChannelCreate(__flags: c_uint) -> c_int;
514 pub fn ChannelCreate_r(__flags: c_uint) -> c_int;
515 pub fn ChannelCreatePulsePool(__flags: c_uint, __config: *const nto_channel_config) -> c_int;
516 pub fn ChannelCreateExt(
517 __flags: c_uint,
518 __mode: crate::mode_t,
519 __bufsize: usize,
520 __maxnumbuf: c_uint,
521 __ev: *const crate::sigevent,
522 __cred: *mut _cred_info,
523 ) -> c_int;
524 pub fn ChannelDestroy(__chid: c_int) -> c_int;
525 pub fn ChannelDestroy_r(__chid: c_int) -> c_int;
526 pub fn ConnectAttach(
527 __nd: u32,
528 __pid: crate::pid_t,
529 __chid: c_int,
530 __index: c_uint,
531 __flags: c_int,
532 ) -> c_int;
533 pub fn ConnectAttach_r(
534 __nd: u32,
535 __pid: crate::pid_t,
536 __chid: c_int,
537 __index: c_uint,
538 __flags: c_int,
539 ) -> c_int;
540
541 // TODO: The following function uses a structure defined in a header file
542 // which doesn't appear as part of the default headers found in a
543 // standard installation of Neutrino 7.1 SDP. Commented out for now.
544 //pub fn ConnectAttachExt(
545 // __nd: u32,
546 // __pid: crate::pid_t,
547 // __chid: c_int,
548 // __index: c_uint,
549 // __flags: c_int,
550 // __cd: *mut _asyncmsg_connection_descriptor,
551 //) -> c_int;
552 pub fn ConnectDetach(__coid: c_int) -> c_int;
553 pub fn ConnectDetach_r(__coid: c_int) -> c_int;
554 pub fn ConnectServerInfo(__pid: crate::pid_t, __coid: c_int, __info: *mut _msg_info64)
555 -> c_int;
556 pub fn ConnectServerInfo_r(
557 __pid: crate::pid_t,
558 __coid: c_int,
559 __info: *mut _msg_info64,
560 ) -> c_int;
561 pub fn ConnectClientInfoExtraArgs(
562 __scoid: c_int,
563 __info_pp: *mut _client_info,
564 __ngroups: c_int,
565 __abilities: *mut _client_able,
566 __nable: c_int,
567 __type_id: *mut c_uint,
568 ) -> c_int;
569 pub fn ConnectClientInfoExtraArgs_r(
570 __scoid: c_int,
571 __info_pp: *mut _client_info,
572 __ngroups: c_int,
573 __abilities: *mut _client_able,
574 __nable: c_int,
575 __type_id: *mut c_uint,
576 ) -> c_int;
577 pub fn ConnectClientInfo(__scoid: c_int, __info: *mut _client_info, __ngroups: c_int) -> c_int;
578 pub fn ConnectClientInfo_r(
579 __scoid: c_int,
580 __info: *mut _client_info,
581 __ngroups: c_int,
582 ) -> c_int;
583 pub fn ConnectClientInfoExt(
584 __scoid: c_int,
585 __info_pp: *mut *mut _client_info,
586 flags: c_int,
587 ) -> c_int;
588 pub fn ClientInfoExtFree(__info_pp: *mut *mut _client_info) -> c_int;
589 pub fn ConnectClientInfoAble(
590 __scoid: c_int,
591 __info_pp: *mut *mut _client_info,
592 flags: c_int,
593 abilities: *mut _client_able,
594 nable: c_int,
595 ) -> c_int;
596 pub fn ConnectFlags(
597 __pid: crate::pid_t,
598 __coid: c_int,
599 __mask: c_uint,
600 __bits: c_uint,
601 ) -> c_int;
602 pub fn ConnectFlags_r(
603 __pid: crate::pid_t,
604 __coid: c_int,
605 __mask: c_uint,
606 __bits: c_uint,
607 ) -> c_int;
608 pub fn ChannelConnectAttr(
609 __id: c_uint,
610 __old_attr: *mut _channel_connect_attr,
611 __new_attr: *mut _channel_connect_attr,
612 __flags: c_uint,
613 ) -> c_int;
614 pub fn MsgSend(
615 __coid: c_int,
616 __smsg: *const c_void,
617 __sbytes: usize,
618 __rmsg: *mut c_void,
619 __rbytes: usize,
620 ) -> c_long;
621 pub fn MsgSend_r(
622 __coid: c_int,
623 __smsg: *const c_void,
624 __sbytes: usize,
625 __rmsg: *mut c_void,
626 __rbytes: usize,
627 ) -> c_long;
628 pub fn MsgSendnc(
629 __coid: c_int,
630 __smsg: *const c_void,
631 __sbytes: usize,
632 __rmsg: *mut c_void,
633 __rbytes: usize,
634 ) -> c_long;
635 pub fn MsgSendnc_r(
636 __coid: c_int,
637 __smsg: *const c_void,
638 __sbytes: usize,
639 __rmsg: *mut c_void,
640 __rbytes: usize,
641 ) -> c_long;
642 pub fn MsgSendsv(
643 __coid: c_int,
644 __smsg: *const c_void,
645 __sbytes: usize,
646 __riov: *const crate::iovec,
647 __rparts: usize,
648 ) -> c_long;
649 pub fn MsgSendsv_r(
650 __coid: c_int,
651 __smsg: *const c_void,
652 __sbytes: usize,
653 __riov: *const crate::iovec,
654 __rparts: usize,
655 ) -> c_long;
656 pub fn MsgSendsvnc(
657 __coid: c_int,
658 __smsg: *const c_void,
659 __sbytes: usize,
660 __riov: *const crate::iovec,
661 __rparts: usize,
662 ) -> c_long;
663 pub fn MsgSendsvnc_r(
664 __coid: c_int,
665 __smsg: *const c_void,
666 __sbytes: usize,
667 __riov: *const crate::iovec,
668 __rparts: usize,
669 ) -> c_long;
670 pub fn MsgSendvs(
671 __coid: c_int,
672 __siov: *const crate::iovec,
673 __sparts: usize,
674 __rmsg: *mut c_void,
675 __rbytes: usize,
676 ) -> c_long;
677 pub fn MsgSendvs_r(
678 __coid: c_int,
679 __siov: *const crate::iovec,
680 __sparts: usize,
681 __rmsg: *mut c_void,
682 __rbytes: usize,
683 ) -> c_long;
684 pub fn MsgSendvsnc(
685 __coid: c_int,
686 __siov: *const crate::iovec,
687 __sparts: usize,
688 __rmsg: *mut c_void,
689 __rbytes: usize,
690 ) -> c_long;
691 pub fn MsgSendvsnc_r(
692 __coid: c_int,
693 __siov: *const crate::iovec,
694 __sparts: usize,
695 __rmsg: *mut c_void,
696 __rbytes: usize,
697 ) -> c_long;
698 pub fn MsgSendv(
699 __coid: c_int,
700 __siov: *const crate::iovec,
701 __sparts: usize,
702 __riov: *const crate::iovec,
703 __rparts: usize,
704 ) -> c_long;
705 pub fn MsgSendv_r(
706 __coid: c_int,
707 __siov: *const crate::iovec,
708 __sparts: usize,
709 __riov: *const crate::iovec,
710 __rparts: usize,
711 ) -> c_long;
712 pub fn MsgSendvnc(
713 __coid: c_int,
714 __siov: *const crate::iovec,
715 __sparts: usize,
716 __riov: *const crate::iovec,
717 __rparts: usize,
718 ) -> c_long;
719 pub fn MsgSendvnc_r(
720 __coid: c_int,
721 __siov: *const crate::iovec,
722 __sparts: usize,
723 __riov: *const crate::iovec,
724 __rparts: usize,
725 ) -> c_long;
726 pub fn MsgReceive(
727 __chid: c_int,
728 __msg: *mut c_void,
729 __bytes: usize,
730 __info: *mut _msg_info64,
731 ) -> c_int;
732 pub fn MsgReceive_r(
733 __chid: c_int,
734 __msg: *mut c_void,
735 __bytes: usize,
736 __info: *mut _msg_info64,
737 ) -> c_int;
738 pub fn MsgReceivev(
739 __chid: c_int,
740 __iov: *const crate::iovec,
741 __parts: usize,
742 __info: *mut _msg_info64,
743 ) -> c_int;
744 pub fn MsgReceivev_r(
745 __chid: c_int,
746 __iov: *const crate::iovec,
747 __parts: usize,
748 __info: *mut _msg_info64,
749 ) -> c_int;
750 pub fn MsgReceivePulse(
751 __chid: c_int,
752 __pulse: *mut c_void,
753 __bytes: usize,
754 __info: *mut _msg_info64,
755 ) -> c_int;
756 pub fn MsgReceivePulse_r(
757 __chid: c_int,
758 __pulse: *mut c_void,
759 __bytes: usize,
760 __info: *mut _msg_info64,
761 ) -> c_int;
762 pub fn MsgReceivePulsev(
763 __chid: c_int,
764 __iov: *const crate::iovec,
765 __parts: usize,
766 __info: *mut _msg_info64,
767 ) -> c_int;
768 pub fn MsgReceivePulsev_r(
769 __chid: c_int,
770 __iov: *const crate::iovec,
771 __parts: usize,
772 __info: *mut _msg_info64,
773 ) -> c_int;
774 pub fn MsgReply(
775 __rcvid: c_int,
776 __status: c_long,
777 __msg: *const c_void,
778 __bytes: usize,
779 ) -> c_int;
780 pub fn MsgReply_r(
781 __rcvid: c_int,
782 __status: c_long,
783 __msg: *const c_void,
784 __bytes: usize,
785 ) -> c_int;
786 pub fn MsgReplyv(
787 __rcvid: c_int,
788 __status: c_long,
789 __iov: *const crate::iovec,
790 __parts: usize,
791 ) -> c_int;
792 pub fn MsgReplyv_r(
793 __rcvid: c_int,
794 __status: c_long,
795 __iov: *const crate::iovec,
796 __parts: usize,
797 ) -> c_int;
798 pub fn MsgReadiov(
799 __rcvid: c_int,
800 __iov: *const crate::iovec,
801 __parts: usize,
802 __offset: usize,
803 __flags: c_int,
804 ) -> isize;
805 pub fn MsgReadiov_r(
806 __rcvid: c_int,
807 __iov: *const crate::iovec,
808 __parts: usize,
809 __offset: usize,
810 __flags: c_int,
811 ) -> isize;
812 pub fn MsgRead(__rcvid: c_int, __msg: *mut c_void, __bytes: usize, __offset: usize) -> isize;
813 pub fn MsgRead_r(__rcvid: c_int, __msg: *mut c_void, __bytes: usize, __offset: usize) -> isize;
814 pub fn MsgReadv(
815 __rcvid: c_int,
816 __iov: *const crate::iovec,
817 __parts: usize,
818 __offset: usize,
819 ) -> isize;
820 pub fn MsgReadv_r(
821 __rcvid: c_int,
822 __iov: *const crate::iovec,
823 __parts: usize,
824 __offset: usize,
825 ) -> isize;
826 pub fn MsgWrite(__rcvid: c_int, __msg: *const c_void, __bytes: usize, __offset: usize)
827 -> isize;
828 pub fn MsgWrite_r(
829 __rcvid: c_int,
830 __msg: *const c_void,
831 __bytes: usize,
832 __offset: usize,
833 ) -> isize;
834 pub fn MsgWritev(
835 __rcvid: c_int,
836 __iov: *const crate::iovec,
837 __parts: usize,
838 __offset: usize,
839 ) -> isize;
840 pub fn MsgWritev_r(
841 __rcvid: c_int,
842 __iov: *const crate::iovec,
843 __parts: usize,
844 __offset: usize,
845 ) -> isize;
846 pub fn MsgSendPulse(__coid: c_int, __priority: c_int, __code: c_int, __value: c_int) -> c_int;
847 pub fn MsgSendPulse_r(__coid: c_int, __priority: c_int, __code: c_int, __value: c_int)
848 -> c_int;
849 pub fn MsgSendPulsePtr(
850 __coid: c_int,
851 __priority: c_int,
852 __code: c_int,
853 __value: *mut c_void,
854 ) -> c_int;
855 pub fn MsgSendPulsePtr_r(
856 __coid: c_int,
857 __priority: c_int,
858 __code: c_int,
859 __value: *mut c_void,
860 ) -> c_int;
861 pub fn MsgDeliverEvent(__rcvid: c_int, __event: *const crate::sigevent) -> c_int;
862 pub fn MsgDeliverEvent_r(__rcvid: c_int, __event: *const crate::sigevent) -> c_int;
863 pub fn MsgVerifyEvent(__rcvid: c_int, __event: *const crate::sigevent) -> c_int;
864 pub fn MsgVerifyEvent_r(__rcvid: c_int, __event: *const crate::sigevent) -> c_int;
865 pub fn MsgRegisterEvent(__event: *mut crate::sigevent, __coid: c_int) -> c_int;
866 pub fn MsgRegisterEvent_r(__event: *mut crate::sigevent, __coid: c_int) -> c_int;
867 pub fn MsgUnregisterEvent(__event: *const crate::sigevent) -> c_int;
868 pub fn MsgUnregisterEvent_r(__event: *const crate::sigevent) -> c_int;
869 pub fn MsgInfo(__rcvid: c_int, __info: *mut _msg_info64) -> c_int;
870 pub fn MsgInfo_r(__rcvid: c_int, __info: *mut _msg_info64) -> c_int;
871 pub fn MsgKeyData(
872 __rcvid: c_int,
873 __oper: c_int,
874 __key: u32,
875 __newkey: *mut u32,
876 __iov: *const crate::iovec,
877 __parts: c_int,
878 ) -> c_int;
879 pub fn MsgKeyData_r(
880 __rcvid: c_int,
881 __oper: c_int,
882 __key: u32,
883 __newkey: *mut u32,
884 __iov: *const crate::iovec,
885 __parts: c_int,
886 ) -> c_int;
887 pub fn MsgError(__rcvid: c_int, __err: c_int) -> c_int;
888 pub fn MsgError_r(__rcvid: c_int, __err: c_int) -> c_int;
889 pub fn MsgCurrent(__rcvid: c_int) -> c_int;
890 pub fn MsgCurrent_r(__rcvid: c_int) -> c_int;
891 pub fn MsgSendAsyncGbl(
892 __coid: c_int,
893 __smsg: *const c_void,
894 __sbytes: usize,
895 __msg_prio: c_uint,
896 ) -> c_int;
897 pub fn MsgSendAsync(__coid: c_int) -> c_int;
898 pub fn MsgReceiveAsyncGbl(
899 __chid: c_int,
900 __rmsg: *mut c_void,
901 __rbytes: usize,
902 __info: *mut _msg_info64,
903 __coid: c_int,
904 ) -> c_int;
905 pub fn MsgReceiveAsync(__chid: c_int, __iov: *const crate::iovec, __parts: c_uint) -> c_int;
906 pub fn MsgPause(__rcvid: c_int, __cookie: c_uint) -> c_int;
907 pub fn MsgPause_r(__rcvid: c_int, __cookie: c_uint) -> c_int;
908
909 pub fn SignalKill(
910 __nd: u32,
911 __pid: crate::pid_t,
912 __tid: c_int,
913 __signo: c_int,
914 __code: c_int,
915 __value: c_int,
916 ) -> c_int;
917 pub fn SignalKill_r(
918 __nd: u32,
919 __pid: crate::pid_t,
920 __tid: c_int,
921 __signo: c_int,
922 __code: c_int,
923 __value: c_int,
924 ) -> c_int;
925 pub fn SignalKillSigval(
926 __nd: u32,
927 __pid: crate::pid_t,
928 __tid: c_int,
929 __signo: c_int,
930 __code: c_int,
931 __value: *const crate::sigval,
932 ) -> c_int;
933 pub fn SignalKillSigval_r(
934 __nd: u32,
935 __pid: crate::pid_t,
936 __tid: c_int,
937 __signo: c_int,
938 __code: c_int,
939 __value: *const crate::sigval,
940 ) -> c_int;
941 pub fn SignalReturn(__info: *mut _sighandler_info) -> c_int;
942 pub fn SignalFault(__sigcode: c_uint, __regs: *mut c_void, __refaddr: usize) -> c_int;
943 pub fn SignalAction(
944 __pid: crate::pid_t,
945 __sigstub: unsafe extern "C" fn(),
946 __signo: c_int,
947 __act: *const crate::sigaction,
948 __oact: *mut crate::sigaction,
949 ) -> c_int;
950 pub fn SignalAction_r(
951 __pid: crate::pid_t,
952 __sigstub: unsafe extern "C" fn(),
953 __signo: c_int,
954 __act: *const crate::sigaction,
955 __oact: *mut crate::sigaction,
956 ) -> c_int;
957 pub fn SignalProcmask(
958 __pid: crate::pid_t,
959 __tid: c_int,
960 __how: c_int,
961 __set: *const crate::sigset_t,
962 __oldset: *mut crate::sigset_t,
963 ) -> c_int;
964 pub fn SignalProcmask_r(
965 __pid: crate::pid_t,
966 __tid: c_int,
967 __how: c_int,
968 __set: *const crate::sigset_t,
969 __oldset: *mut crate::sigset_t,
970 ) -> c_int;
971 pub fn SignalSuspend(__set: *const crate::sigset_t) -> c_int;
972 pub fn SignalSuspend_r(__set: *const crate::sigset_t) -> c_int;
973 pub fn SignalWaitinfo(__set: *const crate::sigset_t, __info: *mut crate::siginfo_t) -> c_int;
974 pub fn SignalWaitinfo_r(__set: *const crate::sigset_t, __info: *mut crate::siginfo_t) -> c_int;
975 pub fn SignalWaitinfoMask(
976 __set: *const crate::sigset_t,
977 __info: *mut crate::siginfo_t,
978 __mask: *const crate::sigset_t,
979 ) -> c_int;
980 pub fn SignalWaitinfoMask_r(
981 __set: *const crate::sigset_t,
982 __info: *mut crate::siginfo_t,
983 __mask: *const crate::sigset_t,
984 ) -> c_int;
985 pub fn ThreadCreate(
986 __pid: crate::pid_t,
987 __func: unsafe extern "C" fn(__arg: *mut c_void) -> *mut c_void,
988 __arg: *mut c_void,
989 __attr: *const crate::_thread_attr,
990 ) -> c_int;
991 pub fn ThreadCreate_r(
992 __pid: crate::pid_t,
993 __func: unsafe extern "C" fn(__arg: *mut c_void) -> *mut c_void,
994 __arg: *mut c_void,
995 __attr: *const crate::_thread_attr,
996 ) -> c_int;
997
998 pub fn ThreadDestroy(__tid: c_int, __priority: c_int, __status: *mut c_void) -> c_int;
999 pub fn ThreadDestroy_r(__tid: c_int, __priority: c_int, __status: *mut c_void) -> c_int;
1000 pub fn ThreadDetach(__tid: c_int) -> c_int;
1001 pub fn ThreadDetach_r(__tid: c_int) -> c_int;
1002 pub fn ThreadJoin(__tid: c_int, __status: *mut *mut c_void) -> c_int;
1003 pub fn ThreadJoin_r(__tid: c_int, __status: *mut *mut c_void) -> c_int;
1004 pub fn ThreadCancel(__tid: c_int, __canstub: unsafe extern "C" fn()) -> c_int;
1005 pub fn ThreadCancel_r(__tid: c_int, __canstub: unsafe extern "C" fn()) -> c_int;
1006 pub fn ThreadCtl(__cmd: c_int, __data: *mut c_void) -> c_int;
1007 pub fn ThreadCtl_r(__cmd: c_int, __data: *mut c_void) -> c_int;
1008 pub fn ThreadCtlExt(
1009 __pid: crate::pid_t,
1010 __tid: c_int,
1011 __cmd: c_int,
1012 __data: *mut c_void,
1013 ) -> c_int;
1014 pub fn ThreadCtlExt_r(
1015 __pid: crate::pid_t,
1016 __tid: c_int,
1017 __cmd: c_int,
1018 __data: *mut c_void,
1019 ) -> c_int;
1020
1021 pub fn InterruptHookTrace(
1022 __handler: Option<unsafe extern "C" fn(arg1: c_int) -> *const crate::sigevent>,
1023 __flags: c_uint,
1024 ) -> c_int;
1025 pub fn InterruptHookIdle(
1026 __handler: Option<unsafe extern "C" fn(arg1: *mut u64, arg2: *mut qtime_entry)>,
1027 __flags: c_uint,
1028 ) -> c_int;
1029 pub fn InterruptHookIdle2(
1030 __handler: Option<
1031 unsafe extern "C" fn(arg1: c_uint, arg2: *mut syspage_entry, arg3: *mut _idle_hook),
1032 >,
1033 __flags: c_uint,
1034 ) -> c_int;
1035 pub fn InterruptHookOverdriveEvent(__event: *const crate::sigevent, __flags: c_uint) -> c_int;
1036 pub fn InterruptAttachEvent(
1037 __intr: c_int,
1038 __event: *const crate::sigevent,
1039 __flags: c_uint,
1040 ) -> c_int;
1041 pub fn InterruptAttachEvent_r(
1042 __intr: c_int,
1043 __event: *const crate::sigevent,
1044 __flags: c_uint,
1045 ) -> c_int;
1046 pub fn InterruptAttach(
1047 __intr: c_int,
1048 __handler: Option<
1049 unsafe extern "C" fn(__area: *mut c_void, __id: c_int) -> *const crate::sigevent,
1050 >,
1051 __area: *const c_void,
1052 __size: c_int,
1053 __flags: c_uint,
1054 ) -> c_int;
1055 pub fn InterruptAttach_r(
1056 __intr: c_int,
1057 __handler: Option<
1058 unsafe extern "C" fn(__area: *mut c_void, __id: c_int) -> *const crate::sigevent,
1059 >,
1060 __area: *const c_void,
1061 __size: c_int,
1062 __flags: c_uint,
1063 ) -> c_int;
1064 pub fn InterruptAttachArray(
1065 __intr: c_int,
1066 __handler: Option<
1067 unsafe extern "C" fn(__area: *mut c_void, __id: c_int) -> *const *const crate::sigevent,
1068 >,
1069 __area: *const c_void,
1070 __size: c_int,
1071 __flags: c_uint,
1072 ) -> c_int;
1073 pub fn InterruptAttachArray_r(
1074 __intr: c_int,
1075 __handler: Option<
1076 unsafe extern "C" fn(__area: *mut c_void, __id: c_int) -> *const *const crate::sigevent,
1077 >,
1078 __area: *const c_void,
1079 __size: c_int,
1080 __flags: c_uint,
1081 ) -> c_int;
1082 pub fn InterruptDetach(__id: c_int) -> c_int;
1083 pub fn InterruptDetach_r(__id: c_int) -> c_int;
1084 pub fn InterruptWait(__flags: c_int, __timeout: *const u64) -> c_int;
1085 pub fn InterruptWait_r(__flags: c_int, __timeout: *const u64) -> c_int;
1086 pub fn InterruptCharacteristic(
1087 __type: c_int,
1088 __id: c_int,
1089 __new: *mut c_uint,
1090 __old: *mut c_uint,
1091 ) -> c_int;
1092 pub fn InterruptCharacteristic_r(
1093 __type: c_int,
1094 __id: c_int,
1095 __new: *mut c_uint,
1096 __old: *mut c_uint,
1097 ) -> c_int;
1098
1099 pub fn SchedGet(__pid: crate::pid_t, __tid: c_int, __param: *mut crate::sched_param) -> c_int;
1100 pub fn SchedGet_r(__pid: crate::pid_t, __tid: c_int, __param: *mut crate::sched_param)
1101 -> c_int;
1102 pub fn SchedGetCpuNum() -> c_uint;
1103 pub fn SchedSet(
1104 __pid: crate::pid_t,
1105 __tid: c_int,
1106 __algorithm: c_int,
1107 __param: *const crate::sched_param,
1108 ) -> c_int;
1109 pub fn SchedSet_r(
1110 __pid: crate::pid_t,
1111 __tid: c_int,
1112 __algorithm: c_int,
1113 __param: *const crate::sched_param,
1114 ) -> c_int;
1115 pub fn SchedInfo(
1116 __pid: crate::pid_t,
1117 __algorithm: c_int,
1118 __info: *mut crate::_sched_info,
1119 ) -> c_int;
1120 pub fn SchedInfo_r(
1121 __pid: crate::pid_t,
1122 __algorithm: c_int,
1123 __info: *mut crate::_sched_info,
1124 ) -> c_int;
1125 pub fn SchedYield() -> c_int;
1126 pub fn SchedYield_r() -> c_int;
1127 pub fn SchedCtl(__cmd: c_int, __data: *mut c_void, __length: usize) -> c_int;
1128 pub fn SchedCtl_r(__cmd: c_int, __data: *mut c_void, __length: usize) -> c_int;
1129 pub fn SchedJobCreate(__job: *mut nto_job_t) -> c_int;
1130 pub fn SchedJobCreate_r(__job: *mut nto_job_t) -> c_int;
1131 pub fn SchedJobDestroy(__job: *mut nto_job_t) -> c_int;
1132 pub fn SchedJobDestroy_r(__job: *mut nto_job_t) -> c_int;
1133 pub fn SchedWaypoint(
1134 __job: *mut nto_job_t,
1135 __new: *const i64,
1136 __max: *const i64,
1137 __old: *mut i64,
1138 ) -> c_int;
1139 pub fn SchedWaypoint_r(
1140 __job: *mut nto_job_t,
1141 __new: *const i64,
1142 __max: *const i64,
1143 __old: *mut i64,
1144 ) -> c_int;
1145
1146 pub fn TimerCreate(__id: crate::clockid_t, __notify: *const crate::sigevent) -> c_int;
1147 pub fn TimerCreate_r(__id: crate::clockid_t, __notify: *const crate::sigevent) -> c_int;
1148 pub fn TimerDestroy(__id: crate::timer_t) -> c_int;
1149 pub fn TimerDestroy_r(__id: crate::timer_t) -> c_int;
1150 pub fn TimerSettime(
1151 __id: crate::timer_t,
1152 __flags: c_int,
1153 __itime: *const crate::_itimer,
1154 __oitime: *mut crate::_itimer,
1155 ) -> c_int;
1156 pub fn TimerSettime_r(
1157 __id: crate::timer_t,
1158 __flags: c_int,
1159 __itime: *const crate::_itimer,
1160 __oitime: *mut crate::_itimer,
1161 ) -> c_int;
1162 pub fn TimerInfo(
1163 __pid: crate::pid_t,
1164 __id: crate::timer_t,
1165 __flags: c_int,
1166 __info: *mut crate::_timer_info,
1167 ) -> c_int;
1168 pub fn TimerInfo_r(
1169 __pid: crate::pid_t,
1170 __id: crate::timer_t,
1171 __flags: c_int,
1172 __info: *mut crate::_timer_info,
1173 ) -> c_int;
1174 pub fn TimerAlarm(
1175 __id: crate::clockid_t,
1176 __itime: *const crate::_itimer,
1177 __otime: *mut crate::_itimer,
1178 ) -> c_int;
1179 pub fn TimerAlarm_r(
1180 __id: crate::clockid_t,
1181 __itime: *const crate::_itimer,
1182 __otime: *mut crate::_itimer,
1183 ) -> c_int;
1184 pub fn TimerTimeout(
1185 __id: crate::clockid_t,
1186 __flags: c_int,
1187 __notify: *const crate::sigevent,
1188 __ntime: *const u64,
1189 __otime: *mut u64,
1190 ) -> c_int;
1191 pub fn TimerTimeout_r(
1192 __id: crate::clockid_t,
1193 __flags: c_int,
1194 __notify: *const crate::sigevent,
1195 __ntime: *const u64,
1196 __otime: *mut u64,
1197 ) -> c_int;
1198
1199 pub fn SyncTypeCreate(
1200 __type: c_uint,
1201 __sync: *mut crate::sync_t,
1202 __attr: *const crate::_sync_attr,
1203 ) -> c_int;
1204 pub fn SyncTypeCreate_r(
1205 __type: c_uint,
1206 __sync: *mut crate::sync_t,
1207 __attr: *const crate::_sync_attr,
1208 ) -> c_int;
1209 pub fn SyncDestroy(__sync: *mut crate::sync_t) -> c_int;
1210 pub fn SyncDestroy_r(__sync: *mut crate::sync_t) -> c_int;
1211 pub fn SyncCtl(__cmd: c_int, __sync: *mut crate::sync_t, __data: *mut c_void) -> c_int;
1212 pub fn SyncCtl_r(__cmd: c_int, __sync: *mut crate::sync_t, __data: *mut c_void) -> c_int;
1213 pub fn SyncMutexEvent(__sync: *mut crate::sync_t, event: *const crate::sigevent) -> c_int;
1214 pub fn SyncMutexEvent_r(__sync: *mut crate::sync_t, event: *const crate::sigevent) -> c_int;
1215 pub fn SyncMutexLock(__sync: *mut crate::sync_t) -> c_int;
1216 pub fn SyncMutexLock_r(__sync: *mut crate::sync_t) -> c_int;
1217 pub fn SyncMutexUnlock(__sync: *mut crate::sync_t) -> c_int;
1218 pub fn SyncMutexUnlock_r(__sync: *mut crate::sync_t) -> c_int;
1219 pub fn SyncMutexRevive(__sync: *mut crate::sync_t) -> c_int;
1220 pub fn SyncMutexRevive_r(__sync: *mut crate::sync_t) -> c_int;
1221 pub fn SyncCondvarWait(__sync: *mut crate::sync_t, __mutex: *mut crate::sync_t) -> c_int;
1222 pub fn SyncCondvarWait_r(__sync: *mut crate::sync_t, __mutex: *mut crate::sync_t) -> c_int;
1223 pub fn SyncCondvarSignal(__sync: *mut crate::sync_t, __all: c_int) -> c_int;
1224 pub fn SyncCondvarSignal_r(__sync: *mut crate::sync_t, __all: c_int) -> c_int;
1225 pub fn SyncSemPost(__sync: *mut crate::sync_t) -> c_int;
1226 pub fn SyncSemPost_r(__sync: *mut crate::sync_t) -> c_int;
1227 pub fn SyncSemWait(__sync: *mut crate::sync_t, __tryto: c_int) -> c_int;
1228 pub fn SyncSemWait_r(__sync: *mut crate::sync_t, __tryto: c_int) -> c_int;
1229
1230 pub fn ClockTime(__id: crate::clockid_t, _new: *const u64, __old: *mut u64) -> c_int;
1231 pub fn ClockTime_r(__id: crate::clockid_t, _new: *const u64, __old: *mut u64) -> c_int;
1232 pub fn ClockAdjust(
1233 __id: crate::clockid_t,
1234 _new: *const crate::_clockadjust,
1235 __old: *mut crate::_clockadjust,
1236 ) -> c_int;
1237 pub fn ClockAdjust_r(
1238 __id: crate::clockid_t,
1239 _new: *const crate::_clockadjust,
1240 __old: *mut crate::_clockadjust,
1241 ) -> c_int;
1242 pub fn ClockPeriod(
1243 __id: crate::clockid_t,
1244 _new: *const crate::_clockperiod,
1245 __old: *mut crate::_clockperiod,
1246 __reserved: c_int,
1247 ) -> c_int;
1248 pub fn ClockPeriod_r(
1249 __id: crate::clockid_t,
1250 _new: *const crate::_clockperiod,
1251 __old: *mut crate::_clockperiod,
1252 __reserved: c_int,
1253 ) -> c_int;
1254 pub fn ClockId(__pid: crate::pid_t, __tid: c_int) -> c_int;
1255 pub fn ClockId_r(__pid: crate::pid_t, __tid: c_int) -> c_int;
1256
1257 //
1258 //TODO: The following commented out functions are implemented in assembly.
1259 // We can implmement them either via a C stub or rust's inline assembly.
1260 //
1261 //pub fn InterruptEnable();
1262 //pub fn InterruptDisable();
1263 pub fn InterruptMask(__intr: c_int, __id: c_int) -> c_int;
1264 pub fn InterruptUnmask(__intr: c_int, __id: c_int) -> c_int;
1265 //pub fn InterruptLock(__spin: *mut intrspin);
1266 //pub fn InterruptUnlock(__spin: *mut intrspin);
1267 //pub fn InterruptStatus() -> c_uint;
1268 }