rump_syscalls.c revision 1.155 1 1.148 thorpej /* $NetBSD: rump_syscalls.c,v 1.155 2020/11/02 18:56:16 christos Exp $ */
2 1.1 pooka
3 1.1 pooka /*
4 1.29 pooka * System call vector and marshalling for rump.
5 1.1 pooka *
6 1.1 pooka * DO NOT EDIT-- this file is automatically generated.
7 1.155 christos * created from NetBSD: syscalls.master,v 1.307 2020/11/02 18:55:12 christos Exp
8 1.1 pooka */
9 1.1 pooka
10 1.85 pooka #ifdef RUMP_CLIENT
11 1.91 pooka #include <rump/rumpuser_port.h>
12 1.85 pooka #endif /* RUMP_CLIENT */
13 1.85 pooka
14 1.81 pooka #include <sys/param.h>
15 1.81 pooka
16 1.81 pooka #ifdef __NetBSD__
17 1.1 pooka #include <sys/cdefs.h>
18 1.148 thorpej __KERNEL_RCSID(0, "$NetBSD: rump_syscalls.c,v 1.155 2020/11/02 18:56:16 christos Exp $");
19 1.1 pooka
20 1.53 pooka #include <sys/fstypes.h>
21 1.1 pooka #include <sys/proc.h>
22 1.81 pooka #endif /* __NetBSD__ */
23 1.81 pooka
24 1.71 pooka #ifdef RUMP_CLIENT
25 1.81 pooka #include <errno.h>
26 1.81 pooka #include <stdint.h>
27 1.81 pooka #include <stdlib.h>
28 1.96 pooka #include <string.h>
29 1.81 pooka
30 1.71 pooka #include <srcsys/syscall.h>
31 1.71 pooka #include <srcsys/syscallargs.h>
32 1.53 pooka
33 1.53 pooka #include <rump/rumpclient.h>
34 1.53 pooka
35 1.53 pooka #define rsys_syscall(num, data, dlen, retval) \
36 1.53 pooka rumpclient_syscall(num, data, dlen, retval)
37 1.53 pooka #define rsys_seterrno(error) errno = error
38 1.53 pooka #else
39 1.71 pooka #include <sys/syscall.h>
40 1.71 pooka #include <sys/syscallargs.h>
41 1.71 pooka
42 1.55 pooka #include <sys/syscallvar.h>
43 1.55 pooka
44 1.122 pooka #include <rump-sys/kern.h>
45 1.122 pooka
46 1.27 pooka #include <rump/rumpuser.h>
47 1.90 pooka #define rsys_syscall(num, data, dlen, retval) \
48 1.90 pooka rump_syscall(num, data, dlen, retval)
49 1.90 pooka
50 1.90 pooka #define rsys_seterrno(error) rumpuser_seterrno(error)
51 1.86 pooka #endif
52 1.55 pooka
53 1.103 pooka #ifndef RUMP_KERNEL_IS_LIBC
54 1.103 pooka #define RUMP_SYS_COMPAT
55 1.53 pooka #endif
56 1.53 pooka
57 1.1 pooka #if BYTE_ORDER == BIG_ENDIAN
58 1.1 pooka #define SPARG(p,k) ((p)->k.be.datum)
59 1.1 pooka #else /* LITTLE_ENDIAN, I hope dearly */
60 1.1 pooka #define SPARG(p,k) ((p)->k.le.datum)
61 1.1 pooka #endif
62 1.1 pooka
63 1.16 pooka
64 1.90 pooka void rumpns_sys_nomodule(void);
65 1.90 pooka
66 1.60 pooka ssize_t rump___sysimpl_read(int, void *, size_t);
67 1.1 pooka ssize_t
68 1.60 pooka rump___sysimpl_read(int fd, void * buf, size_t nbyte)
69 1.1 pooka {
70 1.93 pooka register_t retval[2];
71 1.27 pooka int error = 0;
72 1.68 pooka ssize_t rv = -1;
73 1.31 pooka struct sys_read_args callarg;
74 1.1 pooka
75 1.95 pooka memset(&callarg, 0, sizeof(callarg));
76 1.31 pooka SPARG(&callarg, fd) = fd;
77 1.31 pooka SPARG(&callarg, buf) = buf;
78 1.31 pooka SPARG(&callarg, nbyte) = nbyte;
79 1.1 pooka
80 1.120 pgoyette error = rsys_syscall(SYS_read, &callarg, sizeof(callarg), retval);
81 1.63 pooka rsys_seterrno(error);
82 1.68 pooka if (error == 0) {
83 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
84 1.68 pooka rv = *(ssize_t *)retval;
85 1.68 pooka else
86 1.69 pooka rv = *retval;
87 1.27 pooka }
88 1.68 pooka return rv;
89 1.1 pooka }
90 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
91 1.103 pooka __weak_alias(read,rump___sysimpl_read);
92 1.103 pooka __weak_alias(_read,rump___sysimpl_read);
93 1.103 pooka __strong_alias(_sys_read,rump___sysimpl_read);
94 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
95 1.1 pooka
96 1.60 pooka ssize_t rump___sysimpl_write(int, const void *, size_t);
97 1.1 pooka ssize_t
98 1.60 pooka rump___sysimpl_write(int fd, const void * buf, size_t nbyte)
99 1.1 pooka {
100 1.93 pooka register_t retval[2];
101 1.27 pooka int error = 0;
102 1.68 pooka ssize_t rv = -1;
103 1.31 pooka struct sys_write_args callarg;
104 1.1 pooka
105 1.95 pooka memset(&callarg, 0, sizeof(callarg));
106 1.31 pooka SPARG(&callarg, fd) = fd;
107 1.31 pooka SPARG(&callarg, buf) = buf;
108 1.31 pooka SPARG(&callarg, nbyte) = nbyte;
109 1.1 pooka
110 1.120 pgoyette error = rsys_syscall(SYS_write, &callarg, sizeof(callarg), retval);
111 1.63 pooka rsys_seterrno(error);
112 1.68 pooka if (error == 0) {
113 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
114 1.68 pooka rv = *(ssize_t *)retval;
115 1.68 pooka else
116 1.69 pooka rv = *retval;
117 1.27 pooka }
118 1.68 pooka return rv;
119 1.1 pooka }
120 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
121 1.103 pooka __weak_alias(write,rump___sysimpl_write);
122 1.103 pooka __weak_alias(_write,rump___sysimpl_write);
123 1.103 pooka __strong_alias(_sys_write,rump___sysimpl_write);
124 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
125 1.1 pooka
126 1.60 pooka int rump___sysimpl_open(const char *, int, mode_t);
127 1.1 pooka int
128 1.60 pooka rump___sysimpl_open(const char * path, int flags, mode_t mode)
129 1.1 pooka {
130 1.93 pooka register_t retval[2];
131 1.27 pooka int error = 0;
132 1.68 pooka int rv = -1;
133 1.31 pooka struct sys_open_args callarg;
134 1.1 pooka
135 1.95 pooka memset(&callarg, 0, sizeof(callarg));
136 1.31 pooka SPARG(&callarg, path) = path;
137 1.31 pooka SPARG(&callarg, flags) = flags;
138 1.31 pooka SPARG(&callarg, mode) = mode;
139 1.1 pooka
140 1.120 pgoyette error = rsys_syscall(SYS_open, &callarg, sizeof(callarg), retval);
141 1.63 pooka rsys_seterrno(error);
142 1.68 pooka if (error == 0) {
143 1.68 pooka if (sizeof(int) > sizeof(register_t))
144 1.68 pooka rv = *(int *)retval;
145 1.68 pooka else
146 1.69 pooka rv = *retval;
147 1.27 pooka }
148 1.68 pooka return rv;
149 1.1 pooka }
150 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
151 1.103 pooka __weak_alias(open,rump___sysimpl_open);
152 1.103 pooka __weak_alias(_open,rump___sysimpl_open);
153 1.103 pooka __strong_alias(_sys_open,rump___sysimpl_open);
154 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
155 1.1 pooka
156 1.60 pooka int rump___sysimpl_close(int);
157 1.1 pooka int
158 1.60 pooka rump___sysimpl_close(int fd)
159 1.1 pooka {
160 1.93 pooka register_t retval[2];
161 1.27 pooka int error = 0;
162 1.68 pooka int rv = -1;
163 1.31 pooka struct sys_close_args callarg;
164 1.1 pooka
165 1.95 pooka memset(&callarg, 0, sizeof(callarg));
166 1.31 pooka SPARG(&callarg, fd) = fd;
167 1.1 pooka
168 1.120 pgoyette error = rsys_syscall(SYS_close, &callarg, sizeof(callarg), retval);
169 1.63 pooka rsys_seterrno(error);
170 1.68 pooka if (error == 0) {
171 1.68 pooka if (sizeof(int) > sizeof(register_t))
172 1.68 pooka rv = *(int *)retval;
173 1.68 pooka else
174 1.69 pooka rv = *retval;
175 1.27 pooka }
176 1.68 pooka return rv;
177 1.1 pooka }
178 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
179 1.103 pooka __weak_alias(close,rump___sysimpl_close);
180 1.103 pooka __weak_alias(_close,rump___sysimpl_close);
181 1.103 pooka __strong_alias(_sys_close,rump___sysimpl_close);
182 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
183 1.1 pooka
184 1.60 pooka int rump___sysimpl_link(const char *, const char *);
185 1.1 pooka int
186 1.60 pooka rump___sysimpl_link(const char * path, const char * link)
187 1.1 pooka {
188 1.93 pooka register_t retval[2];
189 1.27 pooka int error = 0;
190 1.68 pooka int rv = -1;
191 1.31 pooka struct sys_link_args callarg;
192 1.1 pooka
193 1.95 pooka memset(&callarg, 0, sizeof(callarg));
194 1.31 pooka SPARG(&callarg, path) = path;
195 1.31 pooka SPARG(&callarg, link) = link;
196 1.1 pooka
197 1.120 pgoyette error = rsys_syscall(SYS_link, &callarg, sizeof(callarg), retval);
198 1.63 pooka rsys_seterrno(error);
199 1.68 pooka if (error == 0) {
200 1.68 pooka if (sizeof(int) > sizeof(register_t))
201 1.68 pooka rv = *(int *)retval;
202 1.68 pooka else
203 1.69 pooka rv = *retval;
204 1.27 pooka }
205 1.68 pooka return rv;
206 1.1 pooka }
207 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
208 1.103 pooka __weak_alias(link,rump___sysimpl_link);
209 1.103 pooka __weak_alias(_link,rump___sysimpl_link);
210 1.103 pooka __strong_alias(_sys_link,rump___sysimpl_link);
211 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
212 1.1 pooka
213 1.60 pooka int rump___sysimpl_unlink(const char *);
214 1.1 pooka int
215 1.60 pooka rump___sysimpl_unlink(const char * path)
216 1.1 pooka {
217 1.93 pooka register_t retval[2];
218 1.27 pooka int error = 0;
219 1.68 pooka int rv = -1;
220 1.31 pooka struct sys_unlink_args callarg;
221 1.1 pooka
222 1.95 pooka memset(&callarg, 0, sizeof(callarg));
223 1.31 pooka SPARG(&callarg, path) = path;
224 1.1 pooka
225 1.120 pgoyette error = rsys_syscall(SYS_unlink, &callarg, sizeof(callarg), retval);
226 1.63 pooka rsys_seterrno(error);
227 1.68 pooka if (error == 0) {
228 1.68 pooka if (sizeof(int) > sizeof(register_t))
229 1.68 pooka rv = *(int *)retval;
230 1.68 pooka else
231 1.69 pooka rv = *retval;
232 1.27 pooka }
233 1.68 pooka return rv;
234 1.1 pooka }
235 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
236 1.103 pooka __weak_alias(unlink,rump___sysimpl_unlink);
237 1.103 pooka __weak_alias(_unlink,rump___sysimpl_unlink);
238 1.103 pooka __strong_alias(_sys_unlink,rump___sysimpl_unlink);
239 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
240 1.1 pooka
241 1.60 pooka int rump___sysimpl_chdir(const char *);
242 1.1 pooka int
243 1.60 pooka rump___sysimpl_chdir(const char * path)
244 1.1 pooka {
245 1.93 pooka register_t retval[2];
246 1.27 pooka int error = 0;
247 1.68 pooka int rv = -1;
248 1.31 pooka struct sys_chdir_args callarg;
249 1.1 pooka
250 1.95 pooka memset(&callarg, 0, sizeof(callarg));
251 1.31 pooka SPARG(&callarg, path) = path;
252 1.1 pooka
253 1.120 pgoyette error = rsys_syscall(SYS_chdir, &callarg, sizeof(callarg), retval);
254 1.63 pooka rsys_seterrno(error);
255 1.68 pooka if (error == 0) {
256 1.68 pooka if (sizeof(int) > sizeof(register_t))
257 1.68 pooka rv = *(int *)retval;
258 1.68 pooka else
259 1.69 pooka rv = *retval;
260 1.27 pooka }
261 1.68 pooka return rv;
262 1.1 pooka }
263 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
264 1.103 pooka __weak_alias(chdir,rump___sysimpl_chdir);
265 1.103 pooka __weak_alias(_chdir,rump___sysimpl_chdir);
266 1.103 pooka __strong_alias(_sys_chdir,rump___sysimpl_chdir);
267 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
268 1.1 pooka
269 1.60 pooka int rump___sysimpl_fchdir(int);
270 1.1 pooka int
271 1.60 pooka rump___sysimpl_fchdir(int fd)
272 1.1 pooka {
273 1.93 pooka register_t retval[2];
274 1.27 pooka int error = 0;
275 1.68 pooka int rv = -1;
276 1.31 pooka struct sys_fchdir_args callarg;
277 1.1 pooka
278 1.95 pooka memset(&callarg, 0, sizeof(callarg));
279 1.31 pooka SPARG(&callarg, fd) = fd;
280 1.1 pooka
281 1.120 pgoyette error = rsys_syscall(SYS_fchdir, &callarg, sizeof(callarg), retval);
282 1.63 pooka rsys_seterrno(error);
283 1.68 pooka if (error == 0) {
284 1.68 pooka if (sizeof(int) > sizeof(register_t))
285 1.68 pooka rv = *(int *)retval;
286 1.68 pooka else
287 1.69 pooka rv = *retval;
288 1.27 pooka }
289 1.68 pooka return rv;
290 1.1 pooka }
291 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
292 1.103 pooka __weak_alias(fchdir,rump___sysimpl_fchdir);
293 1.103 pooka __weak_alias(_fchdir,rump___sysimpl_fchdir);
294 1.103 pooka __strong_alias(_sys_fchdir,rump___sysimpl_fchdir);
295 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
296 1.1 pooka
297 1.103 pooka #ifdef RUMP_SYS_COMPAT
298 1.61 pooka int rump___sysimpl_mknod(const char *, mode_t, uint32_t);
299 1.61 pooka int
300 1.61 pooka rump___sysimpl_mknod(const char * path, mode_t mode, uint32_t dev)
301 1.61 pooka {
302 1.93 pooka register_t retval[2];
303 1.61 pooka int error = 0;
304 1.68 pooka int rv = -1;
305 1.61 pooka struct compat_50_sys_mknod_args callarg;
306 1.61 pooka
307 1.95 pooka memset(&callarg, 0, sizeof(callarg));
308 1.61 pooka SPARG(&callarg, path) = path;
309 1.61 pooka SPARG(&callarg, mode) = mode;
310 1.61 pooka SPARG(&callarg, dev) = dev;
311 1.61 pooka
312 1.120 pgoyette error = rsys_syscall(SYS_compat_50_mknod, &callarg, sizeof(callarg), retval);
313 1.63 pooka rsys_seterrno(error);
314 1.68 pooka if (error == 0) {
315 1.68 pooka if (sizeof(int) > sizeof(register_t))
316 1.68 pooka rv = *(int *)retval;
317 1.68 pooka else
318 1.69 pooka rv = *retval;
319 1.61 pooka }
320 1.68 pooka return rv;
321 1.61 pooka }
322 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
323 1.103 pooka __weak_alias(mknod,rump___sysimpl_mknod);
324 1.103 pooka __weak_alias(_mknod,rump___sysimpl_mknod);
325 1.103 pooka __strong_alias(_sys_mknod,rump___sysimpl_mknod);
326 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
327 1.103 pooka #endif /* RUMP_SYS_COMPAT */
328 1.61 pooka
329 1.60 pooka int rump___sysimpl_chmod(const char *, mode_t);
330 1.1 pooka int
331 1.60 pooka rump___sysimpl_chmod(const char * path, mode_t mode)
332 1.1 pooka {
333 1.93 pooka register_t retval[2];
334 1.27 pooka int error = 0;
335 1.68 pooka int rv = -1;
336 1.31 pooka struct sys_chmod_args callarg;
337 1.1 pooka
338 1.95 pooka memset(&callarg, 0, sizeof(callarg));
339 1.31 pooka SPARG(&callarg, path) = path;
340 1.31 pooka SPARG(&callarg, mode) = mode;
341 1.1 pooka
342 1.120 pgoyette error = rsys_syscall(SYS_chmod, &callarg, sizeof(callarg), retval);
343 1.63 pooka rsys_seterrno(error);
344 1.68 pooka if (error == 0) {
345 1.68 pooka if (sizeof(int) > sizeof(register_t))
346 1.68 pooka rv = *(int *)retval;
347 1.68 pooka else
348 1.69 pooka rv = *retval;
349 1.27 pooka }
350 1.68 pooka return rv;
351 1.1 pooka }
352 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
353 1.103 pooka __weak_alias(chmod,rump___sysimpl_chmod);
354 1.103 pooka __weak_alias(_chmod,rump___sysimpl_chmod);
355 1.103 pooka __strong_alias(_sys_chmod,rump___sysimpl_chmod);
356 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
357 1.1 pooka
358 1.60 pooka int rump___sysimpl_chown(const char *, uid_t, gid_t);
359 1.1 pooka int
360 1.60 pooka rump___sysimpl_chown(const char * path, uid_t uid, gid_t gid)
361 1.1 pooka {
362 1.93 pooka register_t retval[2];
363 1.27 pooka int error = 0;
364 1.68 pooka int rv = -1;
365 1.31 pooka struct sys_chown_args callarg;
366 1.1 pooka
367 1.95 pooka memset(&callarg, 0, sizeof(callarg));
368 1.31 pooka SPARG(&callarg, path) = path;
369 1.31 pooka SPARG(&callarg, uid) = uid;
370 1.31 pooka SPARG(&callarg, gid) = gid;
371 1.1 pooka
372 1.120 pgoyette error = rsys_syscall(SYS_chown, &callarg, sizeof(callarg), retval);
373 1.63 pooka rsys_seterrno(error);
374 1.68 pooka if (error == 0) {
375 1.68 pooka if (sizeof(int) > sizeof(register_t))
376 1.68 pooka rv = *(int *)retval;
377 1.68 pooka else
378 1.69 pooka rv = *retval;
379 1.27 pooka }
380 1.68 pooka return rv;
381 1.1 pooka }
382 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
383 1.103 pooka __weak_alias(chown,rump___sysimpl_chown);
384 1.103 pooka __weak_alias(_chown,rump___sysimpl_chown);
385 1.103 pooka __strong_alias(_sys_chown,rump___sysimpl_chown);
386 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
387 1.1 pooka
388 1.60 pooka pid_t rump___sysimpl_getpid(void);
389 1.49 pooka pid_t
390 1.60 pooka rump___sysimpl_getpid(void )
391 1.49 pooka {
392 1.93 pooka register_t retval[2];
393 1.68 pooka pid_t rv = -1;
394 1.49 pooka
395 1.119 pgoyette (void)rsys_syscall(SYS_getpid, NULL, 0, retval);
396 1.68 pooka if (sizeof(pid_t) > sizeof(register_t))
397 1.68 pooka rv = *(pid_t *)retval;
398 1.68 pooka else
399 1.69 pooka rv = *retval;
400 1.68 pooka return rv;
401 1.49 pooka }
402 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
403 1.103 pooka __weak_alias(getpid,rump___sysimpl_getpid);
404 1.103 pooka __weak_alias(_getpid,rump___sysimpl_getpid);
405 1.103 pooka __strong_alias(_sys_getpid,rump___sysimpl_getpid);
406 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
407 1.49 pooka
408 1.60 pooka int rump___sysimpl_unmount(const char *, int);
409 1.1 pooka int
410 1.60 pooka rump___sysimpl_unmount(const char * path, int flags)
411 1.1 pooka {
412 1.93 pooka register_t retval[2];
413 1.27 pooka int error = 0;
414 1.68 pooka int rv = -1;
415 1.31 pooka struct sys_unmount_args callarg;
416 1.1 pooka
417 1.95 pooka memset(&callarg, 0, sizeof(callarg));
418 1.31 pooka SPARG(&callarg, path) = path;
419 1.31 pooka SPARG(&callarg, flags) = flags;
420 1.1 pooka
421 1.120 pgoyette error = rsys_syscall(SYS_unmount, &callarg, sizeof(callarg), retval);
422 1.63 pooka rsys_seterrno(error);
423 1.68 pooka if (error == 0) {
424 1.68 pooka if (sizeof(int) > sizeof(register_t))
425 1.68 pooka rv = *(int *)retval;
426 1.68 pooka else
427 1.69 pooka rv = *retval;
428 1.27 pooka }
429 1.68 pooka return rv;
430 1.1 pooka }
431 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
432 1.103 pooka __weak_alias(unmount,rump___sysimpl_unmount);
433 1.103 pooka __weak_alias(_unmount,rump___sysimpl_unmount);
434 1.103 pooka __strong_alias(_sys_unmount,rump___sysimpl_unmount);
435 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
436 1.1 pooka
437 1.60 pooka int rump___sysimpl_setuid(uid_t);
438 1.49 pooka int
439 1.60 pooka rump___sysimpl_setuid(uid_t uid)
440 1.49 pooka {
441 1.93 pooka register_t retval[2];
442 1.49 pooka int error = 0;
443 1.68 pooka int rv = -1;
444 1.49 pooka struct sys_setuid_args callarg;
445 1.49 pooka
446 1.95 pooka memset(&callarg, 0, sizeof(callarg));
447 1.49 pooka SPARG(&callarg, uid) = uid;
448 1.49 pooka
449 1.120 pgoyette error = rsys_syscall(SYS_setuid, &callarg, sizeof(callarg), retval);
450 1.63 pooka rsys_seterrno(error);
451 1.68 pooka if (error == 0) {
452 1.68 pooka if (sizeof(int) > sizeof(register_t))
453 1.68 pooka rv = *(int *)retval;
454 1.68 pooka else
455 1.69 pooka rv = *retval;
456 1.49 pooka }
457 1.68 pooka return rv;
458 1.49 pooka }
459 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
460 1.103 pooka __weak_alias(setuid,rump___sysimpl_setuid);
461 1.103 pooka __weak_alias(_setuid,rump___sysimpl_setuid);
462 1.103 pooka __strong_alias(_sys_setuid,rump___sysimpl_setuid);
463 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
464 1.49 pooka
465 1.60 pooka uid_t rump___sysimpl_getuid(void);
466 1.49 pooka uid_t
467 1.60 pooka rump___sysimpl_getuid(void )
468 1.49 pooka {
469 1.93 pooka register_t retval[2];
470 1.68 pooka uid_t rv = -1;
471 1.49 pooka
472 1.119 pgoyette (void)rsys_syscall(SYS_getuid, NULL, 0, retval);
473 1.68 pooka if (sizeof(uid_t) > sizeof(register_t))
474 1.68 pooka rv = *(uid_t *)retval;
475 1.68 pooka else
476 1.69 pooka rv = *retval;
477 1.68 pooka return rv;
478 1.49 pooka }
479 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
480 1.103 pooka __weak_alias(getuid,rump___sysimpl_getuid);
481 1.103 pooka __weak_alias(_getuid,rump___sysimpl_getuid);
482 1.103 pooka __strong_alias(_sys_getuid,rump___sysimpl_getuid);
483 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
484 1.49 pooka
485 1.60 pooka uid_t rump___sysimpl_geteuid(void);
486 1.49 pooka uid_t
487 1.60 pooka rump___sysimpl_geteuid(void )
488 1.49 pooka {
489 1.93 pooka register_t retval[2];
490 1.68 pooka uid_t rv = -1;
491 1.49 pooka
492 1.119 pgoyette (void)rsys_syscall(SYS_geteuid, NULL, 0, retval);
493 1.68 pooka if (sizeof(uid_t) > sizeof(register_t))
494 1.68 pooka rv = *(uid_t *)retval;
495 1.68 pooka else
496 1.69 pooka rv = *retval;
497 1.68 pooka return rv;
498 1.49 pooka }
499 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
500 1.103 pooka __weak_alias(geteuid,rump___sysimpl_geteuid);
501 1.103 pooka __weak_alias(_geteuid,rump___sysimpl_geteuid);
502 1.103 pooka __strong_alias(_sys_geteuid,rump___sysimpl_geteuid);
503 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
504 1.49 pooka
505 1.60 pooka ssize_t rump___sysimpl_recvmsg(int, struct msghdr *, int);
506 1.28 pooka ssize_t
507 1.60 pooka rump___sysimpl_recvmsg(int s, struct msghdr * msg, int flags)
508 1.28 pooka {
509 1.93 pooka register_t retval[2];
510 1.28 pooka int error = 0;
511 1.68 pooka ssize_t rv = -1;
512 1.31 pooka struct sys_recvmsg_args callarg;
513 1.28 pooka
514 1.95 pooka memset(&callarg, 0, sizeof(callarg));
515 1.31 pooka SPARG(&callarg, s) = s;
516 1.31 pooka SPARG(&callarg, msg) = msg;
517 1.31 pooka SPARG(&callarg, flags) = flags;
518 1.28 pooka
519 1.120 pgoyette error = rsys_syscall(SYS_recvmsg, &callarg, sizeof(callarg), retval);
520 1.63 pooka rsys_seterrno(error);
521 1.68 pooka if (error == 0) {
522 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
523 1.68 pooka rv = *(ssize_t *)retval;
524 1.68 pooka else
525 1.69 pooka rv = *retval;
526 1.28 pooka }
527 1.68 pooka return rv;
528 1.28 pooka }
529 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
530 1.103 pooka __weak_alias(recvmsg,rump___sysimpl_recvmsg);
531 1.103 pooka __weak_alias(_recvmsg,rump___sysimpl_recvmsg);
532 1.103 pooka __strong_alias(_sys_recvmsg,rump___sysimpl_recvmsg);
533 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
534 1.28 pooka
535 1.60 pooka ssize_t rump___sysimpl_sendmsg(int, const struct msghdr *, int);
536 1.28 pooka ssize_t
537 1.60 pooka rump___sysimpl_sendmsg(int s, const struct msghdr * msg, int flags)
538 1.28 pooka {
539 1.93 pooka register_t retval[2];
540 1.28 pooka int error = 0;
541 1.68 pooka ssize_t rv = -1;
542 1.31 pooka struct sys_sendmsg_args callarg;
543 1.28 pooka
544 1.95 pooka memset(&callarg, 0, sizeof(callarg));
545 1.31 pooka SPARG(&callarg, s) = s;
546 1.31 pooka SPARG(&callarg, msg) = msg;
547 1.31 pooka SPARG(&callarg, flags) = flags;
548 1.28 pooka
549 1.120 pgoyette error = rsys_syscall(SYS_sendmsg, &callarg, sizeof(callarg), retval);
550 1.63 pooka rsys_seterrno(error);
551 1.68 pooka if (error == 0) {
552 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
553 1.68 pooka rv = *(ssize_t *)retval;
554 1.68 pooka else
555 1.69 pooka rv = *retval;
556 1.28 pooka }
557 1.68 pooka return rv;
558 1.28 pooka }
559 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
560 1.103 pooka __weak_alias(sendmsg,rump___sysimpl_sendmsg);
561 1.103 pooka __weak_alias(_sendmsg,rump___sysimpl_sendmsg);
562 1.103 pooka __strong_alias(_sys_sendmsg,rump___sysimpl_sendmsg);
563 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
564 1.28 pooka
565 1.72 christos ssize_t rump___sysimpl_recvfrom(int, void *, size_t, int, struct sockaddr *, socklen_t *);
566 1.28 pooka ssize_t
567 1.72 christos rump___sysimpl_recvfrom(int s, void * buf, size_t len, int flags, struct sockaddr * from, socklen_t * fromlenaddr)
568 1.28 pooka {
569 1.93 pooka register_t retval[2];
570 1.28 pooka int error = 0;
571 1.68 pooka ssize_t rv = -1;
572 1.31 pooka struct sys_recvfrom_args callarg;
573 1.28 pooka
574 1.95 pooka memset(&callarg, 0, sizeof(callarg));
575 1.31 pooka SPARG(&callarg, s) = s;
576 1.31 pooka SPARG(&callarg, buf) = buf;
577 1.31 pooka SPARG(&callarg, len) = len;
578 1.31 pooka SPARG(&callarg, flags) = flags;
579 1.31 pooka SPARG(&callarg, from) = from;
580 1.31 pooka SPARG(&callarg, fromlenaddr) = fromlenaddr;
581 1.28 pooka
582 1.120 pgoyette error = rsys_syscall(SYS_recvfrom, &callarg, sizeof(callarg), retval);
583 1.63 pooka rsys_seterrno(error);
584 1.68 pooka if (error == 0) {
585 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
586 1.68 pooka rv = *(ssize_t *)retval;
587 1.68 pooka else
588 1.69 pooka rv = *retval;
589 1.28 pooka }
590 1.68 pooka return rv;
591 1.28 pooka }
592 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
593 1.103 pooka __weak_alias(recvfrom,rump___sysimpl_recvfrom);
594 1.103 pooka __weak_alias(_recvfrom,rump___sysimpl_recvfrom);
595 1.103 pooka __strong_alias(_sys_recvfrom,rump___sysimpl_recvfrom);
596 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
597 1.28 pooka
598 1.72 christos int rump___sysimpl_accept(int, struct sockaddr *, socklen_t *);
599 1.1 pooka int
600 1.72 christos rump___sysimpl_accept(int s, struct sockaddr * name, socklen_t * anamelen)
601 1.22 pooka {
602 1.93 pooka register_t retval[2];
603 1.27 pooka int error = 0;
604 1.68 pooka int rv = -1;
605 1.31 pooka struct sys_accept_args callarg;
606 1.22 pooka
607 1.95 pooka memset(&callarg, 0, sizeof(callarg));
608 1.31 pooka SPARG(&callarg, s) = s;
609 1.31 pooka SPARG(&callarg, name) = name;
610 1.31 pooka SPARG(&callarg, anamelen) = anamelen;
611 1.22 pooka
612 1.120 pgoyette error = rsys_syscall(SYS_accept, &callarg, sizeof(callarg), retval);
613 1.63 pooka rsys_seterrno(error);
614 1.68 pooka if (error == 0) {
615 1.68 pooka if (sizeof(int) > sizeof(register_t))
616 1.68 pooka rv = *(int *)retval;
617 1.68 pooka else
618 1.69 pooka rv = *retval;
619 1.27 pooka }
620 1.68 pooka return rv;
621 1.22 pooka }
622 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
623 1.103 pooka __weak_alias(accept,rump___sysimpl_accept);
624 1.103 pooka __weak_alias(_accept,rump___sysimpl_accept);
625 1.103 pooka __strong_alias(_sys_accept,rump___sysimpl_accept);
626 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
627 1.22 pooka
628 1.72 christos int rump___sysimpl_getpeername(int, struct sockaddr *, socklen_t *);
629 1.28 pooka int
630 1.72 christos rump___sysimpl_getpeername(int fdes, struct sockaddr * asa, socklen_t * alen)
631 1.28 pooka {
632 1.93 pooka register_t retval[2];
633 1.28 pooka int error = 0;
634 1.68 pooka int rv = -1;
635 1.31 pooka struct sys_getpeername_args callarg;
636 1.28 pooka
637 1.95 pooka memset(&callarg, 0, sizeof(callarg));
638 1.31 pooka SPARG(&callarg, fdes) = fdes;
639 1.31 pooka SPARG(&callarg, asa) = asa;
640 1.31 pooka SPARG(&callarg, alen) = alen;
641 1.28 pooka
642 1.120 pgoyette error = rsys_syscall(SYS_getpeername, &callarg, sizeof(callarg), retval);
643 1.63 pooka rsys_seterrno(error);
644 1.68 pooka if (error == 0) {
645 1.68 pooka if (sizeof(int) > sizeof(register_t))
646 1.68 pooka rv = *(int *)retval;
647 1.68 pooka else
648 1.69 pooka rv = *retval;
649 1.28 pooka }
650 1.68 pooka return rv;
651 1.28 pooka }
652 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
653 1.103 pooka __weak_alias(getpeername,rump___sysimpl_getpeername);
654 1.103 pooka __weak_alias(_getpeername,rump___sysimpl_getpeername);
655 1.103 pooka __strong_alias(_sys_getpeername,rump___sysimpl_getpeername);
656 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
657 1.28 pooka
658 1.72 christos int rump___sysimpl_getsockname(int, struct sockaddr *, socklen_t *);
659 1.28 pooka int
660 1.72 christos rump___sysimpl_getsockname(int fdes, struct sockaddr * asa, socklen_t * alen)
661 1.28 pooka {
662 1.93 pooka register_t retval[2];
663 1.28 pooka int error = 0;
664 1.68 pooka int rv = -1;
665 1.31 pooka struct sys_getsockname_args callarg;
666 1.28 pooka
667 1.95 pooka memset(&callarg, 0, sizeof(callarg));
668 1.31 pooka SPARG(&callarg, fdes) = fdes;
669 1.31 pooka SPARG(&callarg, asa) = asa;
670 1.31 pooka SPARG(&callarg, alen) = alen;
671 1.28 pooka
672 1.120 pgoyette error = rsys_syscall(SYS_getsockname, &callarg, sizeof(callarg), retval);
673 1.63 pooka rsys_seterrno(error);
674 1.68 pooka if (error == 0) {
675 1.68 pooka if (sizeof(int) > sizeof(register_t))
676 1.68 pooka rv = *(int *)retval;
677 1.68 pooka else
678 1.69 pooka rv = *retval;
679 1.28 pooka }
680 1.68 pooka return rv;
681 1.28 pooka }
682 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
683 1.103 pooka __weak_alias(getsockname,rump___sysimpl_getsockname);
684 1.103 pooka __weak_alias(_getsockname,rump___sysimpl_getsockname);
685 1.103 pooka __strong_alias(_sys_getsockname,rump___sysimpl_getsockname);
686 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
687 1.28 pooka
688 1.60 pooka int rump___sysimpl_access(const char *, int);
689 1.34 pooka int
690 1.60 pooka rump___sysimpl_access(const char * path, int flags)
691 1.34 pooka {
692 1.93 pooka register_t retval[2];
693 1.34 pooka int error = 0;
694 1.68 pooka int rv = -1;
695 1.34 pooka struct sys_access_args callarg;
696 1.34 pooka
697 1.95 pooka memset(&callarg, 0, sizeof(callarg));
698 1.34 pooka SPARG(&callarg, path) = path;
699 1.34 pooka SPARG(&callarg, flags) = flags;
700 1.34 pooka
701 1.120 pgoyette error = rsys_syscall(SYS_access, &callarg, sizeof(callarg), retval);
702 1.63 pooka rsys_seterrno(error);
703 1.68 pooka if (error == 0) {
704 1.68 pooka if (sizeof(int) > sizeof(register_t))
705 1.68 pooka rv = *(int *)retval;
706 1.68 pooka else
707 1.69 pooka rv = *retval;
708 1.34 pooka }
709 1.68 pooka return rv;
710 1.34 pooka }
711 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
712 1.103 pooka __weak_alias(access,rump___sysimpl_access);
713 1.103 pooka __weak_alias(_access,rump___sysimpl_access);
714 1.103 pooka __strong_alias(_sys_access,rump___sysimpl_access);
715 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
716 1.34 pooka
717 1.60 pooka int rump___sysimpl_chflags(const char *, u_long);
718 1.22 pooka int
719 1.60 pooka rump___sysimpl_chflags(const char * path, u_long flags)
720 1.1 pooka {
721 1.93 pooka register_t retval[2];
722 1.27 pooka int error = 0;
723 1.68 pooka int rv = -1;
724 1.31 pooka struct sys_chflags_args callarg;
725 1.1 pooka
726 1.95 pooka memset(&callarg, 0, sizeof(callarg));
727 1.31 pooka SPARG(&callarg, path) = path;
728 1.31 pooka SPARG(&callarg, flags) = flags;
729 1.1 pooka
730 1.120 pgoyette error = rsys_syscall(SYS_chflags, &callarg, sizeof(callarg), retval);
731 1.63 pooka rsys_seterrno(error);
732 1.68 pooka if (error == 0) {
733 1.68 pooka if (sizeof(int) > sizeof(register_t))
734 1.68 pooka rv = *(int *)retval;
735 1.68 pooka else
736 1.69 pooka rv = *retval;
737 1.27 pooka }
738 1.68 pooka return rv;
739 1.1 pooka }
740 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
741 1.103 pooka __weak_alias(chflags,rump___sysimpl_chflags);
742 1.103 pooka __weak_alias(_chflags,rump___sysimpl_chflags);
743 1.103 pooka __strong_alias(_sys_chflags,rump___sysimpl_chflags);
744 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
745 1.1 pooka
746 1.60 pooka int rump___sysimpl_fchflags(int, u_long);
747 1.34 pooka int
748 1.60 pooka rump___sysimpl_fchflags(int fd, u_long flags)
749 1.34 pooka {
750 1.93 pooka register_t retval[2];
751 1.34 pooka int error = 0;
752 1.68 pooka int rv = -1;
753 1.34 pooka struct sys_fchflags_args callarg;
754 1.34 pooka
755 1.95 pooka memset(&callarg, 0, sizeof(callarg));
756 1.34 pooka SPARG(&callarg, fd) = fd;
757 1.34 pooka SPARG(&callarg, flags) = flags;
758 1.34 pooka
759 1.120 pgoyette error = rsys_syscall(SYS_fchflags, &callarg, sizeof(callarg), retval);
760 1.63 pooka rsys_seterrno(error);
761 1.68 pooka if (error == 0) {
762 1.68 pooka if (sizeof(int) > sizeof(register_t))
763 1.68 pooka rv = *(int *)retval;
764 1.68 pooka else
765 1.69 pooka rv = *retval;
766 1.34 pooka }
767 1.68 pooka return rv;
768 1.34 pooka }
769 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
770 1.103 pooka __weak_alias(fchflags,rump___sysimpl_fchflags);
771 1.103 pooka __weak_alias(_fchflags,rump___sysimpl_fchflags);
772 1.103 pooka __strong_alias(_sys_fchflags,rump___sysimpl_fchflags);
773 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
774 1.34 pooka
775 1.60 pooka void rump___sysimpl_sync(void);
776 1.1 pooka void
777 1.60 pooka rump___sysimpl_sync(void )
778 1.1 pooka {
779 1.93 pooka register_t retval[2];
780 1.1 pooka
781 1.120 pgoyette rsys_syscall(SYS_sync, NULL, 0, retval);
782 1.1 pooka }
783 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
784 1.103 pooka __weak_alias(sync,rump___sysimpl_sync);
785 1.103 pooka __weak_alias(_sync,rump___sysimpl_sync);
786 1.103 pooka __strong_alias(_sys_sync,rump___sysimpl_sync);
787 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
788 1.1 pooka
789 1.60 pooka pid_t rump___sysimpl_getppid(void);
790 1.49 pooka pid_t
791 1.60 pooka rump___sysimpl_getppid(void )
792 1.49 pooka {
793 1.93 pooka register_t retval[2];
794 1.68 pooka pid_t rv = -1;
795 1.49 pooka
796 1.119 pgoyette (void)rsys_syscall(SYS_getppid, NULL, 0, retval);
797 1.68 pooka if (sizeof(pid_t) > sizeof(register_t))
798 1.68 pooka rv = *(pid_t *)retval;
799 1.68 pooka else
800 1.69 pooka rv = *retval;
801 1.68 pooka return rv;
802 1.49 pooka }
803 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
804 1.103 pooka __weak_alias(getppid,rump___sysimpl_getppid);
805 1.103 pooka __weak_alias(_getppid,rump___sysimpl_getppid);
806 1.103 pooka __strong_alias(_sys_getppid,rump___sysimpl_getppid);
807 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
808 1.49 pooka
809 1.60 pooka int rump___sysimpl_dup(int);
810 1.34 pooka int
811 1.60 pooka rump___sysimpl_dup(int fd)
812 1.34 pooka {
813 1.93 pooka register_t retval[2];
814 1.34 pooka int error = 0;
815 1.68 pooka int rv = -1;
816 1.34 pooka struct sys_dup_args callarg;
817 1.34 pooka
818 1.95 pooka memset(&callarg, 0, sizeof(callarg));
819 1.34 pooka SPARG(&callarg, fd) = fd;
820 1.34 pooka
821 1.120 pgoyette error = rsys_syscall(SYS_dup, &callarg, sizeof(callarg), retval);
822 1.63 pooka rsys_seterrno(error);
823 1.68 pooka if (error == 0) {
824 1.68 pooka if (sizeof(int) > sizeof(register_t))
825 1.68 pooka rv = *(int *)retval;
826 1.68 pooka else
827 1.69 pooka rv = *retval;
828 1.34 pooka }
829 1.68 pooka return rv;
830 1.34 pooka }
831 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
832 1.103 pooka __weak_alias(dup,rump___sysimpl_dup);
833 1.103 pooka __weak_alias(_dup,rump___sysimpl_dup);
834 1.103 pooka __strong_alias(_sys_dup,rump___sysimpl_dup);
835 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
836 1.34 pooka
837 1.60 pooka gid_t rump___sysimpl_getegid(void);
838 1.49 pooka gid_t
839 1.60 pooka rump___sysimpl_getegid(void )
840 1.49 pooka {
841 1.93 pooka register_t retval[2];
842 1.68 pooka gid_t rv = -1;
843 1.49 pooka
844 1.119 pgoyette (void)rsys_syscall(SYS_getegid, NULL, 0, retval);
845 1.68 pooka if (sizeof(gid_t) > sizeof(register_t))
846 1.68 pooka rv = *(gid_t *)retval;
847 1.68 pooka else
848 1.69 pooka rv = *retval;
849 1.68 pooka return rv;
850 1.49 pooka }
851 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
852 1.103 pooka __weak_alias(getegid,rump___sysimpl_getegid);
853 1.103 pooka __weak_alias(_getegid,rump___sysimpl_getegid);
854 1.103 pooka __strong_alias(_sys_getegid,rump___sysimpl_getegid);
855 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
856 1.49 pooka
857 1.94 pooka int rump___sysimpl_ktrace(const char *, int, int, pid_t);
858 1.94 pooka int
859 1.94 pooka rump___sysimpl_ktrace(const char * fname, int ops, int facs, pid_t pid)
860 1.94 pooka {
861 1.94 pooka register_t retval[2];
862 1.94 pooka int error = 0;
863 1.94 pooka int rv = -1;
864 1.94 pooka struct sys_ktrace_args callarg;
865 1.94 pooka
866 1.95 pooka memset(&callarg, 0, sizeof(callarg));
867 1.94 pooka SPARG(&callarg, fname) = fname;
868 1.94 pooka SPARG(&callarg, ops) = ops;
869 1.94 pooka SPARG(&callarg, facs) = facs;
870 1.94 pooka SPARG(&callarg, pid) = pid;
871 1.94 pooka
872 1.120 pgoyette error = rsys_syscall(SYS_ktrace, &callarg, sizeof(callarg), retval);
873 1.94 pooka rsys_seterrno(error);
874 1.94 pooka if (error == 0) {
875 1.94 pooka if (sizeof(int) > sizeof(register_t))
876 1.94 pooka rv = *(int *)retval;
877 1.94 pooka else
878 1.94 pooka rv = *retval;
879 1.94 pooka }
880 1.94 pooka return rv;
881 1.94 pooka }
882 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
883 1.103 pooka __weak_alias(ktrace,rump___sysimpl_ktrace);
884 1.103 pooka __weak_alias(_ktrace,rump___sysimpl_ktrace);
885 1.103 pooka __strong_alias(_sys_ktrace,rump___sysimpl_ktrace);
886 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
887 1.94 pooka
888 1.60 pooka gid_t rump___sysimpl_getgid(void);
889 1.49 pooka gid_t
890 1.60 pooka rump___sysimpl_getgid(void )
891 1.49 pooka {
892 1.93 pooka register_t retval[2];
893 1.68 pooka gid_t rv = -1;
894 1.49 pooka
895 1.119 pgoyette (void)rsys_syscall(SYS_getgid, NULL, 0, retval);
896 1.68 pooka if (sizeof(gid_t) > sizeof(register_t))
897 1.68 pooka rv = *(gid_t *)retval;
898 1.68 pooka else
899 1.69 pooka rv = *retval;
900 1.68 pooka return rv;
901 1.49 pooka }
902 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
903 1.103 pooka __weak_alias(getgid,rump___sysimpl_getgid);
904 1.103 pooka __weak_alias(_getgid,rump___sysimpl_getgid);
905 1.103 pooka __strong_alias(_sys_getgid,rump___sysimpl_getgid);
906 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
907 1.49 pooka
908 1.60 pooka int rump___sysimpl___getlogin(char *, size_t);
909 1.49 pooka int
910 1.60 pooka rump___sysimpl___getlogin(char * namebuf, size_t namelen)
911 1.49 pooka {
912 1.93 pooka register_t retval[2];
913 1.49 pooka int error = 0;
914 1.68 pooka int rv = -1;
915 1.49 pooka struct sys___getlogin_args callarg;
916 1.49 pooka
917 1.95 pooka memset(&callarg, 0, sizeof(callarg));
918 1.49 pooka SPARG(&callarg, namebuf) = namebuf;
919 1.49 pooka SPARG(&callarg, namelen) = namelen;
920 1.49 pooka
921 1.120 pgoyette error = rsys_syscall(SYS___getlogin, &callarg, sizeof(callarg), retval);
922 1.63 pooka rsys_seterrno(error);
923 1.68 pooka if (error == 0) {
924 1.68 pooka if (sizeof(int) > sizeof(register_t))
925 1.68 pooka rv = *(int *)retval;
926 1.68 pooka else
927 1.69 pooka rv = *retval;
928 1.49 pooka }
929 1.68 pooka return rv;
930 1.49 pooka }
931 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
932 1.103 pooka __weak_alias(__getlogin,rump___sysimpl___getlogin);
933 1.103 pooka __weak_alias(___getlogin,rump___sysimpl___getlogin);
934 1.103 pooka __strong_alias(_sys___getlogin,rump___sysimpl___getlogin);
935 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
936 1.49 pooka
937 1.60 pooka int rump___sysimpl___setlogin(const char *);
938 1.49 pooka int
939 1.60 pooka rump___sysimpl___setlogin(const char * namebuf)
940 1.49 pooka {
941 1.93 pooka register_t retval[2];
942 1.49 pooka int error = 0;
943 1.68 pooka int rv = -1;
944 1.49 pooka struct sys___setlogin_args callarg;
945 1.49 pooka
946 1.95 pooka memset(&callarg, 0, sizeof(callarg));
947 1.49 pooka SPARG(&callarg, namebuf) = namebuf;
948 1.49 pooka
949 1.120 pgoyette error = rsys_syscall(SYS___setlogin, &callarg, sizeof(callarg), retval);
950 1.63 pooka rsys_seterrno(error);
951 1.68 pooka if (error == 0) {
952 1.68 pooka if (sizeof(int) > sizeof(register_t))
953 1.68 pooka rv = *(int *)retval;
954 1.68 pooka else
955 1.69 pooka rv = *retval;
956 1.49 pooka }
957 1.68 pooka return rv;
958 1.49 pooka }
959 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
960 1.103 pooka __weak_alias(__setlogin,rump___sysimpl___setlogin);
961 1.103 pooka __weak_alias(___setlogin,rump___sysimpl___setlogin);
962 1.103 pooka __strong_alias(_sys___setlogin,rump___sysimpl___setlogin);
963 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
964 1.49 pooka
965 1.60 pooka int rump___sysimpl_ioctl(int, u_long, void *);
966 1.1 pooka int
967 1.60 pooka rump___sysimpl_ioctl(int fd, u_long com, void * data)
968 1.19 pooka {
969 1.93 pooka register_t retval[2];
970 1.27 pooka int error = 0;
971 1.68 pooka int rv = -1;
972 1.31 pooka struct sys_ioctl_args callarg;
973 1.19 pooka
974 1.95 pooka memset(&callarg, 0, sizeof(callarg));
975 1.31 pooka SPARG(&callarg, fd) = fd;
976 1.31 pooka SPARG(&callarg, com) = com;
977 1.31 pooka SPARG(&callarg, data) = data;
978 1.19 pooka
979 1.120 pgoyette error = rsys_syscall(SYS_ioctl, &callarg, sizeof(callarg), retval);
980 1.63 pooka rsys_seterrno(error);
981 1.68 pooka if (error == 0) {
982 1.68 pooka if (sizeof(int) > sizeof(register_t))
983 1.68 pooka rv = *(int *)retval;
984 1.68 pooka else
985 1.69 pooka rv = *retval;
986 1.27 pooka }
987 1.68 pooka return rv;
988 1.19 pooka }
989 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
990 1.103 pooka __weak_alias(ioctl,rump___sysimpl_ioctl);
991 1.103 pooka __weak_alias(_ioctl,rump___sysimpl_ioctl);
992 1.103 pooka __strong_alias(_sys_ioctl,rump___sysimpl_ioctl);
993 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
994 1.19 pooka
995 1.60 pooka int rump___sysimpl_revoke(const char *);
996 1.34 pooka int
997 1.60 pooka rump___sysimpl_revoke(const char * path)
998 1.34 pooka {
999 1.93 pooka register_t retval[2];
1000 1.34 pooka int error = 0;
1001 1.68 pooka int rv = -1;
1002 1.34 pooka struct sys_revoke_args callarg;
1003 1.34 pooka
1004 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1005 1.34 pooka SPARG(&callarg, path) = path;
1006 1.34 pooka
1007 1.120 pgoyette error = rsys_syscall(SYS_revoke, &callarg, sizeof(callarg), retval);
1008 1.63 pooka rsys_seterrno(error);
1009 1.68 pooka if (error == 0) {
1010 1.68 pooka if (sizeof(int) > sizeof(register_t))
1011 1.68 pooka rv = *(int *)retval;
1012 1.68 pooka else
1013 1.69 pooka rv = *retval;
1014 1.34 pooka }
1015 1.68 pooka return rv;
1016 1.34 pooka }
1017 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1018 1.103 pooka __weak_alias(revoke,rump___sysimpl_revoke);
1019 1.103 pooka __weak_alias(_revoke,rump___sysimpl_revoke);
1020 1.103 pooka __strong_alias(_sys_revoke,rump___sysimpl_revoke);
1021 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1022 1.34 pooka
1023 1.60 pooka int rump___sysimpl_symlink(const char *, const char *);
1024 1.19 pooka int
1025 1.60 pooka rump___sysimpl_symlink(const char * path, const char * link)
1026 1.1 pooka {
1027 1.93 pooka register_t retval[2];
1028 1.27 pooka int error = 0;
1029 1.68 pooka int rv = -1;
1030 1.31 pooka struct sys_symlink_args callarg;
1031 1.1 pooka
1032 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1033 1.31 pooka SPARG(&callarg, path) = path;
1034 1.31 pooka SPARG(&callarg, link) = link;
1035 1.1 pooka
1036 1.120 pgoyette error = rsys_syscall(SYS_symlink, &callarg, sizeof(callarg), retval);
1037 1.63 pooka rsys_seterrno(error);
1038 1.68 pooka if (error == 0) {
1039 1.68 pooka if (sizeof(int) > sizeof(register_t))
1040 1.68 pooka rv = *(int *)retval;
1041 1.68 pooka else
1042 1.69 pooka rv = *retval;
1043 1.27 pooka }
1044 1.68 pooka return rv;
1045 1.1 pooka }
1046 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1047 1.103 pooka __weak_alias(symlink,rump___sysimpl_symlink);
1048 1.103 pooka __weak_alias(_symlink,rump___sysimpl_symlink);
1049 1.103 pooka __strong_alias(_sys_symlink,rump___sysimpl_symlink);
1050 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1051 1.1 pooka
1052 1.60 pooka ssize_t rump___sysimpl_readlink(const char *, char *, size_t);
1053 1.1 pooka ssize_t
1054 1.60 pooka rump___sysimpl_readlink(const char * path, char * buf, size_t count)
1055 1.1 pooka {
1056 1.93 pooka register_t retval[2];
1057 1.27 pooka int error = 0;
1058 1.68 pooka ssize_t rv = -1;
1059 1.31 pooka struct sys_readlink_args callarg;
1060 1.1 pooka
1061 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1062 1.31 pooka SPARG(&callarg, path) = path;
1063 1.31 pooka SPARG(&callarg, buf) = buf;
1064 1.31 pooka SPARG(&callarg, count) = count;
1065 1.1 pooka
1066 1.120 pgoyette error = rsys_syscall(SYS_readlink, &callarg, sizeof(callarg), retval);
1067 1.63 pooka rsys_seterrno(error);
1068 1.68 pooka if (error == 0) {
1069 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
1070 1.68 pooka rv = *(ssize_t *)retval;
1071 1.68 pooka else
1072 1.69 pooka rv = *retval;
1073 1.27 pooka }
1074 1.68 pooka return rv;
1075 1.1 pooka }
1076 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1077 1.103 pooka __weak_alias(readlink,rump___sysimpl_readlink);
1078 1.103 pooka __weak_alias(_readlink,rump___sysimpl_readlink);
1079 1.103 pooka __strong_alias(_sys_readlink,rump___sysimpl_readlink);
1080 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1081 1.1 pooka
1082 1.60 pooka mode_t rump___sysimpl_umask(mode_t);
1083 1.50 pooka mode_t
1084 1.60 pooka rump___sysimpl_umask(mode_t newmask)
1085 1.50 pooka {
1086 1.93 pooka register_t retval[2];
1087 1.50 pooka int error = 0;
1088 1.68 pooka mode_t rv = -1;
1089 1.50 pooka struct sys_umask_args callarg;
1090 1.50 pooka
1091 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1092 1.50 pooka SPARG(&callarg, newmask) = newmask;
1093 1.50 pooka
1094 1.120 pgoyette error = rsys_syscall(SYS_umask, &callarg, sizeof(callarg), retval);
1095 1.63 pooka rsys_seterrno(error);
1096 1.68 pooka if (error == 0) {
1097 1.68 pooka if (sizeof(mode_t) > sizeof(register_t))
1098 1.68 pooka rv = *(mode_t *)retval;
1099 1.68 pooka else
1100 1.69 pooka rv = *retval;
1101 1.50 pooka }
1102 1.68 pooka return rv;
1103 1.50 pooka }
1104 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1105 1.103 pooka __weak_alias(umask,rump___sysimpl_umask);
1106 1.103 pooka __weak_alias(_umask,rump___sysimpl_umask);
1107 1.103 pooka __strong_alias(_sys_umask,rump___sysimpl_umask);
1108 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1109 1.50 pooka
1110 1.60 pooka int rump___sysimpl_chroot(const char *);
1111 1.34 pooka int
1112 1.60 pooka rump___sysimpl_chroot(const char * path)
1113 1.34 pooka {
1114 1.93 pooka register_t retval[2];
1115 1.34 pooka int error = 0;
1116 1.68 pooka int rv = -1;
1117 1.34 pooka struct sys_chroot_args callarg;
1118 1.34 pooka
1119 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1120 1.34 pooka SPARG(&callarg, path) = path;
1121 1.34 pooka
1122 1.120 pgoyette error = rsys_syscall(SYS_chroot, &callarg, sizeof(callarg), retval);
1123 1.63 pooka rsys_seterrno(error);
1124 1.68 pooka if (error == 0) {
1125 1.68 pooka if (sizeof(int) > sizeof(register_t))
1126 1.68 pooka rv = *(int *)retval;
1127 1.68 pooka else
1128 1.69 pooka rv = *retval;
1129 1.34 pooka }
1130 1.68 pooka return rv;
1131 1.34 pooka }
1132 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1133 1.103 pooka __weak_alias(chroot,rump___sysimpl_chroot);
1134 1.103 pooka __weak_alias(_chroot,rump___sysimpl_chroot);
1135 1.103 pooka __strong_alias(_sys_chroot,rump___sysimpl_chroot);
1136 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1137 1.34 pooka
1138 1.60 pooka int rump___sysimpl_getgroups(int, gid_t *);
1139 1.49 pooka int
1140 1.60 pooka rump___sysimpl_getgroups(int gidsetsize, gid_t * gidset)
1141 1.49 pooka {
1142 1.93 pooka register_t retval[2];
1143 1.49 pooka int error = 0;
1144 1.68 pooka int rv = -1;
1145 1.49 pooka struct sys_getgroups_args callarg;
1146 1.49 pooka
1147 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1148 1.49 pooka SPARG(&callarg, gidsetsize) = gidsetsize;
1149 1.49 pooka SPARG(&callarg, gidset) = gidset;
1150 1.49 pooka
1151 1.120 pgoyette error = rsys_syscall(SYS_getgroups, &callarg, sizeof(callarg), retval);
1152 1.63 pooka rsys_seterrno(error);
1153 1.68 pooka if (error == 0) {
1154 1.68 pooka if (sizeof(int) > sizeof(register_t))
1155 1.68 pooka rv = *(int *)retval;
1156 1.68 pooka else
1157 1.69 pooka rv = *retval;
1158 1.49 pooka }
1159 1.68 pooka return rv;
1160 1.49 pooka }
1161 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1162 1.103 pooka __weak_alias(getgroups,rump___sysimpl_getgroups);
1163 1.103 pooka __weak_alias(_getgroups,rump___sysimpl_getgroups);
1164 1.103 pooka __strong_alias(_sys_getgroups,rump___sysimpl_getgroups);
1165 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1166 1.49 pooka
1167 1.60 pooka int rump___sysimpl_setgroups(int, const gid_t *);
1168 1.49 pooka int
1169 1.60 pooka rump___sysimpl_setgroups(int gidsetsize, const gid_t * gidset)
1170 1.49 pooka {
1171 1.93 pooka register_t retval[2];
1172 1.49 pooka int error = 0;
1173 1.68 pooka int rv = -1;
1174 1.49 pooka struct sys_setgroups_args callarg;
1175 1.49 pooka
1176 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1177 1.49 pooka SPARG(&callarg, gidsetsize) = gidsetsize;
1178 1.49 pooka SPARG(&callarg, gidset) = gidset;
1179 1.49 pooka
1180 1.120 pgoyette error = rsys_syscall(SYS_setgroups, &callarg, sizeof(callarg), retval);
1181 1.63 pooka rsys_seterrno(error);
1182 1.68 pooka if (error == 0) {
1183 1.68 pooka if (sizeof(int) > sizeof(register_t))
1184 1.68 pooka rv = *(int *)retval;
1185 1.68 pooka else
1186 1.69 pooka rv = *retval;
1187 1.49 pooka }
1188 1.68 pooka return rv;
1189 1.49 pooka }
1190 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1191 1.103 pooka __weak_alias(setgroups,rump___sysimpl_setgroups);
1192 1.103 pooka __weak_alias(_setgroups,rump___sysimpl_setgroups);
1193 1.103 pooka __strong_alias(_sys_setgroups,rump___sysimpl_setgroups);
1194 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1195 1.49 pooka
1196 1.60 pooka int rump___sysimpl_getpgrp(void);
1197 1.49 pooka int
1198 1.60 pooka rump___sysimpl_getpgrp(void )
1199 1.49 pooka {
1200 1.93 pooka register_t retval[2];
1201 1.49 pooka int error = 0;
1202 1.68 pooka int rv = -1;
1203 1.49 pooka
1204 1.120 pgoyette error = rsys_syscall(SYS_getpgrp, NULL, 0, retval);
1205 1.63 pooka rsys_seterrno(error);
1206 1.68 pooka if (error == 0) {
1207 1.68 pooka if (sizeof(int) > sizeof(register_t))
1208 1.68 pooka rv = *(int *)retval;
1209 1.68 pooka else
1210 1.69 pooka rv = *retval;
1211 1.49 pooka }
1212 1.68 pooka return rv;
1213 1.49 pooka }
1214 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1215 1.103 pooka __weak_alias(getpgrp,rump___sysimpl_getpgrp);
1216 1.103 pooka __weak_alias(_getpgrp,rump___sysimpl_getpgrp);
1217 1.103 pooka __strong_alias(_sys_getpgrp,rump___sysimpl_getpgrp);
1218 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1219 1.49 pooka
1220 1.62 pooka int rump___sysimpl_setpgid(pid_t, pid_t);
1221 1.49 pooka int
1222 1.62 pooka rump___sysimpl_setpgid(pid_t pid, pid_t pgid)
1223 1.49 pooka {
1224 1.93 pooka register_t retval[2];
1225 1.49 pooka int error = 0;
1226 1.68 pooka int rv = -1;
1227 1.49 pooka struct sys_setpgid_args callarg;
1228 1.49 pooka
1229 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1230 1.49 pooka SPARG(&callarg, pid) = pid;
1231 1.49 pooka SPARG(&callarg, pgid) = pgid;
1232 1.49 pooka
1233 1.120 pgoyette error = rsys_syscall(SYS_setpgid, &callarg, sizeof(callarg), retval);
1234 1.63 pooka rsys_seterrno(error);
1235 1.68 pooka if (error == 0) {
1236 1.68 pooka if (sizeof(int) > sizeof(register_t))
1237 1.68 pooka rv = *(int *)retval;
1238 1.68 pooka else
1239 1.69 pooka rv = *retval;
1240 1.49 pooka }
1241 1.68 pooka return rv;
1242 1.49 pooka }
1243 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1244 1.103 pooka __weak_alias(setpgid,rump___sysimpl_setpgid);
1245 1.103 pooka __weak_alias(_setpgid,rump___sysimpl_setpgid);
1246 1.103 pooka __strong_alias(_sys_setpgid,rump___sysimpl_setpgid);
1247 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1248 1.49 pooka
1249 1.60 pooka int rump___sysimpl_dup2(int, int);
1250 1.34 pooka int
1251 1.60 pooka rump___sysimpl_dup2(int from, int to)
1252 1.34 pooka {
1253 1.93 pooka register_t retval[2];
1254 1.34 pooka int error = 0;
1255 1.68 pooka int rv = -1;
1256 1.34 pooka struct sys_dup2_args callarg;
1257 1.34 pooka
1258 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1259 1.34 pooka SPARG(&callarg, from) = from;
1260 1.34 pooka SPARG(&callarg, to) = to;
1261 1.34 pooka
1262 1.120 pgoyette error = rsys_syscall(SYS_dup2, &callarg, sizeof(callarg), retval);
1263 1.63 pooka rsys_seterrno(error);
1264 1.68 pooka if (error == 0) {
1265 1.68 pooka if (sizeof(int) > sizeof(register_t))
1266 1.68 pooka rv = *(int *)retval;
1267 1.68 pooka else
1268 1.69 pooka rv = *retval;
1269 1.34 pooka }
1270 1.68 pooka return rv;
1271 1.34 pooka }
1272 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1273 1.103 pooka __weak_alias(dup2,rump___sysimpl_dup2);
1274 1.103 pooka __weak_alias(_dup2,rump___sysimpl_dup2);
1275 1.103 pooka __strong_alias(_sys_dup2,rump___sysimpl_dup2);
1276 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1277 1.34 pooka
1278 1.154 riastrad ssize_t rump___sysimpl_getrandom(void *, size_t, unsigned int);
1279 1.154 riastrad ssize_t
1280 1.154 riastrad rump___sysimpl_getrandom(void * buf, size_t buflen, unsigned int flags)
1281 1.154 riastrad {
1282 1.154 riastrad register_t retval[2];
1283 1.154 riastrad int error = 0;
1284 1.154 riastrad ssize_t rv = -1;
1285 1.154 riastrad struct sys_getrandom_args callarg;
1286 1.154 riastrad
1287 1.154 riastrad memset(&callarg, 0, sizeof(callarg));
1288 1.154 riastrad SPARG(&callarg, buf) = buf;
1289 1.154 riastrad SPARG(&callarg, buflen) = buflen;
1290 1.154 riastrad SPARG(&callarg, flags) = flags;
1291 1.154 riastrad
1292 1.154 riastrad error = rsys_syscall(SYS_getrandom, &callarg, sizeof(callarg), retval);
1293 1.154 riastrad rsys_seterrno(error);
1294 1.154 riastrad if (error == 0) {
1295 1.154 riastrad if (sizeof(ssize_t) > sizeof(register_t))
1296 1.154 riastrad rv = *(ssize_t *)retval;
1297 1.154 riastrad else
1298 1.154 riastrad rv = *retval;
1299 1.154 riastrad }
1300 1.154 riastrad return rv;
1301 1.154 riastrad }
1302 1.154 riastrad #ifdef RUMP_KERNEL_IS_LIBC
1303 1.154 riastrad __weak_alias(getrandom,rump___sysimpl_getrandom);
1304 1.154 riastrad __weak_alias(_getrandom,rump___sysimpl_getrandom);
1305 1.154 riastrad __strong_alias(_sys_getrandom,rump___sysimpl_getrandom);
1306 1.154 riastrad #endif /* RUMP_KERNEL_IS_LIBC */
1307 1.154 riastrad
1308 1.60 pooka int rump___sysimpl_fcntl(int, int, void *);
1309 1.34 pooka int
1310 1.60 pooka rump___sysimpl_fcntl(int fd, int cmd, void * arg)
1311 1.34 pooka {
1312 1.93 pooka register_t retval[2];
1313 1.34 pooka int error = 0;
1314 1.68 pooka int rv = -1;
1315 1.34 pooka struct sys_fcntl_args callarg;
1316 1.34 pooka
1317 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1318 1.34 pooka SPARG(&callarg, fd) = fd;
1319 1.34 pooka SPARG(&callarg, cmd) = cmd;
1320 1.34 pooka SPARG(&callarg, arg) = arg;
1321 1.34 pooka
1322 1.120 pgoyette error = rsys_syscall(SYS_fcntl, &callarg, sizeof(callarg), retval);
1323 1.63 pooka rsys_seterrno(error);
1324 1.68 pooka if (error == 0) {
1325 1.68 pooka if (sizeof(int) > sizeof(register_t))
1326 1.68 pooka rv = *(int *)retval;
1327 1.68 pooka else
1328 1.69 pooka rv = *retval;
1329 1.34 pooka }
1330 1.68 pooka return rv;
1331 1.34 pooka }
1332 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1333 1.103 pooka __weak_alias(fcntl,rump___sysimpl_fcntl);
1334 1.103 pooka __weak_alias(_fcntl,rump___sysimpl_fcntl);
1335 1.103 pooka __strong_alias(_sys_fcntl,rump___sysimpl_fcntl);
1336 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1337 1.34 pooka
1338 1.103 pooka #ifdef RUMP_SYS_COMPAT
1339 1.60 pooka int rump___sysimpl_select(int, fd_set *, fd_set *, fd_set *, struct timeval *);
1340 1.1 pooka int
1341 1.60 pooka rump___sysimpl_select(int nd, fd_set * in, fd_set * ou, fd_set * ex, struct timeval * tv)
1342 1.60 pooka {
1343 1.93 pooka register_t retval[2];
1344 1.60 pooka int error = 0;
1345 1.68 pooka int rv = -1;
1346 1.60 pooka struct compat_50_sys_select_args callarg;
1347 1.60 pooka
1348 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1349 1.60 pooka SPARG(&callarg, nd) = nd;
1350 1.60 pooka SPARG(&callarg, in) = in;
1351 1.60 pooka SPARG(&callarg, ou) = ou;
1352 1.60 pooka SPARG(&callarg, ex) = ex;
1353 1.60 pooka SPARG(&callarg, tv) = (struct timeval50 *)tv;
1354 1.60 pooka
1355 1.120 pgoyette error = rsys_syscall(SYS_compat_50_select, &callarg, sizeof(callarg), retval);
1356 1.63 pooka rsys_seterrno(error);
1357 1.68 pooka if (error == 0) {
1358 1.68 pooka if (sizeof(int) > sizeof(register_t))
1359 1.68 pooka rv = *(int *)retval;
1360 1.68 pooka else
1361 1.69 pooka rv = *retval;
1362 1.60 pooka }
1363 1.68 pooka return rv;
1364 1.60 pooka }
1365 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1366 1.103 pooka __weak_alias(select,rump___sysimpl_select);
1367 1.103 pooka __weak_alias(_select,rump___sysimpl_select);
1368 1.103 pooka __strong_alias(_sys_select,rump___sysimpl_select);
1369 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1370 1.103 pooka #endif /* RUMP_SYS_COMPAT */
1371 1.60 pooka
1372 1.60 pooka int rump___sysimpl_fsync(int);
1373 1.60 pooka int
1374 1.60 pooka rump___sysimpl_fsync(int fd)
1375 1.12 pooka {
1376 1.93 pooka register_t retval[2];
1377 1.27 pooka int error = 0;
1378 1.68 pooka int rv = -1;
1379 1.31 pooka struct sys_fsync_args callarg;
1380 1.12 pooka
1381 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1382 1.31 pooka SPARG(&callarg, fd) = fd;
1383 1.12 pooka
1384 1.120 pgoyette error = rsys_syscall(SYS_fsync, &callarg, sizeof(callarg), retval);
1385 1.63 pooka rsys_seterrno(error);
1386 1.68 pooka if (error == 0) {
1387 1.68 pooka if (sizeof(int) > sizeof(register_t))
1388 1.68 pooka rv = *(int *)retval;
1389 1.68 pooka else
1390 1.69 pooka rv = *retval;
1391 1.27 pooka }
1392 1.68 pooka return rv;
1393 1.12 pooka }
1394 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1395 1.103 pooka __weak_alias(fsync,rump___sysimpl_fsync);
1396 1.103 pooka __weak_alias(_fsync,rump___sysimpl_fsync);
1397 1.103 pooka __strong_alias(_sys_fsync,rump___sysimpl_fsync);
1398 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1399 1.12 pooka
1400 1.72 christos int rump___sysimpl_connect(int, const struct sockaddr *, socklen_t);
1401 1.12 pooka int
1402 1.72 christos rump___sysimpl_connect(int s, const struct sockaddr * name, socklen_t namelen)
1403 1.18 pooka {
1404 1.93 pooka register_t retval[2];
1405 1.27 pooka int error = 0;
1406 1.68 pooka int rv = -1;
1407 1.31 pooka struct sys_connect_args callarg;
1408 1.18 pooka
1409 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1410 1.31 pooka SPARG(&callarg, s) = s;
1411 1.31 pooka SPARG(&callarg, name) = name;
1412 1.31 pooka SPARG(&callarg, namelen) = namelen;
1413 1.18 pooka
1414 1.120 pgoyette error = rsys_syscall(SYS_connect, &callarg, sizeof(callarg), retval);
1415 1.63 pooka rsys_seterrno(error);
1416 1.68 pooka if (error == 0) {
1417 1.68 pooka if (sizeof(int) > sizeof(register_t))
1418 1.68 pooka rv = *(int *)retval;
1419 1.68 pooka else
1420 1.69 pooka rv = *retval;
1421 1.27 pooka }
1422 1.68 pooka return rv;
1423 1.18 pooka }
1424 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1425 1.103 pooka __weak_alias(connect,rump___sysimpl_connect);
1426 1.103 pooka __weak_alias(_connect,rump___sysimpl_connect);
1427 1.103 pooka __strong_alias(_sys_connect,rump___sysimpl_connect);
1428 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1429 1.18 pooka
1430 1.72 christos int rump___sysimpl_bind(int, const struct sockaddr *, socklen_t);
1431 1.18 pooka int
1432 1.72 christos rump___sysimpl_bind(int s, const struct sockaddr * name, socklen_t namelen)
1433 1.22 pooka {
1434 1.93 pooka register_t retval[2];
1435 1.27 pooka int error = 0;
1436 1.68 pooka int rv = -1;
1437 1.31 pooka struct sys_bind_args callarg;
1438 1.22 pooka
1439 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1440 1.31 pooka SPARG(&callarg, s) = s;
1441 1.31 pooka SPARG(&callarg, name) = name;
1442 1.31 pooka SPARG(&callarg, namelen) = namelen;
1443 1.22 pooka
1444 1.120 pgoyette error = rsys_syscall(SYS_bind, &callarg, sizeof(callarg), retval);
1445 1.63 pooka rsys_seterrno(error);
1446 1.68 pooka if (error == 0) {
1447 1.68 pooka if (sizeof(int) > sizeof(register_t))
1448 1.68 pooka rv = *(int *)retval;
1449 1.68 pooka else
1450 1.69 pooka rv = *retval;
1451 1.27 pooka }
1452 1.68 pooka return rv;
1453 1.22 pooka }
1454 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1455 1.103 pooka __weak_alias(bind,rump___sysimpl_bind);
1456 1.103 pooka __weak_alias(_bind,rump___sysimpl_bind);
1457 1.103 pooka __strong_alias(_sys_bind,rump___sysimpl_bind);
1458 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1459 1.22 pooka
1460 1.72 christos int rump___sysimpl_setsockopt(int, int, int, const void *, socklen_t);
1461 1.22 pooka int
1462 1.72 christos rump___sysimpl_setsockopt(int s, int level, int name, const void * val, socklen_t valsize)
1463 1.18 pooka {
1464 1.93 pooka register_t retval[2];
1465 1.27 pooka int error = 0;
1466 1.68 pooka int rv = -1;
1467 1.31 pooka struct sys_setsockopt_args callarg;
1468 1.18 pooka
1469 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1470 1.31 pooka SPARG(&callarg, s) = s;
1471 1.31 pooka SPARG(&callarg, level) = level;
1472 1.31 pooka SPARG(&callarg, name) = name;
1473 1.31 pooka SPARG(&callarg, val) = val;
1474 1.31 pooka SPARG(&callarg, valsize) = valsize;
1475 1.18 pooka
1476 1.120 pgoyette error = rsys_syscall(SYS_setsockopt, &callarg, sizeof(callarg), retval);
1477 1.63 pooka rsys_seterrno(error);
1478 1.68 pooka if (error == 0) {
1479 1.68 pooka if (sizeof(int) > sizeof(register_t))
1480 1.68 pooka rv = *(int *)retval;
1481 1.68 pooka else
1482 1.69 pooka rv = *retval;
1483 1.27 pooka }
1484 1.68 pooka return rv;
1485 1.18 pooka }
1486 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1487 1.103 pooka __weak_alias(setsockopt,rump___sysimpl_setsockopt);
1488 1.103 pooka __weak_alias(_setsockopt,rump___sysimpl_setsockopt);
1489 1.103 pooka __strong_alias(_sys_setsockopt,rump___sysimpl_setsockopt);
1490 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1491 1.18 pooka
1492 1.60 pooka int rump___sysimpl_listen(int, int);
1493 1.18 pooka int
1494 1.60 pooka rump___sysimpl_listen(int s, int backlog)
1495 1.22 pooka {
1496 1.93 pooka register_t retval[2];
1497 1.27 pooka int error = 0;
1498 1.68 pooka int rv = -1;
1499 1.31 pooka struct sys_listen_args callarg;
1500 1.22 pooka
1501 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1502 1.31 pooka SPARG(&callarg, s) = s;
1503 1.31 pooka SPARG(&callarg, backlog) = backlog;
1504 1.22 pooka
1505 1.120 pgoyette error = rsys_syscall(SYS_listen, &callarg, sizeof(callarg), retval);
1506 1.63 pooka rsys_seterrno(error);
1507 1.68 pooka if (error == 0) {
1508 1.68 pooka if (sizeof(int) > sizeof(register_t))
1509 1.68 pooka rv = *(int *)retval;
1510 1.68 pooka else
1511 1.69 pooka rv = *retval;
1512 1.27 pooka }
1513 1.68 pooka return rv;
1514 1.22 pooka }
1515 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1516 1.103 pooka __weak_alias(listen,rump___sysimpl_listen);
1517 1.103 pooka __weak_alias(_listen,rump___sysimpl_listen);
1518 1.103 pooka __strong_alias(_sys_listen,rump___sysimpl_listen);
1519 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1520 1.22 pooka
1521 1.72 christos int rump___sysimpl_getsockopt(int, int, int, void *, socklen_t *);
1522 1.22 pooka int
1523 1.72 christos rump___sysimpl_getsockopt(int s, int level, int name, void * val, socklen_t * avalsize)
1524 1.18 pooka {
1525 1.93 pooka register_t retval[2];
1526 1.27 pooka int error = 0;
1527 1.68 pooka int rv = -1;
1528 1.31 pooka struct sys_getsockopt_args callarg;
1529 1.18 pooka
1530 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1531 1.31 pooka SPARG(&callarg, s) = s;
1532 1.31 pooka SPARG(&callarg, level) = level;
1533 1.31 pooka SPARG(&callarg, name) = name;
1534 1.31 pooka SPARG(&callarg, val) = val;
1535 1.31 pooka SPARG(&callarg, avalsize) = avalsize;
1536 1.18 pooka
1537 1.120 pgoyette error = rsys_syscall(SYS_getsockopt, &callarg, sizeof(callarg), retval);
1538 1.63 pooka rsys_seterrno(error);
1539 1.68 pooka if (error == 0) {
1540 1.68 pooka if (sizeof(int) > sizeof(register_t))
1541 1.68 pooka rv = *(int *)retval;
1542 1.68 pooka else
1543 1.69 pooka rv = *retval;
1544 1.27 pooka }
1545 1.68 pooka return rv;
1546 1.18 pooka }
1547 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1548 1.103 pooka __weak_alias(getsockopt,rump___sysimpl_getsockopt);
1549 1.103 pooka __weak_alias(_getsockopt,rump___sysimpl_getsockopt);
1550 1.103 pooka __strong_alias(_sys_getsockopt,rump___sysimpl_getsockopt);
1551 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1552 1.18 pooka
1553 1.60 pooka ssize_t rump___sysimpl_readv(int, const struct iovec *, int);
1554 1.34 pooka ssize_t
1555 1.60 pooka rump___sysimpl_readv(int fd, const struct iovec * iovp, int iovcnt)
1556 1.34 pooka {
1557 1.93 pooka register_t retval[2];
1558 1.34 pooka int error = 0;
1559 1.68 pooka ssize_t rv = -1;
1560 1.34 pooka struct sys_readv_args callarg;
1561 1.34 pooka
1562 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1563 1.34 pooka SPARG(&callarg, fd) = fd;
1564 1.34 pooka SPARG(&callarg, iovp) = iovp;
1565 1.34 pooka SPARG(&callarg, iovcnt) = iovcnt;
1566 1.34 pooka
1567 1.120 pgoyette error = rsys_syscall(SYS_readv, &callarg, sizeof(callarg), retval);
1568 1.63 pooka rsys_seterrno(error);
1569 1.68 pooka if (error == 0) {
1570 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
1571 1.68 pooka rv = *(ssize_t *)retval;
1572 1.68 pooka else
1573 1.69 pooka rv = *retval;
1574 1.34 pooka }
1575 1.68 pooka return rv;
1576 1.34 pooka }
1577 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1578 1.103 pooka __weak_alias(readv,rump___sysimpl_readv);
1579 1.103 pooka __weak_alias(_readv,rump___sysimpl_readv);
1580 1.103 pooka __strong_alias(_sys_readv,rump___sysimpl_readv);
1581 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1582 1.34 pooka
1583 1.60 pooka ssize_t rump___sysimpl_writev(int, const struct iovec *, int);
1584 1.34 pooka ssize_t
1585 1.60 pooka rump___sysimpl_writev(int fd, const struct iovec * iovp, int iovcnt)
1586 1.34 pooka {
1587 1.93 pooka register_t retval[2];
1588 1.34 pooka int error = 0;
1589 1.68 pooka ssize_t rv = -1;
1590 1.34 pooka struct sys_writev_args callarg;
1591 1.34 pooka
1592 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1593 1.34 pooka SPARG(&callarg, fd) = fd;
1594 1.34 pooka SPARG(&callarg, iovp) = iovp;
1595 1.34 pooka SPARG(&callarg, iovcnt) = iovcnt;
1596 1.34 pooka
1597 1.120 pgoyette error = rsys_syscall(SYS_writev, &callarg, sizeof(callarg), retval);
1598 1.63 pooka rsys_seterrno(error);
1599 1.68 pooka if (error == 0) {
1600 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
1601 1.68 pooka rv = *(ssize_t *)retval;
1602 1.68 pooka else
1603 1.69 pooka rv = *retval;
1604 1.34 pooka }
1605 1.68 pooka return rv;
1606 1.34 pooka }
1607 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1608 1.103 pooka __weak_alias(writev,rump___sysimpl_writev);
1609 1.103 pooka __weak_alias(_writev,rump___sysimpl_writev);
1610 1.103 pooka __strong_alias(_sys_writev,rump___sysimpl_writev);
1611 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1612 1.34 pooka
1613 1.60 pooka int rump___sysimpl_fchown(int, uid_t, gid_t);
1614 1.34 pooka int
1615 1.60 pooka rump___sysimpl_fchown(int fd, uid_t uid, gid_t gid)
1616 1.34 pooka {
1617 1.93 pooka register_t retval[2];
1618 1.34 pooka int error = 0;
1619 1.68 pooka int rv = -1;
1620 1.34 pooka struct sys_fchown_args callarg;
1621 1.34 pooka
1622 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1623 1.34 pooka SPARG(&callarg, fd) = fd;
1624 1.34 pooka SPARG(&callarg, uid) = uid;
1625 1.34 pooka SPARG(&callarg, gid) = gid;
1626 1.34 pooka
1627 1.120 pgoyette error = rsys_syscall(SYS_fchown, &callarg, sizeof(callarg), retval);
1628 1.63 pooka rsys_seterrno(error);
1629 1.68 pooka if (error == 0) {
1630 1.68 pooka if (sizeof(int) > sizeof(register_t))
1631 1.68 pooka rv = *(int *)retval;
1632 1.68 pooka else
1633 1.69 pooka rv = *retval;
1634 1.34 pooka }
1635 1.68 pooka return rv;
1636 1.34 pooka }
1637 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1638 1.103 pooka __weak_alias(fchown,rump___sysimpl_fchown);
1639 1.103 pooka __weak_alias(_fchown,rump___sysimpl_fchown);
1640 1.103 pooka __strong_alias(_sys_fchown,rump___sysimpl_fchown);
1641 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1642 1.34 pooka
1643 1.60 pooka int rump___sysimpl_fchmod(int, mode_t);
1644 1.34 pooka int
1645 1.60 pooka rump___sysimpl_fchmod(int fd, mode_t mode)
1646 1.34 pooka {
1647 1.93 pooka register_t retval[2];
1648 1.34 pooka int error = 0;
1649 1.68 pooka int rv = -1;
1650 1.34 pooka struct sys_fchmod_args callarg;
1651 1.34 pooka
1652 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1653 1.34 pooka SPARG(&callarg, fd) = fd;
1654 1.34 pooka SPARG(&callarg, mode) = mode;
1655 1.34 pooka
1656 1.120 pgoyette error = rsys_syscall(SYS_fchmod, &callarg, sizeof(callarg), retval);
1657 1.63 pooka rsys_seterrno(error);
1658 1.68 pooka if (error == 0) {
1659 1.68 pooka if (sizeof(int) > sizeof(register_t))
1660 1.68 pooka rv = *(int *)retval;
1661 1.68 pooka else
1662 1.69 pooka rv = *retval;
1663 1.34 pooka }
1664 1.68 pooka return rv;
1665 1.34 pooka }
1666 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1667 1.103 pooka __weak_alias(fchmod,rump___sysimpl_fchmod);
1668 1.103 pooka __weak_alias(_fchmod,rump___sysimpl_fchmod);
1669 1.103 pooka __strong_alias(_sys_fchmod,rump___sysimpl_fchmod);
1670 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1671 1.34 pooka
1672 1.60 pooka int rump___sysimpl_setreuid(uid_t, uid_t);
1673 1.49 pooka int
1674 1.60 pooka rump___sysimpl_setreuid(uid_t ruid, uid_t euid)
1675 1.49 pooka {
1676 1.93 pooka register_t retval[2];
1677 1.49 pooka int error = 0;
1678 1.68 pooka int rv = -1;
1679 1.49 pooka struct sys_setreuid_args callarg;
1680 1.49 pooka
1681 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1682 1.49 pooka SPARG(&callarg, ruid) = ruid;
1683 1.49 pooka SPARG(&callarg, euid) = euid;
1684 1.49 pooka
1685 1.120 pgoyette error = rsys_syscall(SYS_setreuid, &callarg, sizeof(callarg), retval);
1686 1.63 pooka rsys_seterrno(error);
1687 1.68 pooka if (error == 0) {
1688 1.68 pooka if (sizeof(int) > sizeof(register_t))
1689 1.68 pooka rv = *(int *)retval;
1690 1.68 pooka else
1691 1.69 pooka rv = *retval;
1692 1.49 pooka }
1693 1.68 pooka return rv;
1694 1.49 pooka }
1695 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1696 1.103 pooka __weak_alias(setreuid,rump___sysimpl_setreuid);
1697 1.103 pooka __weak_alias(_setreuid,rump___sysimpl_setreuid);
1698 1.103 pooka __strong_alias(_sys_setreuid,rump___sysimpl_setreuid);
1699 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1700 1.49 pooka
1701 1.60 pooka int rump___sysimpl_setregid(gid_t, gid_t);
1702 1.49 pooka int
1703 1.60 pooka rump___sysimpl_setregid(gid_t rgid, gid_t egid)
1704 1.49 pooka {
1705 1.93 pooka register_t retval[2];
1706 1.49 pooka int error = 0;
1707 1.68 pooka int rv = -1;
1708 1.49 pooka struct sys_setregid_args callarg;
1709 1.49 pooka
1710 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1711 1.49 pooka SPARG(&callarg, rgid) = rgid;
1712 1.49 pooka SPARG(&callarg, egid) = egid;
1713 1.49 pooka
1714 1.120 pgoyette error = rsys_syscall(SYS_setregid, &callarg, sizeof(callarg), retval);
1715 1.63 pooka rsys_seterrno(error);
1716 1.68 pooka if (error == 0) {
1717 1.68 pooka if (sizeof(int) > sizeof(register_t))
1718 1.68 pooka rv = *(int *)retval;
1719 1.68 pooka else
1720 1.69 pooka rv = *retval;
1721 1.49 pooka }
1722 1.68 pooka return rv;
1723 1.49 pooka }
1724 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1725 1.103 pooka __weak_alias(setregid,rump___sysimpl_setregid);
1726 1.103 pooka __weak_alias(_setregid,rump___sysimpl_setregid);
1727 1.103 pooka __strong_alias(_sys_setregid,rump___sysimpl_setregid);
1728 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1729 1.49 pooka
1730 1.60 pooka int rump___sysimpl_rename(const char *, const char *);
1731 1.18 pooka int
1732 1.60 pooka rump___sysimpl_rename(const char * from, const char * to)
1733 1.1 pooka {
1734 1.93 pooka register_t retval[2];
1735 1.27 pooka int error = 0;
1736 1.68 pooka int rv = -1;
1737 1.31 pooka struct sys_rename_args callarg;
1738 1.1 pooka
1739 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1740 1.31 pooka SPARG(&callarg, from) = from;
1741 1.31 pooka SPARG(&callarg, to) = to;
1742 1.1 pooka
1743 1.120 pgoyette error = rsys_syscall(SYS_rename, &callarg, sizeof(callarg), retval);
1744 1.63 pooka rsys_seterrno(error);
1745 1.68 pooka if (error == 0) {
1746 1.68 pooka if (sizeof(int) > sizeof(register_t))
1747 1.68 pooka rv = *(int *)retval;
1748 1.68 pooka else
1749 1.69 pooka rv = *retval;
1750 1.27 pooka }
1751 1.68 pooka return rv;
1752 1.1 pooka }
1753 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1754 1.103 pooka __weak_alias(rename,rump___sysimpl_rename);
1755 1.103 pooka __weak_alias(_rename,rump___sysimpl_rename);
1756 1.103 pooka __strong_alias(_sys_rename,rump___sysimpl_rename);
1757 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1758 1.1 pooka
1759 1.60 pooka int rump___sysimpl_flock(int, int);
1760 1.34 pooka int
1761 1.60 pooka rump___sysimpl_flock(int fd, int how)
1762 1.34 pooka {
1763 1.93 pooka register_t retval[2];
1764 1.34 pooka int error = 0;
1765 1.68 pooka int rv = -1;
1766 1.34 pooka struct sys_flock_args callarg;
1767 1.34 pooka
1768 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1769 1.34 pooka SPARG(&callarg, fd) = fd;
1770 1.34 pooka SPARG(&callarg, how) = how;
1771 1.34 pooka
1772 1.120 pgoyette error = rsys_syscall(SYS_flock, &callarg, sizeof(callarg), retval);
1773 1.63 pooka rsys_seterrno(error);
1774 1.68 pooka if (error == 0) {
1775 1.68 pooka if (sizeof(int) > sizeof(register_t))
1776 1.68 pooka rv = *(int *)retval;
1777 1.68 pooka else
1778 1.69 pooka rv = *retval;
1779 1.34 pooka }
1780 1.68 pooka return rv;
1781 1.34 pooka }
1782 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1783 1.103 pooka __weak_alias(flock,rump___sysimpl_flock);
1784 1.103 pooka __weak_alias(_flock,rump___sysimpl_flock);
1785 1.103 pooka __strong_alias(_sys_flock,rump___sysimpl_flock);
1786 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1787 1.34 pooka
1788 1.60 pooka int rump___sysimpl_mkfifo(const char *, mode_t);
1789 1.1 pooka int
1790 1.60 pooka rump___sysimpl_mkfifo(const char * path, mode_t mode)
1791 1.10 pooka {
1792 1.93 pooka register_t retval[2];
1793 1.27 pooka int error = 0;
1794 1.68 pooka int rv = -1;
1795 1.31 pooka struct sys_mkfifo_args callarg;
1796 1.10 pooka
1797 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1798 1.31 pooka SPARG(&callarg, path) = path;
1799 1.31 pooka SPARG(&callarg, mode) = mode;
1800 1.10 pooka
1801 1.120 pgoyette error = rsys_syscall(SYS_mkfifo, &callarg, sizeof(callarg), retval);
1802 1.63 pooka rsys_seterrno(error);
1803 1.68 pooka if (error == 0) {
1804 1.68 pooka if (sizeof(int) > sizeof(register_t))
1805 1.68 pooka rv = *(int *)retval;
1806 1.68 pooka else
1807 1.69 pooka rv = *retval;
1808 1.27 pooka }
1809 1.68 pooka return rv;
1810 1.10 pooka }
1811 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1812 1.103 pooka __weak_alias(mkfifo,rump___sysimpl_mkfifo);
1813 1.103 pooka __weak_alias(_mkfifo,rump___sysimpl_mkfifo);
1814 1.103 pooka __strong_alias(_sys_mkfifo,rump___sysimpl_mkfifo);
1815 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1816 1.10 pooka
1817 1.72 christos ssize_t rump___sysimpl_sendto(int, const void *, size_t, int, const struct sockaddr *, socklen_t);
1818 1.28 pooka ssize_t
1819 1.72 christos rump___sysimpl_sendto(int s, const void * buf, size_t len, int flags, const struct sockaddr * to, socklen_t tolen)
1820 1.28 pooka {
1821 1.93 pooka register_t retval[2];
1822 1.28 pooka int error = 0;
1823 1.68 pooka ssize_t rv = -1;
1824 1.31 pooka struct sys_sendto_args callarg;
1825 1.28 pooka
1826 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1827 1.31 pooka SPARG(&callarg, s) = s;
1828 1.31 pooka SPARG(&callarg, buf) = buf;
1829 1.31 pooka SPARG(&callarg, len) = len;
1830 1.31 pooka SPARG(&callarg, flags) = flags;
1831 1.31 pooka SPARG(&callarg, to) = to;
1832 1.31 pooka SPARG(&callarg, tolen) = tolen;
1833 1.28 pooka
1834 1.120 pgoyette error = rsys_syscall(SYS_sendto, &callarg, sizeof(callarg), retval);
1835 1.63 pooka rsys_seterrno(error);
1836 1.68 pooka if (error == 0) {
1837 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
1838 1.68 pooka rv = *(ssize_t *)retval;
1839 1.68 pooka else
1840 1.69 pooka rv = *retval;
1841 1.28 pooka }
1842 1.68 pooka return rv;
1843 1.28 pooka }
1844 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1845 1.103 pooka __weak_alias(sendto,rump___sysimpl_sendto);
1846 1.103 pooka __weak_alias(_sendto,rump___sysimpl_sendto);
1847 1.103 pooka __strong_alias(_sys_sendto,rump___sysimpl_sendto);
1848 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1849 1.28 pooka
1850 1.60 pooka int rump___sysimpl_shutdown(int, int);
1851 1.28 pooka int
1852 1.60 pooka rump___sysimpl_shutdown(int s, int how)
1853 1.28 pooka {
1854 1.93 pooka register_t retval[2];
1855 1.28 pooka int error = 0;
1856 1.68 pooka int rv = -1;
1857 1.31 pooka struct sys_shutdown_args callarg;
1858 1.28 pooka
1859 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1860 1.31 pooka SPARG(&callarg, s) = s;
1861 1.31 pooka SPARG(&callarg, how) = how;
1862 1.28 pooka
1863 1.120 pgoyette error = rsys_syscall(SYS_shutdown, &callarg, sizeof(callarg), retval);
1864 1.63 pooka rsys_seterrno(error);
1865 1.68 pooka if (error == 0) {
1866 1.68 pooka if (sizeof(int) > sizeof(register_t))
1867 1.68 pooka rv = *(int *)retval;
1868 1.68 pooka else
1869 1.69 pooka rv = *retval;
1870 1.28 pooka }
1871 1.68 pooka return rv;
1872 1.28 pooka }
1873 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1874 1.103 pooka __weak_alias(shutdown,rump___sysimpl_shutdown);
1875 1.103 pooka __weak_alias(_shutdown,rump___sysimpl_shutdown);
1876 1.103 pooka __strong_alias(_sys_shutdown,rump___sysimpl_shutdown);
1877 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1878 1.28 pooka
1879 1.60 pooka int rump___sysimpl_socketpair(int, int, int, int *);
1880 1.28 pooka int
1881 1.60 pooka rump___sysimpl_socketpair(int domain, int type, int protocol, int * rsv)
1882 1.28 pooka {
1883 1.93 pooka register_t retval[2];
1884 1.28 pooka int error = 0;
1885 1.68 pooka int rv = -1;
1886 1.31 pooka struct sys_socketpair_args callarg;
1887 1.28 pooka
1888 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1889 1.31 pooka SPARG(&callarg, domain) = domain;
1890 1.31 pooka SPARG(&callarg, type) = type;
1891 1.31 pooka SPARG(&callarg, protocol) = protocol;
1892 1.31 pooka SPARG(&callarg, rsv) = rsv;
1893 1.28 pooka
1894 1.120 pgoyette error = rsys_syscall(SYS_socketpair, &callarg, sizeof(callarg), retval);
1895 1.63 pooka rsys_seterrno(error);
1896 1.68 pooka if (error == 0) {
1897 1.68 pooka if (sizeof(int) > sizeof(register_t))
1898 1.68 pooka rv = *(int *)retval;
1899 1.68 pooka else
1900 1.69 pooka rv = *retval;
1901 1.34 pooka }
1902 1.68 pooka return rv;
1903 1.34 pooka }
1904 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1905 1.103 pooka __weak_alias(socketpair,rump___sysimpl_socketpair);
1906 1.103 pooka __weak_alias(_socketpair,rump___sysimpl_socketpair);
1907 1.103 pooka __strong_alias(_sys_socketpair,rump___sysimpl_socketpair);
1908 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1909 1.34 pooka
1910 1.60 pooka int rump___sysimpl_mkdir(const char *, mode_t);
1911 1.34 pooka int
1912 1.60 pooka rump___sysimpl_mkdir(const char * path, mode_t mode)
1913 1.34 pooka {
1914 1.93 pooka register_t retval[2];
1915 1.34 pooka int error = 0;
1916 1.68 pooka int rv = -1;
1917 1.34 pooka struct sys_mkdir_args callarg;
1918 1.34 pooka
1919 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1920 1.34 pooka SPARG(&callarg, path) = path;
1921 1.34 pooka SPARG(&callarg, mode) = mode;
1922 1.34 pooka
1923 1.120 pgoyette error = rsys_syscall(SYS_mkdir, &callarg, sizeof(callarg), retval);
1924 1.63 pooka rsys_seterrno(error);
1925 1.68 pooka if (error == 0) {
1926 1.68 pooka if (sizeof(int) > sizeof(register_t))
1927 1.68 pooka rv = *(int *)retval;
1928 1.68 pooka else
1929 1.69 pooka rv = *retval;
1930 1.34 pooka }
1931 1.68 pooka return rv;
1932 1.34 pooka }
1933 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1934 1.103 pooka __weak_alias(mkdir,rump___sysimpl_mkdir);
1935 1.103 pooka __weak_alias(_mkdir,rump___sysimpl_mkdir);
1936 1.103 pooka __strong_alias(_sys_mkdir,rump___sysimpl_mkdir);
1937 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1938 1.34 pooka
1939 1.60 pooka int rump___sysimpl_rmdir(const char *);
1940 1.34 pooka int
1941 1.60 pooka rump___sysimpl_rmdir(const char * path)
1942 1.34 pooka {
1943 1.93 pooka register_t retval[2];
1944 1.34 pooka int error = 0;
1945 1.68 pooka int rv = -1;
1946 1.34 pooka struct sys_rmdir_args callarg;
1947 1.34 pooka
1948 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1949 1.34 pooka SPARG(&callarg, path) = path;
1950 1.34 pooka
1951 1.120 pgoyette error = rsys_syscall(SYS_rmdir, &callarg, sizeof(callarg), retval);
1952 1.63 pooka rsys_seterrno(error);
1953 1.68 pooka if (error == 0) {
1954 1.68 pooka if (sizeof(int) > sizeof(register_t))
1955 1.68 pooka rv = *(int *)retval;
1956 1.68 pooka else
1957 1.69 pooka rv = *retval;
1958 1.34 pooka }
1959 1.68 pooka return rv;
1960 1.34 pooka }
1961 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1962 1.103 pooka __weak_alias(rmdir,rump___sysimpl_rmdir);
1963 1.103 pooka __weak_alias(_rmdir,rump___sysimpl_rmdir);
1964 1.103 pooka __strong_alias(_sys_rmdir,rump___sysimpl_rmdir);
1965 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1966 1.34 pooka
1967 1.103 pooka #ifdef RUMP_SYS_COMPAT
1968 1.60 pooka int rump___sysimpl_utimes(const char *, const struct timeval *);
1969 1.60 pooka int
1970 1.60 pooka rump___sysimpl_utimes(const char * path, const struct timeval * tptr)
1971 1.60 pooka {
1972 1.93 pooka register_t retval[2];
1973 1.60 pooka int error = 0;
1974 1.68 pooka int rv = -1;
1975 1.60 pooka struct compat_50_sys_utimes_args callarg;
1976 1.60 pooka
1977 1.95 pooka memset(&callarg, 0, sizeof(callarg));
1978 1.60 pooka SPARG(&callarg, path) = path;
1979 1.60 pooka SPARG(&callarg, tptr) = (const struct timeval50 *)tptr;
1980 1.60 pooka
1981 1.120 pgoyette error = rsys_syscall(SYS_compat_50_utimes, &callarg, sizeof(callarg), retval);
1982 1.63 pooka rsys_seterrno(error);
1983 1.68 pooka if (error == 0) {
1984 1.68 pooka if (sizeof(int) > sizeof(register_t))
1985 1.68 pooka rv = *(int *)retval;
1986 1.68 pooka else
1987 1.69 pooka rv = *retval;
1988 1.60 pooka }
1989 1.68 pooka return rv;
1990 1.60 pooka }
1991 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
1992 1.103 pooka __weak_alias(utimes,rump___sysimpl_utimes);
1993 1.103 pooka __weak_alias(_utimes,rump___sysimpl_utimes);
1994 1.103 pooka __strong_alias(_sys_utimes,rump___sysimpl_utimes);
1995 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
1996 1.103 pooka #endif /* RUMP_SYS_COMPAT */
1997 1.60 pooka
1998 1.60 pooka int rump___sysimpl_setsid(void);
1999 1.49 pooka int
2000 1.60 pooka rump___sysimpl_setsid(void )
2001 1.49 pooka {
2002 1.93 pooka register_t retval[2];
2003 1.49 pooka int error = 0;
2004 1.68 pooka int rv = -1;
2005 1.49 pooka
2006 1.120 pgoyette error = rsys_syscall(SYS_setsid, NULL, 0, retval);
2007 1.63 pooka rsys_seterrno(error);
2008 1.68 pooka if (error == 0) {
2009 1.68 pooka if (sizeof(int) > sizeof(register_t))
2010 1.68 pooka rv = *(int *)retval;
2011 1.68 pooka else
2012 1.69 pooka rv = *retval;
2013 1.49 pooka }
2014 1.68 pooka return rv;
2015 1.49 pooka }
2016 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2017 1.103 pooka __weak_alias(setsid,rump___sysimpl_setsid);
2018 1.103 pooka __weak_alias(_setsid,rump___sysimpl_setsid);
2019 1.103 pooka __strong_alias(_sys_setsid,rump___sysimpl_setsid);
2020 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2021 1.49 pooka
2022 1.60 pooka int rump___sysimpl_nfssvc(int, void *);
2023 1.34 pooka int
2024 1.60 pooka rump___sysimpl_nfssvc(int flag, void * argp)
2025 1.34 pooka {
2026 1.93 pooka register_t retval[2];
2027 1.34 pooka int error = 0;
2028 1.68 pooka int rv = -1;
2029 1.34 pooka struct sys_nfssvc_args callarg;
2030 1.34 pooka
2031 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2032 1.34 pooka SPARG(&callarg, flag) = flag;
2033 1.34 pooka SPARG(&callarg, argp) = argp;
2034 1.34 pooka
2035 1.120 pgoyette error = rsys_syscall(SYS_nfssvc, &callarg, sizeof(callarg), retval);
2036 1.63 pooka rsys_seterrno(error);
2037 1.68 pooka if (error == 0) {
2038 1.68 pooka if (sizeof(int) > sizeof(register_t))
2039 1.68 pooka rv = *(int *)retval;
2040 1.68 pooka else
2041 1.69 pooka rv = *retval;
2042 1.34 pooka }
2043 1.68 pooka return rv;
2044 1.34 pooka }
2045 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2046 1.103 pooka __weak_alias(nfssvc,rump___sysimpl_nfssvc);
2047 1.103 pooka __weak_alias(_nfssvc,rump___sysimpl_nfssvc);
2048 1.103 pooka __strong_alias(_sys_nfssvc,rump___sysimpl_nfssvc);
2049 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2050 1.34 pooka
2051 1.60 pooka ssize_t rump___sysimpl_pread(int, void *, size_t, off_t);
2052 1.34 pooka ssize_t
2053 1.60 pooka rump___sysimpl_pread(int fd, void * buf, size_t nbyte, off_t offset)
2054 1.34 pooka {
2055 1.93 pooka register_t retval[2];
2056 1.34 pooka int error = 0;
2057 1.68 pooka ssize_t rv = -1;
2058 1.34 pooka struct sys_pread_args callarg;
2059 1.34 pooka
2060 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2061 1.34 pooka SPARG(&callarg, fd) = fd;
2062 1.34 pooka SPARG(&callarg, buf) = buf;
2063 1.34 pooka SPARG(&callarg, nbyte) = nbyte;
2064 1.35 pooka SPARG(&callarg, PAD) = 0;
2065 1.34 pooka SPARG(&callarg, offset) = offset;
2066 1.34 pooka
2067 1.120 pgoyette error = rsys_syscall(SYS_pread, &callarg, sizeof(callarg), retval);
2068 1.63 pooka rsys_seterrno(error);
2069 1.68 pooka if (error == 0) {
2070 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
2071 1.68 pooka rv = *(ssize_t *)retval;
2072 1.68 pooka else
2073 1.69 pooka rv = *retval;
2074 1.34 pooka }
2075 1.68 pooka return rv;
2076 1.34 pooka }
2077 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2078 1.103 pooka __weak_alias(pread,rump___sysimpl_pread);
2079 1.103 pooka __weak_alias(_pread,rump___sysimpl_pread);
2080 1.103 pooka __strong_alias(_sys_pread,rump___sysimpl_pread);
2081 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2082 1.34 pooka
2083 1.60 pooka ssize_t rump___sysimpl_pwrite(int, const void *, size_t, off_t);
2084 1.34 pooka ssize_t
2085 1.60 pooka rump___sysimpl_pwrite(int fd, const void * buf, size_t nbyte, off_t offset)
2086 1.34 pooka {
2087 1.93 pooka register_t retval[2];
2088 1.34 pooka int error = 0;
2089 1.68 pooka ssize_t rv = -1;
2090 1.34 pooka struct sys_pwrite_args callarg;
2091 1.34 pooka
2092 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2093 1.34 pooka SPARG(&callarg, fd) = fd;
2094 1.34 pooka SPARG(&callarg, buf) = buf;
2095 1.34 pooka SPARG(&callarg, nbyte) = nbyte;
2096 1.35 pooka SPARG(&callarg, PAD) = 0;
2097 1.34 pooka SPARG(&callarg, offset) = offset;
2098 1.34 pooka
2099 1.120 pgoyette error = rsys_syscall(SYS_pwrite, &callarg, sizeof(callarg), retval);
2100 1.63 pooka rsys_seterrno(error);
2101 1.68 pooka if (error == 0) {
2102 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
2103 1.68 pooka rv = *(ssize_t *)retval;
2104 1.68 pooka else
2105 1.69 pooka rv = *retval;
2106 1.34 pooka }
2107 1.68 pooka return rv;
2108 1.34 pooka }
2109 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2110 1.103 pooka __weak_alias(pwrite,rump___sysimpl_pwrite);
2111 1.103 pooka __weak_alias(_pwrite,rump___sysimpl_pwrite);
2112 1.103 pooka __strong_alias(_sys_pwrite,rump___sysimpl_pwrite);
2113 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2114 1.34 pooka
2115 1.60 pooka int rump___sysimpl_setgid(gid_t);
2116 1.49 pooka int
2117 1.60 pooka rump___sysimpl_setgid(gid_t gid)
2118 1.49 pooka {
2119 1.93 pooka register_t retval[2];
2120 1.49 pooka int error = 0;
2121 1.68 pooka int rv = -1;
2122 1.49 pooka struct sys_setgid_args callarg;
2123 1.49 pooka
2124 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2125 1.49 pooka SPARG(&callarg, gid) = gid;
2126 1.49 pooka
2127 1.120 pgoyette error = rsys_syscall(SYS_setgid, &callarg, sizeof(callarg), retval);
2128 1.63 pooka rsys_seterrno(error);
2129 1.68 pooka if (error == 0) {
2130 1.68 pooka if (sizeof(int) > sizeof(register_t))
2131 1.68 pooka rv = *(int *)retval;
2132 1.68 pooka else
2133 1.69 pooka rv = *retval;
2134 1.49 pooka }
2135 1.68 pooka return rv;
2136 1.49 pooka }
2137 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2138 1.103 pooka __weak_alias(setgid,rump___sysimpl_setgid);
2139 1.103 pooka __weak_alias(_setgid,rump___sysimpl_setgid);
2140 1.103 pooka __strong_alias(_sys_setgid,rump___sysimpl_setgid);
2141 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2142 1.49 pooka
2143 1.60 pooka int rump___sysimpl_setegid(gid_t);
2144 1.49 pooka int
2145 1.60 pooka rump___sysimpl_setegid(gid_t egid)
2146 1.49 pooka {
2147 1.93 pooka register_t retval[2];
2148 1.49 pooka int error = 0;
2149 1.68 pooka int rv = -1;
2150 1.49 pooka struct sys_setegid_args callarg;
2151 1.49 pooka
2152 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2153 1.49 pooka SPARG(&callarg, egid) = egid;
2154 1.49 pooka
2155 1.120 pgoyette error = rsys_syscall(SYS_setegid, &callarg, sizeof(callarg), retval);
2156 1.63 pooka rsys_seterrno(error);
2157 1.68 pooka if (error == 0) {
2158 1.68 pooka if (sizeof(int) > sizeof(register_t))
2159 1.68 pooka rv = *(int *)retval;
2160 1.68 pooka else
2161 1.69 pooka rv = *retval;
2162 1.49 pooka }
2163 1.68 pooka return rv;
2164 1.49 pooka }
2165 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2166 1.103 pooka __weak_alias(setegid,rump___sysimpl_setegid);
2167 1.103 pooka __weak_alias(_setegid,rump___sysimpl_setegid);
2168 1.103 pooka __strong_alias(_sys_setegid,rump___sysimpl_setegid);
2169 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2170 1.49 pooka
2171 1.60 pooka int rump___sysimpl_seteuid(uid_t);
2172 1.49 pooka int
2173 1.60 pooka rump___sysimpl_seteuid(uid_t euid)
2174 1.49 pooka {
2175 1.93 pooka register_t retval[2];
2176 1.49 pooka int error = 0;
2177 1.68 pooka int rv = -1;
2178 1.49 pooka struct sys_seteuid_args callarg;
2179 1.49 pooka
2180 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2181 1.49 pooka SPARG(&callarg, euid) = euid;
2182 1.49 pooka
2183 1.120 pgoyette error = rsys_syscall(SYS_seteuid, &callarg, sizeof(callarg), retval);
2184 1.63 pooka rsys_seterrno(error);
2185 1.68 pooka if (error == 0) {
2186 1.68 pooka if (sizeof(int) > sizeof(register_t))
2187 1.68 pooka rv = *(int *)retval;
2188 1.68 pooka else
2189 1.69 pooka rv = *retval;
2190 1.49 pooka }
2191 1.68 pooka return rv;
2192 1.49 pooka }
2193 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2194 1.103 pooka __weak_alias(seteuid,rump___sysimpl_seteuid);
2195 1.103 pooka __weak_alias(_seteuid,rump___sysimpl_seteuid);
2196 1.103 pooka __strong_alias(_sys_seteuid,rump___sysimpl_seteuid);
2197 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2198 1.49 pooka
2199 1.60 pooka long rump___sysimpl_pathconf(const char *, int);
2200 1.45 njoly long
2201 1.60 pooka rump___sysimpl_pathconf(const char * path, int name)
2202 1.45 njoly {
2203 1.93 pooka register_t retval[2];
2204 1.45 njoly int error = 0;
2205 1.68 pooka long rv = -1;
2206 1.45 njoly struct sys_pathconf_args callarg;
2207 1.45 njoly
2208 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2209 1.45 njoly SPARG(&callarg, path) = path;
2210 1.45 njoly SPARG(&callarg, name) = name;
2211 1.45 njoly
2212 1.120 pgoyette error = rsys_syscall(SYS_pathconf, &callarg, sizeof(callarg), retval);
2213 1.63 pooka rsys_seterrno(error);
2214 1.68 pooka if (error == 0) {
2215 1.68 pooka if (sizeof(long) > sizeof(register_t))
2216 1.68 pooka rv = *(long *)retval;
2217 1.68 pooka else
2218 1.69 pooka rv = *retval;
2219 1.45 njoly }
2220 1.68 pooka return rv;
2221 1.45 njoly }
2222 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2223 1.103 pooka __weak_alias(pathconf,rump___sysimpl_pathconf);
2224 1.103 pooka __weak_alias(_pathconf,rump___sysimpl_pathconf);
2225 1.103 pooka __strong_alias(_sys_pathconf,rump___sysimpl_pathconf);
2226 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2227 1.45 njoly
2228 1.60 pooka long rump___sysimpl_fpathconf(int, int);
2229 1.45 njoly long
2230 1.60 pooka rump___sysimpl_fpathconf(int fd, int name)
2231 1.45 njoly {
2232 1.93 pooka register_t retval[2];
2233 1.45 njoly int error = 0;
2234 1.68 pooka long rv = -1;
2235 1.45 njoly struct sys_fpathconf_args callarg;
2236 1.45 njoly
2237 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2238 1.45 njoly SPARG(&callarg, fd) = fd;
2239 1.45 njoly SPARG(&callarg, name) = name;
2240 1.45 njoly
2241 1.120 pgoyette error = rsys_syscall(SYS_fpathconf, &callarg, sizeof(callarg), retval);
2242 1.63 pooka rsys_seterrno(error);
2243 1.68 pooka if (error == 0) {
2244 1.68 pooka if (sizeof(long) > sizeof(register_t))
2245 1.68 pooka rv = *(long *)retval;
2246 1.68 pooka else
2247 1.69 pooka rv = *retval;
2248 1.45 njoly }
2249 1.68 pooka return rv;
2250 1.45 njoly }
2251 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2252 1.103 pooka __weak_alias(fpathconf,rump___sysimpl_fpathconf);
2253 1.103 pooka __weak_alias(_fpathconf,rump___sysimpl_fpathconf);
2254 1.103 pooka __strong_alias(_sys_fpathconf,rump___sysimpl_fpathconf);
2255 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2256 1.45 njoly
2257 1.139 rjs int rump___sysimpl_getsockopt2(int, int, int, void *, socklen_t *);
2258 1.139 rjs int
2259 1.139 rjs rump___sysimpl_getsockopt2(int s, int level, int name, void * val, socklen_t * avalsize)
2260 1.139 rjs {
2261 1.139 rjs register_t retval[2];
2262 1.139 rjs int error = 0;
2263 1.139 rjs int rv = -1;
2264 1.139 rjs struct sys_getsockopt2_args callarg;
2265 1.139 rjs
2266 1.139 rjs memset(&callarg, 0, sizeof(callarg));
2267 1.139 rjs SPARG(&callarg, s) = s;
2268 1.139 rjs SPARG(&callarg, level) = level;
2269 1.139 rjs SPARG(&callarg, name) = name;
2270 1.139 rjs SPARG(&callarg, val) = val;
2271 1.139 rjs SPARG(&callarg, avalsize) = avalsize;
2272 1.139 rjs
2273 1.139 rjs error = rsys_syscall(SYS_getsockopt2, &callarg, sizeof(callarg), retval);
2274 1.139 rjs rsys_seterrno(error);
2275 1.139 rjs if (error == 0) {
2276 1.139 rjs if (sizeof(int) > sizeof(register_t))
2277 1.139 rjs rv = *(int *)retval;
2278 1.139 rjs else
2279 1.139 rjs rv = *retval;
2280 1.139 rjs }
2281 1.139 rjs return rv;
2282 1.139 rjs }
2283 1.139 rjs #ifdef RUMP_KERNEL_IS_LIBC
2284 1.139 rjs __weak_alias(getsockopt2,rump___sysimpl_getsockopt2);
2285 1.139 rjs __weak_alias(_getsockopt2,rump___sysimpl_getsockopt2);
2286 1.139 rjs __strong_alias(_sys_getsockopt2,rump___sysimpl_getsockopt2);
2287 1.139 rjs #endif /* RUMP_KERNEL_IS_LIBC */
2288 1.139 rjs
2289 1.60 pooka int rump___sysimpl_getrlimit(int, struct rlimit *);
2290 1.42 pooka int
2291 1.60 pooka rump___sysimpl_getrlimit(int which, struct rlimit * rlp)
2292 1.42 pooka {
2293 1.93 pooka register_t retval[2];
2294 1.42 pooka int error = 0;
2295 1.68 pooka int rv = -1;
2296 1.42 pooka struct sys_getrlimit_args callarg;
2297 1.42 pooka
2298 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2299 1.42 pooka SPARG(&callarg, which) = which;
2300 1.42 pooka SPARG(&callarg, rlp) = rlp;
2301 1.42 pooka
2302 1.120 pgoyette error = rsys_syscall(SYS_getrlimit, &callarg, sizeof(callarg), retval);
2303 1.63 pooka rsys_seterrno(error);
2304 1.68 pooka if (error == 0) {
2305 1.68 pooka if (sizeof(int) > sizeof(register_t))
2306 1.68 pooka rv = *(int *)retval;
2307 1.68 pooka else
2308 1.69 pooka rv = *retval;
2309 1.42 pooka }
2310 1.68 pooka return rv;
2311 1.42 pooka }
2312 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2313 1.103 pooka __weak_alias(getrlimit,rump___sysimpl_getrlimit);
2314 1.103 pooka __weak_alias(_getrlimit,rump___sysimpl_getrlimit);
2315 1.103 pooka __strong_alias(_sys_getrlimit,rump___sysimpl_getrlimit);
2316 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2317 1.42 pooka
2318 1.60 pooka int rump___sysimpl_setrlimit(int, const struct rlimit *);
2319 1.42 pooka int
2320 1.60 pooka rump___sysimpl_setrlimit(int which, const struct rlimit * rlp)
2321 1.42 pooka {
2322 1.93 pooka register_t retval[2];
2323 1.42 pooka int error = 0;
2324 1.68 pooka int rv = -1;
2325 1.42 pooka struct sys_setrlimit_args callarg;
2326 1.42 pooka
2327 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2328 1.42 pooka SPARG(&callarg, which) = which;
2329 1.42 pooka SPARG(&callarg, rlp) = rlp;
2330 1.42 pooka
2331 1.120 pgoyette error = rsys_syscall(SYS_setrlimit, &callarg, sizeof(callarg), retval);
2332 1.63 pooka rsys_seterrno(error);
2333 1.68 pooka if (error == 0) {
2334 1.68 pooka if (sizeof(int) > sizeof(register_t))
2335 1.68 pooka rv = *(int *)retval;
2336 1.68 pooka else
2337 1.69 pooka rv = *retval;
2338 1.42 pooka }
2339 1.68 pooka return rv;
2340 1.42 pooka }
2341 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2342 1.103 pooka __weak_alias(setrlimit,rump___sysimpl_setrlimit);
2343 1.103 pooka __weak_alias(_setrlimit,rump___sysimpl_setrlimit);
2344 1.103 pooka __strong_alias(_sys_setrlimit,rump___sysimpl_setrlimit);
2345 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2346 1.42 pooka
2347 1.60 pooka off_t rump___sysimpl_lseek(int, off_t, int);
2348 1.34 pooka off_t
2349 1.60 pooka rump___sysimpl_lseek(int fd, off_t offset, int whence)
2350 1.34 pooka {
2351 1.93 pooka register_t retval[2];
2352 1.34 pooka int error = 0;
2353 1.68 pooka off_t rv = -1;
2354 1.34 pooka struct sys_lseek_args callarg;
2355 1.34 pooka
2356 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2357 1.34 pooka SPARG(&callarg, fd) = fd;
2358 1.35 pooka SPARG(&callarg, PAD) = 0;
2359 1.34 pooka SPARG(&callarg, offset) = offset;
2360 1.34 pooka SPARG(&callarg, whence) = whence;
2361 1.34 pooka
2362 1.120 pgoyette error = rsys_syscall(SYS_lseek, &callarg, sizeof(callarg), retval);
2363 1.63 pooka rsys_seterrno(error);
2364 1.68 pooka if (error == 0) {
2365 1.68 pooka if (sizeof(off_t) > sizeof(register_t))
2366 1.68 pooka rv = *(off_t *)retval;
2367 1.68 pooka else
2368 1.69 pooka rv = *retval;
2369 1.34 pooka }
2370 1.68 pooka return rv;
2371 1.34 pooka }
2372 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2373 1.103 pooka __weak_alias(lseek,rump___sysimpl_lseek);
2374 1.103 pooka __weak_alias(_lseek,rump___sysimpl_lseek);
2375 1.103 pooka __strong_alias(_sys_lseek,rump___sysimpl_lseek);
2376 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2377 1.34 pooka
2378 1.60 pooka int rump___sysimpl_truncate(const char *, off_t);
2379 1.34 pooka int
2380 1.60 pooka rump___sysimpl_truncate(const char * path, off_t length)
2381 1.34 pooka {
2382 1.93 pooka register_t retval[2];
2383 1.34 pooka int error = 0;
2384 1.68 pooka int rv = -1;
2385 1.34 pooka struct sys_truncate_args callarg;
2386 1.34 pooka
2387 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2388 1.34 pooka SPARG(&callarg, path) = path;
2389 1.35 pooka SPARG(&callarg, PAD) = 0;
2390 1.34 pooka SPARG(&callarg, length) = length;
2391 1.34 pooka
2392 1.120 pgoyette error = rsys_syscall(SYS_truncate, &callarg, sizeof(callarg), retval);
2393 1.63 pooka rsys_seterrno(error);
2394 1.68 pooka if (error == 0) {
2395 1.68 pooka if (sizeof(int) > sizeof(register_t))
2396 1.68 pooka rv = *(int *)retval;
2397 1.68 pooka else
2398 1.69 pooka rv = *retval;
2399 1.34 pooka }
2400 1.68 pooka return rv;
2401 1.34 pooka }
2402 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2403 1.103 pooka __weak_alias(truncate,rump___sysimpl_truncate);
2404 1.103 pooka __weak_alias(_truncate,rump___sysimpl_truncate);
2405 1.103 pooka __strong_alias(_sys_truncate,rump___sysimpl_truncate);
2406 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2407 1.34 pooka
2408 1.60 pooka int rump___sysimpl_ftruncate(int, off_t);
2409 1.34 pooka int
2410 1.60 pooka rump___sysimpl_ftruncate(int fd, off_t length)
2411 1.34 pooka {
2412 1.93 pooka register_t retval[2];
2413 1.34 pooka int error = 0;
2414 1.68 pooka int rv = -1;
2415 1.34 pooka struct sys_ftruncate_args callarg;
2416 1.34 pooka
2417 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2418 1.34 pooka SPARG(&callarg, fd) = fd;
2419 1.35 pooka SPARG(&callarg, PAD) = 0;
2420 1.34 pooka SPARG(&callarg, length) = length;
2421 1.34 pooka
2422 1.120 pgoyette error = rsys_syscall(SYS_ftruncate, &callarg, sizeof(callarg), retval);
2423 1.63 pooka rsys_seterrno(error);
2424 1.68 pooka if (error == 0) {
2425 1.68 pooka if (sizeof(int) > sizeof(register_t))
2426 1.68 pooka rv = *(int *)retval;
2427 1.68 pooka else
2428 1.69 pooka rv = *retval;
2429 1.34 pooka }
2430 1.68 pooka return rv;
2431 1.34 pooka }
2432 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2433 1.103 pooka __weak_alias(ftruncate,rump___sysimpl_ftruncate);
2434 1.103 pooka __weak_alias(_ftruncate,rump___sysimpl_ftruncate);
2435 1.103 pooka __strong_alias(_sys_ftruncate,rump___sysimpl_ftruncate);
2436 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2437 1.34 pooka
2438 1.60 pooka int rump___sysimpl___sysctl(const int *, u_int, void *, size_t *, const void *, size_t);
2439 1.34 pooka int
2440 1.101 joerg rump___sysimpl___sysctl(const int * name, u_int namelen, void * oldv, size_t * oldlenp, const void * newv, size_t newlen)
2441 1.34 pooka {
2442 1.93 pooka register_t retval[2];
2443 1.34 pooka int error = 0;
2444 1.68 pooka int rv = -1;
2445 1.34 pooka struct sys___sysctl_args callarg;
2446 1.34 pooka
2447 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2448 1.34 pooka SPARG(&callarg, name) = name;
2449 1.34 pooka SPARG(&callarg, namelen) = namelen;
2450 1.101 joerg SPARG(&callarg, oldv) = oldv;
2451 1.34 pooka SPARG(&callarg, oldlenp) = oldlenp;
2452 1.101 joerg SPARG(&callarg, newv) = newv;
2453 1.34 pooka SPARG(&callarg, newlen) = newlen;
2454 1.34 pooka
2455 1.120 pgoyette error = rsys_syscall(SYS___sysctl, &callarg, sizeof(callarg), retval);
2456 1.63 pooka rsys_seterrno(error);
2457 1.68 pooka if (error == 0) {
2458 1.68 pooka if (sizeof(int) > sizeof(register_t))
2459 1.68 pooka rv = *(int *)retval;
2460 1.68 pooka else
2461 1.69 pooka rv = *retval;
2462 1.34 pooka }
2463 1.68 pooka return rv;
2464 1.34 pooka }
2465 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2466 1.103 pooka __weak_alias(__sysctl,rump___sysimpl___sysctl);
2467 1.103 pooka __weak_alias(___sysctl,rump___sysimpl___sysctl);
2468 1.103 pooka __strong_alias(_sys___sysctl,rump___sysimpl___sysctl);
2469 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2470 1.34 pooka
2471 1.103 pooka #ifdef RUMP_SYS_COMPAT
2472 1.60 pooka int rump___sysimpl_futimes(int, const struct timeval *);
2473 1.60 pooka int
2474 1.60 pooka rump___sysimpl_futimes(int fd, const struct timeval * tptr)
2475 1.60 pooka {
2476 1.93 pooka register_t retval[2];
2477 1.60 pooka int error = 0;
2478 1.68 pooka int rv = -1;
2479 1.60 pooka struct compat_50_sys_futimes_args callarg;
2480 1.60 pooka
2481 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2482 1.60 pooka SPARG(&callarg, fd) = fd;
2483 1.60 pooka SPARG(&callarg, tptr) = (const struct timeval50 *)tptr;
2484 1.60 pooka
2485 1.120 pgoyette error = rsys_syscall(SYS_compat_50_futimes, &callarg, sizeof(callarg), retval);
2486 1.63 pooka rsys_seterrno(error);
2487 1.68 pooka if (error == 0) {
2488 1.68 pooka if (sizeof(int) > sizeof(register_t))
2489 1.68 pooka rv = *(int *)retval;
2490 1.68 pooka else
2491 1.69 pooka rv = *retval;
2492 1.60 pooka }
2493 1.68 pooka return rv;
2494 1.60 pooka }
2495 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2496 1.103 pooka __weak_alias(futimes,rump___sysimpl_futimes);
2497 1.103 pooka __weak_alias(_futimes,rump___sysimpl_futimes);
2498 1.103 pooka __strong_alias(_sys_futimes,rump___sysimpl_futimes);
2499 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2500 1.103 pooka #endif /* RUMP_SYS_COMPAT */
2501 1.60 pooka
2502 1.60 pooka pid_t rump___sysimpl_getpgid(pid_t);
2503 1.49 pooka pid_t
2504 1.60 pooka rump___sysimpl_getpgid(pid_t pid)
2505 1.49 pooka {
2506 1.93 pooka register_t retval[2];
2507 1.49 pooka int error = 0;
2508 1.68 pooka pid_t rv = -1;
2509 1.49 pooka struct sys_getpgid_args callarg;
2510 1.49 pooka
2511 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2512 1.49 pooka SPARG(&callarg, pid) = pid;
2513 1.49 pooka
2514 1.120 pgoyette error = rsys_syscall(SYS_getpgid, &callarg, sizeof(callarg), retval);
2515 1.63 pooka rsys_seterrno(error);
2516 1.68 pooka if (error == 0) {
2517 1.68 pooka if (sizeof(pid_t) > sizeof(register_t))
2518 1.68 pooka rv = *(pid_t *)retval;
2519 1.68 pooka else
2520 1.69 pooka rv = *retval;
2521 1.49 pooka }
2522 1.68 pooka return rv;
2523 1.49 pooka }
2524 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2525 1.103 pooka __weak_alias(getpgid,rump___sysimpl_getpgid);
2526 1.103 pooka __weak_alias(_getpgid,rump___sysimpl_getpgid);
2527 1.103 pooka __strong_alias(_sys_getpgid,rump___sysimpl_getpgid);
2528 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2529 1.49 pooka
2530 1.60 pooka int rump___sysimpl_reboot(int, char *);
2531 1.34 pooka int
2532 1.60 pooka rump___sysimpl_reboot(int opt, char * bootstr)
2533 1.34 pooka {
2534 1.93 pooka register_t retval[2];
2535 1.34 pooka int error = 0;
2536 1.68 pooka int rv = -1;
2537 1.34 pooka struct sys_reboot_args callarg;
2538 1.34 pooka
2539 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2540 1.34 pooka SPARG(&callarg, opt) = opt;
2541 1.34 pooka SPARG(&callarg, bootstr) = bootstr;
2542 1.34 pooka
2543 1.120 pgoyette error = rsys_syscall(SYS_reboot, &callarg, sizeof(callarg), retval);
2544 1.63 pooka rsys_seterrno(error);
2545 1.68 pooka if (error == 0) {
2546 1.68 pooka if (sizeof(int) > sizeof(register_t))
2547 1.68 pooka rv = *(int *)retval;
2548 1.68 pooka else
2549 1.69 pooka rv = *retval;
2550 1.34 pooka }
2551 1.68 pooka return rv;
2552 1.34 pooka }
2553 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2554 1.103 pooka __weak_alias(reboot,rump___sysimpl_reboot);
2555 1.103 pooka __weak_alias(_reboot,rump___sysimpl_reboot);
2556 1.103 pooka __strong_alias(_sys_reboot,rump___sysimpl_reboot);
2557 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2558 1.34 pooka
2559 1.60 pooka int rump___sysimpl_poll(struct pollfd *, u_int, int);
2560 1.34 pooka int
2561 1.60 pooka rump___sysimpl_poll(struct pollfd * fds, u_int nfds, int timeout)
2562 1.34 pooka {
2563 1.93 pooka register_t retval[2];
2564 1.34 pooka int error = 0;
2565 1.68 pooka int rv = -1;
2566 1.34 pooka struct sys_poll_args callarg;
2567 1.34 pooka
2568 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2569 1.34 pooka SPARG(&callarg, fds) = fds;
2570 1.34 pooka SPARG(&callarg, nfds) = nfds;
2571 1.34 pooka SPARG(&callarg, timeout) = timeout;
2572 1.34 pooka
2573 1.120 pgoyette error = rsys_syscall(SYS_poll, &callarg, sizeof(callarg), retval);
2574 1.63 pooka rsys_seterrno(error);
2575 1.68 pooka if (error == 0) {
2576 1.68 pooka if (sizeof(int) > sizeof(register_t))
2577 1.68 pooka rv = *(int *)retval;
2578 1.68 pooka else
2579 1.69 pooka rv = *retval;
2580 1.34 pooka }
2581 1.68 pooka return rv;
2582 1.34 pooka }
2583 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2584 1.103 pooka __weak_alias(poll,rump___sysimpl_poll);
2585 1.103 pooka __weak_alias(_poll,rump___sysimpl_poll);
2586 1.103 pooka __strong_alias(_sys_poll,rump___sysimpl_poll);
2587 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2588 1.34 pooka
2589 1.98 pooka int rump___sysimpl_timer_create(clockid_t, struct sigevent *, timer_t *);
2590 1.98 pooka int
2591 1.98 pooka rump___sysimpl_timer_create(clockid_t clock_id, struct sigevent * evp, timer_t * timerid)
2592 1.98 pooka {
2593 1.98 pooka register_t retval[2];
2594 1.98 pooka int error = 0;
2595 1.98 pooka int rv = -1;
2596 1.98 pooka struct sys_timer_create_args callarg;
2597 1.98 pooka
2598 1.98 pooka memset(&callarg, 0, sizeof(callarg));
2599 1.98 pooka SPARG(&callarg, clock_id) = clock_id;
2600 1.98 pooka SPARG(&callarg, evp) = evp;
2601 1.98 pooka SPARG(&callarg, timerid) = timerid;
2602 1.98 pooka
2603 1.120 pgoyette error = rsys_syscall(SYS_timer_create, &callarg, sizeof(callarg), retval);
2604 1.98 pooka rsys_seterrno(error);
2605 1.98 pooka if (error == 0) {
2606 1.98 pooka if (sizeof(int) > sizeof(register_t))
2607 1.98 pooka rv = *(int *)retval;
2608 1.98 pooka else
2609 1.98 pooka rv = *retval;
2610 1.98 pooka }
2611 1.98 pooka return rv;
2612 1.98 pooka }
2613 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2614 1.103 pooka __weak_alias(timer_create,rump___sysimpl_timer_create);
2615 1.103 pooka __weak_alias(_timer_create,rump___sysimpl_timer_create);
2616 1.103 pooka __strong_alias(_sys_timer_create,rump___sysimpl_timer_create);
2617 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2618 1.98 pooka
2619 1.98 pooka int rump___sysimpl_timer_delete(timer_t);
2620 1.98 pooka int
2621 1.98 pooka rump___sysimpl_timer_delete(timer_t timerid)
2622 1.98 pooka {
2623 1.98 pooka register_t retval[2];
2624 1.98 pooka int error = 0;
2625 1.98 pooka int rv = -1;
2626 1.98 pooka struct sys_timer_delete_args callarg;
2627 1.98 pooka
2628 1.98 pooka memset(&callarg, 0, sizeof(callarg));
2629 1.98 pooka SPARG(&callarg, timerid) = timerid;
2630 1.98 pooka
2631 1.120 pgoyette error = rsys_syscall(SYS_timer_delete, &callarg, sizeof(callarg), retval);
2632 1.98 pooka rsys_seterrno(error);
2633 1.98 pooka if (error == 0) {
2634 1.98 pooka if (sizeof(int) > sizeof(register_t))
2635 1.98 pooka rv = *(int *)retval;
2636 1.98 pooka else
2637 1.98 pooka rv = *retval;
2638 1.98 pooka }
2639 1.98 pooka return rv;
2640 1.98 pooka }
2641 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2642 1.103 pooka __weak_alias(timer_delete,rump___sysimpl_timer_delete);
2643 1.103 pooka __weak_alias(_timer_delete,rump___sysimpl_timer_delete);
2644 1.103 pooka __strong_alias(_sys_timer_delete,rump___sysimpl_timer_delete);
2645 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2646 1.98 pooka
2647 1.98 pooka int rump___sysimpl_timer_getoverrun(timer_t);
2648 1.98 pooka int
2649 1.98 pooka rump___sysimpl_timer_getoverrun(timer_t timerid)
2650 1.98 pooka {
2651 1.98 pooka register_t retval[2];
2652 1.98 pooka int error = 0;
2653 1.98 pooka int rv = -1;
2654 1.98 pooka struct sys_timer_getoverrun_args callarg;
2655 1.98 pooka
2656 1.98 pooka memset(&callarg, 0, sizeof(callarg));
2657 1.98 pooka SPARG(&callarg, timerid) = timerid;
2658 1.98 pooka
2659 1.120 pgoyette error = rsys_syscall(SYS_timer_getoverrun, &callarg, sizeof(callarg), retval);
2660 1.98 pooka rsys_seterrno(error);
2661 1.98 pooka if (error == 0) {
2662 1.98 pooka if (sizeof(int) > sizeof(register_t))
2663 1.98 pooka rv = *(int *)retval;
2664 1.98 pooka else
2665 1.98 pooka rv = *retval;
2666 1.98 pooka }
2667 1.98 pooka return rv;
2668 1.98 pooka }
2669 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2670 1.103 pooka __weak_alias(timer_getoverrun,rump___sysimpl_timer_getoverrun);
2671 1.103 pooka __weak_alias(_timer_getoverrun,rump___sysimpl_timer_getoverrun);
2672 1.103 pooka __strong_alias(_sys_timer_getoverrun,rump___sysimpl_timer_getoverrun);
2673 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2674 1.98 pooka
2675 1.60 pooka int rump___sysimpl_fdatasync(int);
2676 1.34 pooka int
2677 1.60 pooka rump___sysimpl_fdatasync(int fd)
2678 1.34 pooka {
2679 1.93 pooka register_t retval[2];
2680 1.34 pooka int error = 0;
2681 1.68 pooka int rv = -1;
2682 1.34 pooka struct sys_fdatasync_args callarg;
2683 1.34 pooka
2684 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2685 1.34 pooka SPARG(&callarg, fd) = fd;
2686 1.34 pooka
2687 1.120 pgoyette error = rsys_syscall(SYS_fdatasync, &callarg, sizeof(callarg), retval);
2688 1.63 pooka rsys_seterrno(error);
2689 1.68 pooka if (error == 0) {
2690 1.68 pooka if (sizeof(int) > sizeof(register_t))
2691 1.68 pooka rv = *(int *)retval;
2692 1.68 pooka else
2693 1.69 pooka rv = *retval;
2694 1.34 pooka }
2695 1.68 pooka return rv;
2696 1.34 pooka }
2697 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2698 1.103 pooka __weak_alias(fdatasync,rump___sysimpl_fdatasync);
2699 1.103 pooka __weak_alias(_fdatasync,rump___sysimpl_fdatasync);
2700 1.103 pooka __strong_alias(_sys_fdatasync,rump___sysimpl_fdatasync);
2701 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2702 1.34 pooka
2703 1.60 pooka int rump___sysimpl_modctl(int, void *);
2704 1.38 pooka int
2705 1.60 pooka rump___sysimpl_modctl(int cmd, void * arg)
2706 1.38 pooka {
2707 1.93 pooka register_t retval[2];
2708 1.38 pooka int error = 0;
2709 1.68 pooka int rv = -1;
2710 1.38 pooka struct sys_modctl_args callarg;
2711 1.38 pooka
2712 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2713 1.38 pooka SPARG(&callarg, cmd) = cmd;
2714 1.38 pooka SPARG(&callarg, arg) = arg;
2715 1.38 pooka
2716 1.120 pgoyette error = rsys_syscall(SYS_modctl, &callarg, sizeof(callarg), retval);
2717 1.63 pooka rsys_seterrno(error);
2718 1.68 pooka if (error == 0) {
2719 1.68 pooka if (sizeof(int) > sizeof(register_t))
2720 1.68 pooka rv = *(int *)retval;
2721 1.68 pooka else
2722 1.69 pooka rv = *retval;
2723 1.38 pooka }
2724 1.68 pooka return rv;
2725 1.38 pooka }
2726 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2727 1.103 pooka __weak_alias(modctl,rump___sysimpl_modctl);
2728 1.103 pooka __weak_alias(_modctl,rump___sysimpl_modctl);
2729 1.103 pooka __strong_alias(_sys_modctl,rump___sysimpl_modctl);
2730 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2731 1.38 pooka
2732 1.60 pooka int rump___sysimpl__ksem_init(unsigned int, intptr_t *);
2733 1.46 pooka int
2734 1.60 pooka rump___sysimpl__ksem_init(unsigned int value, intptr_t * idp)
2735 1.46 pooka {
2736 1.93 pooka register_t retval[2];
2737 1.46 pooka int error = 0;
2738 1.68 pooka int rv = -1;
2739 1.46 pooka struct sys__ksem_init_args callarg;
2740 1.46 pooka
2741 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2742 1.46 pooka SPARG(&callarg, value) = value;
2743 1.46 pooka SPARG(&callarg, idp) = idp;
2744 1.46 pooka
2745 1.120 pgoyette error = rsys_syscall(SYS__ksem_init, &callarg, sizeof(callarg), retval);
2746 1.63 pooka rsys_seterrno(error);
2747 1.68 pooka if (error == 0) {
2748 1.68 pooka if (sizeof(int) > sizeof(register_t))
2749 1.68 pooka rv = *(int *)retval;
2750 1.68 pooka else
2751 1.69 pooka rv = *retval;
2752 1.46 pooka }
2753 1.68 pooka return rv;
2754 1.46 pooka }
2755 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2756 1.103 pooka __weak_alias(_ksem_init,rump___sysimpl__ksem_init);
2757 1.103 pooka __weak_alias(__ksem_init,rump___sysimpl__ksem_init);
2758 1.103 pooka __strong_alias(_sys__ksem_init,rump___sysimpl__ksem_init);
2759 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2760 1.46 pooka
2761 1.60 pooka int rump___sysimpl__ksem_open(const char *, int, mode_t, unsigned int, intptr_t *);
2762 1.46 pooka int
2763 1.60 pooka rump___sysimpl__ksem_open(const char * name, int oflag, mode_t mode, unsigned int value, intptr_t * idp)
2764 1.46 pooka {
2765 1.93 pooka register_t retval[2];
2766 1.46 pooka int error = 0;
2767 1.68 pooka int rv = -1;
2768 1.46 pooka struct sys__ksem_open_args callarg;
2769 1.46 pooka
2770 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2771 1.46 pooka SPARG(&callarg, name) = name;
2772 1.46 pooka SPARG(&callarg, oflag) = oflag;
2773 1.46 pooka SPARG(&callarg, mode) = mode;
2774 1.46 pooka SPARG(&callarg, value) = value;
2775 1.46 pooka SPARG(&callarg, idp) = idp;
2776 1.46 pooka
2777 1.120 pgoyette error = rsys_syscall(SYS__ksem_open, &callarg, sizeof(callarg), retval);
2778 1.63 pooka rsys_seterrno(error);
2779 1.68 pooka if (error == 0) {
2780 1.68 pooka if (sizeof(int) > sizeof(register_t))
2781 1.68 pooka rv = *(int *)retval;
2782 1.68 pooka else
2783 1.69 pooka rv = *retval;
2784 1.46 pooka }
2785 1.68 pooka return rv;
2786 1.46 pooka }
2787 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2788 1.103 pooka __weak_alias(_ksem_open,rump___sysimpl__ksem_open);
2789 1.103 pooka __weak_alias(__ksem_open,rump___sysimpl__ksem_open);
2790 1.103 pooka __strong_alias(_sys__ksem_open,rump___sysimpl__ksem_open);
2791 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2792 1.46 pooka
2793 1.60 pooka int rump___sysimpl__ksem_unlink(const char *);
2794 1.46 pooka int
2795 1.60 pooka rump___sysimpl__ksem_unlink(const char * name)
2796 1.46 pooka {
2797 1.93 pooka register_t retval[2];
2798 1.46 pooka int error = 0;
2799 1.68 pooka int rv = -1;
2800 1.46 pooka struct sys__ksem_unlink_args callarg;
2801 1.46 pooka
2802 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2803 1.46 pooka SPARG(&callarg, name) = name;
2804 1.46 pooka
2805 1.120 pgoyette error = rsys_syscall(SYS__ksem_unlink, &callarg, sizeof(callarg), retval);
2806 1.63 pooka rsys_seterrno(error);
2807 1.68 pooka if (error == 0) {
2808 1.68 pooka if (sizeof(int) > sizeof(register_t))
2809 1.68 pooka rv = *(int *)retval;
2810 1.68 pooka else
2811 1.69 pooka rv = *retval;
2812 1.46 pooka }
2813 1.68 pooka return rv;
2814 1.46 pooka }
2815 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2816 1.103 pooka __weak_alias(_ksem_unlink,rump___sysimpl__ksem_unlink);
2817 1.103 pooka __weak_alias(__ksem_unlink,rump___sysimpl__ksem_unlink);
2818 1.103 pooka __strong_alias(_sys__ksem_unlink,rump___sysimpl__ksem_unlink);
2819 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2820 1.46 pooka
2821 1.60 pooka int rump___sysimpl__ksem_close(intptr_t);
2822 1.46 pooka int
2823 1.60 pooka rump___sysimpl__ksem_close(intptr_t id)
2824 1.46 pooka {
2825 1.93 pooka register_t retval[2];
2826 1.46 pooka int error = 0;
2827 1.68 pooka int rv = -1;
2828 1.46 pooka struct sys__ksem_close_args callarg;
2829 1.46 pooka
2830 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2831 1.46 pooka SPARG(&callarg, id) = id;
2832 1.46 pooka
2833 1.120 pgoyette error = rsys_syscall(SYS__ksem_close, &callarg, sizeof(callarg), retval);
2834 1.63 pooka rsys_seterrno(error);
2835 1.68 pooka if (error == 0) {
2836 1.68 pooka if (sizeof(int) > sizeof(register_t))
2837 1.68 pooka rv = *(int *)retval;
2838 1.68 pooka else
2839 1.69 pooka rv = *retval;
2840 1.46 pooka }
2841 1.68 pooka return rv;
2842 1.46 pooka }
2843 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2844 1.103 pooka __weak_alias(_ksem_close,rump___sysimpl__ksem_close);
2845 1.103 pooka __weak_alias(__ksem_close,rump___sysimpl__ksem_close);
2846 1.103 pooka __strong_alias(_sys__ksem_close,rump___sysimpl__ksem_close);
2847 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2848 1.46 pooka
2849 1.60 pooka int rump___sysimpl__ksem_post(intptr_t);
2850 1.46 pooka int
2851 1.60 pooka rump___sysimpl__ksem_post(intptr_t id)
2852 1.46 pooka {
2853 1.93 pooka register_t retval[2];
2854 1.46 pooka int error = 0;
2855 1.68 pooka int rv = -1;
2856 1.46 pooka struct sys__ksem_post_args callarg;
2857 1.46 pooka
2858 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2859 1.46 pooka SPARG(&callarg, id) = id;
2860 1.46 pooka
2861 1.120 pgoyette error = rsys_syscall(SYS__ksem_post, &callarg, sizeof(callarg), retval);
2862 1.63 pooka rsys_seterrno(error);
2863 1.68 pooka if (error == 0) {
2864 1.68 pooka if (sizeof(int) > sizeof(register_t))
2865 1.68 pooka rv = *(int *)retval;
2866 1.68 pooka else
2867 1.69 pooka rv = *retval;
2868 1.46 pooka }
2869 1.68 pooka return rv;
2870 1.46 pooka }
2871 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2872 1.103 pooka __weak_alias(_ksem_post,rump___sysimpl__ksem_post);
2873 1.103 pooka __weak_alias(__ksem_post,rump___sysimpl__ksem_post);
2874 1.103 pooka __strong_alias(_sys__ksem_post,rump___sysimpl__ksem_post);
2875 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2876 1.46 pooka
2877 1.60 pooka int rump___sysimpl__ksem_wait(intptr_t);
2878 1.46 pooka int
2879 1.60 pooka rump___sysimpl__ksem_wait(intptr_t id)
2880 1.46 pooka {
2881 1.93 pooka register_t retval[2];
2882 1.46 pooka int error = 0;
2883 1.68 pooka int rv = -1;
2884 1.46 pooka struct sys__ksem_wait_args callarg;
2885 1.46 pooka
2886 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2887 1.46 pooka SPARG(&callarg, id) = id;
2888 1.46 pooka
2889 1.120 pgoyette error = rsys_syscall(SYS__ksem_wait, &callarg, sizeof(callarg), retval);
2890 1.63 pooka rsys_seterrno(error);
2891 1.68 pooka if (error == 0) {
2892 1.68 pooka if (sizeof(int) > sizeof(register_t))
2893 1.68 pooka rv = *(int *)retval;
2894 1.68 pooka else
2895 1.69 pooka rv = *retval;
2896 1.46 pooka }
2897 1.68 pooka return rv;
2898 1.46 pooka }
2899 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2900 1.103 pooka __weak_alias(_ksem_wait,rump___sysimpl__ksem_wait);
2901 1.103 pooka __weak_alias(__ksem_wait,rump___sysimpl__ksem_wait);
2902 1.103 pooka __strong_alias(_sys__ksem_wait,rump___sysimpl__ksem_wait);
2903 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2904 1.46 pooka
2905 1.60 pooka int rump___sysimpl__ksem_trywait(intptr_t);
2906 1.46 pooka int
2907 1.60 pooka rump___sysimpl__ksem_trywait(intptr_t id)
2908 1.46 pooka {
2909 1.93 pooka register_t retval[2];
2910 1.46 pooka int error = 0;
2911 1.68 pooka int rv = -1;
2912 1.46 pooka struct sys__ksem_trywait_args callarg;
2913 1.46 pooka
2914 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2915 1.46 pooka SPARG(&callarg, id) = id;
2916 1.46 pooka
2917 1.120 pgoyette error = rsys_syscall(SYS__ksem_trywait, &callarg, sizeof(callarg), retval);
2918 1.63 pooka rsys_seterrno(error);
2919 1.68 pooka if (error == 0) {
2920 1.68 pooka if (sizeof(int) > sizeof(register_t))
2921 1.68 pooka rv = *(int *)retval;
2922 1.68 pooka else
2923 1.69 pooka rv = *retval;
2924 1.46 pooka }
2925 1.68 pooka return rv;
2926 1.46 pooka }
2927 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2928 1.103 pooka __weak_alias(_ksem_trywait,rump___sysimpl__ksem_trywait);
2929 1.103 pooka __weak_alias(__ksem_trywait,rump___sysimpl__ksem_trywait);
2930 1.103 pooka __strong_alias(_sys__ksem_trywait,rump___sysimpl__ksem_trywait);
2931 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2932 1.46 pooka
2933 1.60 pooka int rump___sysimpl__ksem_getvalue(intptr_t, unsigned int *);
2934 1.46 pooka int
2935 1.60 pooka rump___sysimpl__ksem_getvalue(intptr_t id, unsigned int * value)
2936 1.46 pooka {
2937 1.93 pooka register_t retval[2];
2938 1.46 pooka int error = 0;
2939 1.68 pooka int rv = -1;
2940 1.46 pooka struct sys__ksem_getvalue_args callarg;
2941 1.46 pooka
2942 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2943 1.46 pooka SPARG(&callarg, id) = id;
2944 1.46 pooka SPARG(&callarg, value) = value;
2945 1.46 pooka
2946 1.120 pgoyette error = rsys_syscall(SYS__ksem_getvalue, &callarg, sizeof(callarg), retval);
2947 1.63 pooka rsys_seterrno(error);
2948 1.68 pooka if (error == 0) {
2949 1.68 pooka if (sizeof(int) > sizeof(register_t))
2950 1.68 pooka rv = *(int *)retval;
2951 1.68 pooka else
2952 1.69 pooka rv = *retval;
2953 1.46 pooka }
2954 1.68 pooka return rv;
2955 1.46 pooka }
2956 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2957 1.103 pooka __weak_alias(_ksem_getvalue,rump___sysimpl__ksem_getvalue);
2958 1.103 pooka __weak_alias(__ksem_getvalue,rump___sysimpl__ksem_getvalue);
2959 1.103 pooka __strong_alias(_sys__ksem_getvalue,rump___sysimpl__ksem_getvalue);
2960 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2961 1.46 pooka
2962 1.60 pooka int rump___sysimpl__ksem_destroy(intptr_t);
2963 1.46 pooka int
2964 1.60 pooka rump___sysimpl__ksem_destroy(intptr_t id)
2965 1.46 pooka {
2966 1.93 pooka register_t retval[2];
2967 1.46 pooka int error = 0;
2968 1.68 pooka int rv = -1;
2969 1.46 pooka struct sys__ksem_destroy_args callarg;
2970 1.46 pooka
2971 1.95 pooka memset(&callarg, 0, sizeof(callarg));
2972 1.46 pooka SPARG(&callarg, id) = id;
2973 1.46 pooka
2974 1.120 pgoyette error = rsys_syscall(SYS__ksem_destroy, &callarg, sizeof(callarg), retval);
2975 1.63 pooka rsys_seterrno(error);
2976 1.68 pooka if (error == 0) {
2977 1.68 pooka if (sizeof(int) > sizeof(register_t))
2978 1.68 pooka rv = *(int *)retval;
2979 1.68 pooka else
2980 1.69 pooka rv = *retval;
2981 1.46 pooka }
2982 1.68 pooka return rv;
2983 1.46 pooka }
2984 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
2985 1.103 pooka __weak_alias(_ksem_destroy,rump___sysimpl__ksem_destroy);
2986 1.103 pooka __weak_alias(__ksem_destroy,rump___sysimpl__ksem_destroy);
2987 1.103 pooka __strong_alias(_sys__ksem_destroy,rump___sysimpl__ksem_destroy);
2988 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
2989 1.46 pooka
2990 1.78 joerg int rump___sysimpl__ksem_timedwait(intptr_t, const struct timespec *);
2991 1.78 joerg int
2992 1.78 joerg rump___sysimpl__ksem_timedwait(intptr_t id, const struct timespec * abstime)
2993 1.78 joerg {
2994 1.93 pooka register_t retval[2];
2995 1.78 joerg int error = 0;
2996 1.78 joerg int rv = -1;
2997 1.78 joerg struct sys__ksem_timedwait_args callarg;
2998 1.78 joerg
2999 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3000 1.78 joerg SPARG(&callarg, id) = id;
3001 1.78 joerg SPARG(&callarg, abstime) = abstime;
3002 1.78 joerg
3003 1.120 pgoyette error = rsys_syscall(SYS__ksem_timedwait, &callarg, sizeof(callarg), retval);
3004 1.78 joerg rsys_seterrno(error);
3005 1.78 joerg if (error == 0) {
3006 1.78 joerg if (sizeof(int) > sizeof(register_t))
3007 1.78 joerg rv = *(int *)retval;
3008 1.78 joerg else
3009 1.78 joerg rv = *retval;
3010 1.78 joerg }
3011 1.78 joerg return rv;
3012 1.78 joerg }
3013 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3014 1.103 pooka __weak_alias(_ksem_timedwait,rump___sysimpl__ksem_timedwait);
3015 1.103 pooka __weak_alias(__ksem_timedwait,rump___sysimpl__ksem_timedwait);
3016 1.103 pooka __strong_alias(_sys__ksem_timedwait,rump___sysimpl__ksem_timedwait);
3017 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3018 1.78 joerg
3019 1.108 justin int rump___sysimpl___posix_rename(const char *, const char *);
3020 1.108 justin int
3021 1.108 justin rump___sysimpl___posix_rename(const char * from, const char * to)
3022 1.108 justin {
3023 1.108 justin register_t retval[2];
3024 1.108 justin int error = 0;
3025 1.108 justin int rv = -1;
3026 1.108 justin struct sys___posix_rename_args callarg;
3027 1.108 justin
3028 1.108 justin memset(&callarg, 0, sizeof(callarg));
3029 1.108 justin SPARG(&callarg, from) = from;
3030 1.108 justin SPARG(&callarg, to) = to;
3031 1.108 justin
3032 1.120 pgoyette error = rsys_syscall(SYS___posix_rename, &callarg, sizeof(callarg), retval);
3033 1.108 justin rsys_seterrno(error);
3034 1.108 justin if (error == 0) {
3035 1.108 justin if (sizeof(int) > sizeof(register_t))
3036 1.108 justin rv = *(int *)retval;
3037 1.108 justin else
3038 1.108 justin rv = *retval;
3039 1.108 justin }
3040 1.108 justin return rv;
3041 1.108 justin }
3042 1.108 justin #ifdef RUMP_KERNEL_IS_LIBC
3043 1.108 justin __weak_alias(__posix_rename,rump___sysimpl___posix_rename);
3044 1.108 justin __weak_alias(___posix_rename,rump___sysimpl___posix_rename);
3045 1.108 justin __strong_alias(_sys___posix_rename,rump___sysimpl___posix_rename);
3046 1.108 justin #endif /* RUMP_KERNEL_IS_LIBC */
3047 1.108 justin
3048 1.60 pooka int rump___sysimpl_lchmod(const char *, mode_t);
3049 1.34 pooka int
3050 1.60 pooka rump___sysimpl_lchmod(const char * path, mode_t mode)
3051 1.34 pooka {
3052 1.93 pooka register_t retval[2];
3053 1.34 pooka int error = 0;
3054 1.68 pooka int rv = -1;
3055 1.34 pooka struct sys_lchmod_args callarg;
3056 1.34 pooka
3057 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3058 1.34 pooka SPARG(&callarg, path) = path;
3059 1.34 pooka SPARG(&callarg, mode) = mode;
3060 1.34 pooka
3061 1.120 pgoyette error = rsys_syscall(SYS_lchmod, &callarg, sizeof(callarg), retval);
3062 1.63 pooka rsys_seterrno(error);
3063 1.68 pooka if (error == 0) {
3064 1.68 pooka if (sizeof(int) > sizeof(register_t))
3065 1.68 pooka rv = *(int *)retval;
3066 1.68 pooka else
3067 1.69 pooka rv = *retval;
3068 1.34 pooka }
3069 1.68 pooka return rv;
3070 1.34 pooka }
3071 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3072 1.103 pooka __weak_alias(lchmod,rump___sysimpl_lchmod);
3073 1.103 pooka __weak_alias(_lchmod,rump___sysimpl_lchmod);
3074 1.103 pooka __strong_alias(_sys_lchmod,rump___sysimpl_lchmod);
3075 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3076 1.34 pooka
3077 1.60 pooka int rump___sysimpl_lchown(const char *, uid_t, gid_t);
3078 1.34 pooka int
3079 1.60 pooka rump___sysimpl_lchown(const char * path, uid_t uid, gid_t gid)
3080 1.34 pooka {
3081 1.93 pooka register_t retval[2];
3082 1.34 pooka int error = 0;
3083 1.68 pooka int rv = -1;
3084 1.34 pooka struct sys_lchown_args callarg;
3085 1.34 pooka
3086 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3087 1.34 pooka SPARG(&callarg, path) = path;
3088 1.34 pooka SPARG(&callarg, uid) = uid;
3089 1.34 pooka SPARG(&callarg, gid) = gid;
3090 1.34 pooka
3091 1.120 pgoyette error = rsys_syscall(SYS_lchown, &callarg, sizeof(callarg), retval);
3092 1.63 pooka rsys_seterrno(error);
3093 1.68 pooka if (error == 0) {
3094 1.68 pooka if (sizeof(int) > sizeof(register_t))
3095 1.68 pooka rv = *(int *)retval;
3096 1.68 pooka else
3097 1.69 pooka rv = *retval;
3098 1.34 pooka }
3099 1.68 pooka return rv;
3100 1.34 pooka }
3101 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3102 1.103 pooka __weak_alias(lchown,rump___sysimpl_lchown);
3103 1.103 pooka __weak_alias(_lchown,rump___sysimpl_lchown);
3104 1.103 pooka __strong_alias(_sys_lchown,rump___sysimpl_lchown);
3105 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3106 1.34 pooka
3107 1.103 pooka #ifdef RUMP_SYS_COMPAT
3108 1.60 pooka int rump___sysimpl_lutimes(const char *, const struct timeval *);
3109 1.60 pooka int
3110 1.60 pooka rump___sysimpl_lutimes(const char * path, const struct timeval * tptr)
3111 1.60 pooka {
3112 1.93 pooka register_t retval[2];
3113 1.60 pooka int error = 0;
3114 1.68 pooka int rv = -1;
3115 1.60 pooka struct compat_50_sys_lutimes_args callarg;
3116 1.60 pooka
3117 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3118 1.60 pooka SPARG(&callarg, path) = path;
3119 1.60 pooka SPARG(&callarg, tptr) = (const struct timeval50 *)tptr;
3120 1.60 pooka
3121 1.120 pgoyette error = rsys_syscall(SYS_compat_50_lutimes, &callarg, sizeof(callarg), retval);
3122 1.63 pooka rsys_seterrno(error);
3123 1.68 pooka if (error == 0) {
3124 1.68 pooka if (sizeof(int) > sizeof(register_t))
3125 1.68 pooka rv = *(int *)retval;
3126 1.68 pooka else
3127 1.69 pooka rv = *retval;
3128 1.60 pooka }
3129 1.68 pooka return rv;
3130 1.60 pooka }
3131 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3132 1.103 pooka __weak_alias(lutimes,rump___sysimpl_lutimes);
3133 1.103 pooka __weak_alias(_lutimes,rump___sysimpl_lutimes);
3134 1.103 pooka __strong_alias(_sys_lutimes,rump___sysimpl_lutimes);
3135 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3136 1.103 pooka #endif /* RUMP_SYS_COMPAT */
3137 1.60 pooka
3138 1.113 pooka int rump___sysimpl___posix_chown(const char *, uid_t, gid_t);
3139 1.113 pooka int
3140 1.113 pooka rump___sysimpl___posix_chown(const char * path, uid_t uid, gid_t gid)
3141 1.113 pooka {
3142 1.113 pooka register_t retval[2];
3143 1.113 pooka int error = 0;
3144 1.113 pooka int rv = -1;
3145 1.113 pooka struct sys___posix_chown_args callarg;
3146 1.113 pooka
3147 1.113 pooka memset(&callarg, 0, sizeof(callarg));
3148 1.113 pooka SPARG(&callarg, path) = path;
3149 1.113 pooka SPARG(&callarg, uid) = uid;
3150 1.113 pooka SPARG(&callarg, gid) = gid;
3151 1.113 pooka
3152 1.120 pgoyette error = rsys_syscall(SYS___posix_chown, &callarg, sizeof(callarg), retval);
3153 1.113 pooka rsys_seterrno(error);
3154 1.113 pooka if (error == 0) {
3155 1.113 pooka if (sizeof(int) > sizeof(register_t))
3156 1.113 pooka rv = *(int *)retval;
3157 1.113 pooka else
3158 1.113 pooka rv = *retval;
3159 1.113 pooka }
3160 1.113 pooka return rv;
3161 1.113 pooka }
3162 1.113 pooka #ifdef RUMP_KERNEL_IS_LIBC
3163 1.113 pooka __weak_alias(__posix_chown,rump___sysimpl___posix_chown);
3164 1.113 pooka __weak_alias(___posix_chown,rump___sysimpl___posix_chown);
3165 1.113 pooka __strong_alias(_sys___posix_chown,rump___sysimpl___posix_chown);
3166 1.113 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3167 1.113 pooka
3168 1.113 pooka int rump___sysimpl___posix_fchown(int, uid_t, gid_t);
3169 1.113 pooka int
3170 1.113 pooka rump___sysimpl___posix_fchown(int fd, uid_t uid, gid_t gid)
3171 1.113 pooka {
3172 1.113 pooka register_t retval[2];
3173 1.113 pooka int error = 0;
3174 1.113 pooka int rv = -1;
3175 1.113 pooka struct sys___posix_fchown_args callarg;
3176 1.113 pooka
3177 1.113 pooka memset(&callarg, 0, sizeof(callarg));
3178 1.113 pooka SPARG(&callarg, fd) = fd;
3179 1.113 pooka SPARG(&callarg, uid) = uid;
3180 1.113 pooka SPARG(&callarg, gid) = gid;
3181 1.113 pooka
3182 1.120 pgoyette error = rsys_syscall(SYS___posix_fchown, &callarg, sizeof(callarg), retval);
3183 1.113 pooka rsys_seterrno(error);
3184 1.113 pooka if (error == 0) {
3185 1.113 pooka if (sizeof(int) > sizeof(register_t))
3186 1.113 pooka rv = *(int *)retval;
3187 1.113 pooka else
3188 1.113 pooka rv = *retval;
3189 1.113 pooka }
3190 1.113 pooka return rv;
3191 1.113 pooka }
3192 1.113 pooka #ifdef RUMP_KERNEL_IS_LIBC
3193 1.113 pooka __weak_alias(__posix_fchown,rump___sysimpl___posix_fchown);
3194 1.113 pooka __weak_alias(___posix_fchown,rump___sysimpl___posix_fchown);
3195 1.113 pooka __strong_alias(_sys___posix_fchown,rump___sysimpl___posix_fchown);
3196 1.113 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3197 1.113 pooka
3198 1.113 pooka int rump___sysimpl___posix_lchown(const char *, uid_t, gid_t);
3199 1.113 pooka int
3200 1.113 pooka rump___sysimpl___posix_lchown(const char * path, uid_t uid, gid_t gid)
3201 1.113 pooka {
3202 1.113 pooka register_t retval[2];
3203 1.113 pooka int error = 0;
3204 1.113 pooka int rv = -1;
3205 1.113 pooka struct sys___posix_lchown_args callarg;
3206 1.113 pooka
3207 1.113 pooka memset(&callarg, 0, sizeof(callarg));
3208 1.113 pooka SPARG(&callarg, path) = path;
3209 1.113 pooka SPARG(&callarg, uid) = uid;
3210 1.113 pooka SPARG(&callarg, gid) = gid;
3211 1.113 pooka
3212 1.120 pgoyette error = rsys_syscall(SYS___posix_lchown, &callarg, sizeof(callarg), retval);
3213 1.113 pooka rsys_seterrno(error);
3214 1.113 pooka if (error == 0) {
3215 1.113 pooka if (sizeof(int) > sizeof(register_t))
3216 1.113 pooka rv = *(int *)retval;
3217 1.113 pooka else
3218 1.113 pooka rv = *retval;
3219 1.113 pooka }
3220 1.113 pooka return rv;
3221 1.113 pooka }
3222 1.113 pooka #ifdef RUMP_KERNEL_IS_LIBC
3223 1.113 pooka __weak_alias(__posix_lchown,rump___sysimpl___posix_lchown);
3224 1.113 pooka __weak_alias(___posix_lchown,rump___sysimpl___posix_lchown);
3225 1.113 pooka __strong_alias(_sys___posix_lchown,rump___sysimpl___posix_lchown);
3226 1.113 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3227 1.113 pooka
3228 1.60 pooka pid_t rump___sysimpl_getsid(pid_t);
3229 1.49 pooka pid_t
3230 1.60 pooka rump___sysimpl_getsid(pid_t pid)
3231 1.49 pooka {
3232 1.93 pooka register_t retval[2];
3233 1.49 pooka int error = 0;
3234 1.68 pooka pid_t rv = -1;
3235 1.49 pooka struct sys_getsid_args callarg;
3236 1.49 pooka
3237 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3238 1.49 pooka SPARG(&callarg, pid) = pid;
3239 1.49 pooka
3240 1.120 pgoyette error = rsys_syscall(SYS_getsid, &callarg, sizeof(callarg), retval);
3241 1.63 pooka rsys_seterrno(error);
3242 1.68 pooka if (error == 0) {
3243 1.68 pooka if (sizeof(pid_t) > sizeof(register_t))
3244 1.68 pooka rv = *(pid_t *)retval;
3245 1.68 pooka else
3246 1.69 pooka rv = *retval;
3247 1.49 pooka }
3248 1.68 pooka return rv;
3249 1.49 pooka }
3250 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3251 1.103 pooka __weak_alias(getsid,rump___sysimpl_getsid);
3252 1.103 pooka __weak_alias(_getsid,rump___sysimpl_getsid);
3253 1.103 pooka __strong_alias(_sys_getsid,rump___sysimpl_getsid);
3254 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3255 1.49 pooka
3256 1.94 pooka int rump___sysimpl_fktrace(int, int, int, pid_t);
3257 1.94 pooka int
3258 1.94 pooka rump___sysimpl_fktrace(int fd, int ops, int facs, pid_t pid)
3259 1.94 pooka {
3260 1.94 pooka register_t retval[2];
3261 1.94 pooka int error = 0;
3262 1.94 pooka int rv = -1;
3263 1.94 pooka struct sys_fktrace_args callarg;
3264 1.94 pooka
3265 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3266 1.94 pooka SPARG(&callarg, fd) = fd;
3267 1.94 pooka SPARG(&callarg, ops) = ops;
3268 1.94 pooka SPARG(&callarg, facs) = facs;
3269 1.94 pooka SPARG(&callarg, pid) = pid;
3270 1.94 pooka
3271 1.120 pgoyette error = rsys_syscall(SYS_fktrace, &callarg, sizeof(callarg), retval);
3272 1.94 pooka rsys_seterrno(error);
3273 1.94 pooka if (error == 0) {
3274 1.94 pooka if (sizeof(int) > sizeof(register_t))
3275 1.94 pooka rv = *(int *)retval;
3276 1.94 pooka else
3277 1.94 pooka rv = *retval;
3278 1.94 pooka }
3279 1.94 pooka return rv;
3280 1.94 pooka }
3281 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3282 1.103 pooka __weak_alias(fktrace,rump___sysimpl_fktrace);
3283 1.103 pooka __weak_alias(_fktrace,rump___sysimpl_fktrace);
3284 1.103 pooka __strong_alias(_sys_fktrace,rump___sysimpl_fktrace);
3285 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3286 1.94 pooka
3287 1.64 pooka ssize_t rump___sysimpl_preadv(int, const struct iovec *, int, off_t);
3288 1.64 pooka ssize_t
3289 1.64 pooka rump___sysimpl_preadv(int fd, const struct iovec * iovp, int iovcnt, off_t offset)
3290 1.64 pooka {
3291 1.93 pooka register_t retval[2];
3292 1.64 pooka int error = 0;
3293 1.68 pooka ssize_t rv = -1;
3294 1.64 pooka struct sys_preadv_args callarg;
3295 1.64 pooka
3296 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3297 1.64 pooka SPARG(&callarg, fd) = fd;
3298 1.64 pooka SPARG(&callarg, iovp) = iovp;
3299 1.64 pooka SPARG(&callarg, iovcnt) = iovcnt;
3300 1.64 pooka SPARG(&callarg, PAD) = 0;
3301 1.64 pooka SPARG(&callarg, offset) = offset;
3302 1.64 pooka
3303 1.120 pgoyette error = rsys_syscall(SYS_preadv, &callarg, sizeof(callarg), retval);
3304 1.64 pooka rsys_seterrno(error);
3305 1.68 pooka if (error == 0) {
3306 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3307 1.68 pooka rv = *(ssize_t *)retval;
3308 1.68 pooka else
3309 1.69 pooka rv = *retval;
3310 1.64 pooka }
3311 1.68 pooka return rv;
3312 1.64 pooka }
3313 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3314 1.103 pooka __weak_alias(preadv,rump___sysimpl_preadv);
3315 1.103 pooka __weak_alias(_preadv,rump___sysimpl_preadv);
3316 1.103 pooka __strong_alias(_sys_preadv,rump___sysimpl_preadv);
3317 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3318 1.64 pooka
3319 1.64 pooka ssize_t rump___sysimpl_pwritev(int, const struct iovec *, int, off_t);
3320 1.64 pooka ssize_t
3321 1.64 pooka rump___sysimpl_pwritev(int fd, const struct iovec * iovp, int iovcnt, off_t offset)
3322 1.64 pooka {
3323 1.93 pooka register_t retval[2];
3324 1.64 pooka int error = 0;
3325 1.68 pooka ssize_t rv = -1;
3326 1.64 pooka struct sys_pwritev_args callarg;
3327 1.64 pooka
3328 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3329 1.64 pooka SPARG(&callarg, fd) = fd;
3330 1.64 pooka SPARG(&callarg, iovp) = iovp;
3331 1.64 pooka SPARG(&callarg, iovcnt) = iovcnt;
3332 1.64 pooka SPARG(&callarg, PAD) = 0;
3333 1.64 pooka SPARG(&callarg, offset) = offset;
3334 1.64 pooka
3335 1.120 pgoyette error = rsys_syscall(SYS_pwritev, &callarg, sizeof(callarg), retval);
3336 1.64 pooka rsys_seterrno(error);
3337 1.68 pooka if (error == 0) {
3338 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3339 1.68 pooka rv = *(ssize_t *)retval;
3340 1.68 pooka else
3341 1.69 pooka rv = *retval;
3342 1.64 pooka }
3343 1.68 pooka return rv;
3344 1.64 pooka }
3345 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3346 1.103 pooka __weak_alias(pwritev,rump___sysimpl_pwritev);
3347 1.103 pooka __weak_alias(_pwritev,rump___sysimpl_pwritev);
3348 1.103 pooka __strong_alias(_sys_pwritev,rump___sysimpl_pwritev);
3349 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3350 1.64 pooka
3351 1.60 pooka int rump___sysimpl___getcwd(char *, size_t);
3352 1.51 pooka int
3353 1.60 pooka rump___sysimpl___getcwd(char * bufp, size_t length)
3354 1.51 pooka {
3355 1.93 pooka register_t retval[2];
3356 1.51 pooka int error = 0;
3357 1.68 pooka int rv = -1;
3358 1.51 pooka struct sys___getcwd_args callarg;
3359 1.51 pooka
3360 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3361 1.51 pooka SPARG(&callarg, bufp) = bufp;
3362 1.51 pooka SPARG(&callarg, length) = length;
3363 1.51 pooka
3364 1.120 pgoyette error = rsys_syscall(SYS___getcwd, &callarg, sizeof(callarg), retval);
3365 1.63 pooka rsys_seterrno(error);
3366 1.68 pooka if (error == 0) {
3367 1.68 pooka if (sizeof(int) > sizeof(register_t))
3368 1.68 pooka rv = *(int *)retval;
3369 1.68 pooka else
3370 1.69 pooka rv = *retval;
3371 1.51 pooka }
3372 1.68 pooka return rv;
3373 1.51 pooka }
3374 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3375 1.103 pooka __weak_alias(__getcwd,rump___sysimpl___getcwd);
3376 1.103 pooka __weak_alias(___getcwd,rump___sysimpl___getcwd);
3377 1.103 pooka __strong_alias(_sys___getcwd,rump___sysimpl___getcwd);
3378 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3379 1.51 pooka
3380 1.60 pooka int rump___sysimpl_fchroot(int);
3381 1.34 pooka int
3382 1.60 pooka rump___sysimpl_fchroot(int fd)
3383 1.34 pooka {
3384 1.93 pooka register_t retval[2];
3385 1.34 pooka int error = 0;
3386 1.68 pooka int rv = -1;
3387 1.34 pooka struct sys_fchroot_args callarg;
3388 1.34 pooka
3389 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3390 1.34 pooka SPARG(&callarg, fd) = fd;
3391 1.34 pooka
3392 1.120 pgoyette error = rsys_syscall(SYS_fchroot, &callarg, sizeof(callarg), retval);
3393 1.63 pooka rsys_seterrno(error);
3394 1.68 pooka if (error == 0) {
3395 1.68 pooka if (sizeof(int) > sizeof(register_t))
3396 1.68 pooka rv = *(int *)retval;
3397 1.68 pooka else
3398 1.69 pooka rv = *retval;
3399 1.34 pooka }
3400 1.68 pooka return rv;
3401 1.34 pooka }
3402 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3403 1.103 pooka __weak_alias(fchroot,rump___sysimpl_fchroot);
3404 1.103 pooka __weak_alias(_fchroot,rump___sysimpl_fchroot);
3405 1.103 pooka __strong_alias(_sys_fchroot,rump___sysimpl_fchroot);
3406 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3407 1.34 pooka
3408 1.60 pooka int rump___sysimpl_lchflags(const char *, u_long);
3409 1.34 pooka int
3410 1.60 pooka rump___sysimpl_lchflags(const char * path, u_long flags)
3411 1.34 pooka {
3412 1.93 pooka register_t retval[2];
3413 1.34 pooka int error = 0;
3414 1.68 pooka int rv = -1;
3415 1.34 pooka struct sys_lchflags_args callarg;
3416 1.34 pooka
3417 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3418 1.34 pooka SPARG(&callarg, path) = path;
3419 1.34 pooka SPARG(&callarg, flags) = flags;
3420 1.34 pooka
3421 1.120 pgoyette error = rsys_syscall(SYS_lchflags, &callarg, sizeof(callarg), retval);
3422 1.63 pooka rsys_seterrno(error);
3423 1.68 pooka if (error == 0) {
3424 1.68 pooka if (sizeof(int) > sizeof(register_t))
3425 1.68 pooka rv = *(int *)retval;
3426 1.68 pooka else
3427 1.69 pooka rv = *retval;
3428 1.34 pooka }
3429 1.68 pooka return rv;
3430 1.34 pooka }
3431 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3432 1.103 pooka __weak_alias(lchflags,rump___sysimpl_lchflags);
3433 1.103 pooka __weak_alias(_lchflags,rump___sysimpl_lchflags);
3434 1.103 pooka __strong_alias(_sys_lchflags,rump___sysimpl_lchflags);
3435 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3436 1.34 pooka
3437 1.60 pooka int rump___sysimpl_issetugid(void);
3438 1.49 pooka int
3439 1.60 pooka rump___sysimpl_issetugid(void )
3440 1.49 pooka {
3441 1.93 pooka register_t retval[2];
3442 1.68 pooka int rv = -1;
3443 1.49 pooka
3444 1.119 pgoyette (void)rsys_syscall(SYS_issetugid, NULL, 0, retval);
3445 1.68 pooka if (sizeof(int) > sizeof(register_t))
3446 1.68 pooka rv = *(int *)retval;
3447 1.68 pooka else
3448 1.69 pooka rv = *retval;
3449 1.68 pooka return rv;
3450 1.49 pooka }
3451 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3452 1.103 pooka __weak_alias(issetugid,rump___sysimpl_issetugid);
3453 1.103 pooka __weak_alias(_issetugid,rump___sysimpl_issetugid);
3454 1.103 pooka __strong_alias(_sys_issetugid,rump___sysimpl_issetugid);
3455 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3456 1.49 pooka
3457 1.97 pooka int rump___sysimpl_utrace(const char *, void *, size_t);
3458 1.97 pooka int
3459 1.97 pooka rump___sysimpl_utrace(const char * label, void * addr, size_t len)
3460 1.97 pooka {
3461 1.97 pooka register_t retval[2];
3462 1.97 pooka int error = 0;
3463 1.97 pooka int rv = -1;
3464 1.97 pooka struct sys_utrace_args callarg;
3465 1.97 pooka
3466 1.97 pooka memset(&callarg, 0, sizeof(callarg));
3467 1.97 pooka SPARG(&callarg, label) = label;
3468 1.97 pooka SPARG(&callarg, addr) = addr;
3469 1.97 pooka SPARG(&callarg, len) = len;
3470 1.97 pooka
3471 1.120 pgoyette error = rsys_syscall(SYS_utrace, &callarg, sizeof(callarg), retval);
3472 1.97 pooka rsys_seterrno(error);
3473 1.97 pooka if (error == 0) {
3474 1.97 pooka if (sizeof(int) > sizeof(register_t))
3475 1.97 pooka rv = *(int *)retval;
3476 1.97 pooka else
3477 1.97 pooka rv = *retval;
3478 1.97 pooka }
3479 1.97 pooka return rv;
3480 1.97 pooka }
3481 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3482 1.103 pooka __weak_alias(utrace,rump___sysimpl_utrace);
3483 1.103 pooka __weak_alias(_utrace,rump___sysimpl_utrace);
3484 1.103 pooka __strong_alias(_sys_utrace,rump___sysimpl_utrace);
3485 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3486 1.97 pooka
3487 1.60 pooka int rump___sysimpl_kqueue(void);
3488 1.34 pooka int
3489 1.60 pooka rump___sysimpl_kqueue(void )
3490 1.34 pooka {
3491 1.93 pooka register_t retval[2];
3492 1.34 pooka int error = 0;
3493 1.68 pooka int rv = -1;
3494 1.34 pooka
3495 1.120 pgoyette error = rsys_syscall(SYS_kqueue, NULL, 0, retval);
3496 1.63 pooka rsys_seterrno(error);
3497 1.68 pooka if (error == 0) {
3498 1.68 pooka if (sizeof(int) > sizeof(register_t))
3499 1.68 pooka rv = *(int *)retval;
3500 1.68 pooka else
3501 1.69 pooka rv = *retval;
3502 1.34 pooka }
3503 1.68 pooka return rv;
3504 1.34 pooka }
3505 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3506 1.103 pooka __weak_alias(kqueue,rump___sysimpl_kqueue);
3507 1.103 pooka __weak_alias(_kqueue,rump___sysimpl_kqueue);
3508 1.103 pooka __strong_alias(_sys_kqueue,rump___sysimpl_kqueue);
3509 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3510 1.34 pooka
3511 1.103 pooka #ifdef RUMP_SYS_COMPAT
3512 1.60 pooka int rump___sysimpl_kevent(int, const struct kevent *, size_t, struct kevent *, size_t, const struct timespec *);
3513 1.60 pooka int
3514 1.60 pooka rump___sysimpl_kevent(int fd, const struct kevent * changelist, size_t nchanges, struct kevent * eventlist, size_t nevents, const struct timespec * timeout)
3515 1.60 pooka {
3516 1.93 pooka register_t retval[2];
3517 1.60 pooka int error = 0;
3518 1.68 pooka int rv = -1;
3519 1.60 pooka struct compat_50_sys_kevent_args callarg;
3520 1.60 pooka
3521 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3522 1.60 pooka SPARG(&callarg, fd) = fd;
3523 1.60 pooka SPARG(&callarg, changelist) = changelist;
3524 1.60 pooka SPARG(&callarg, nchanges) = nchanges;
3525 1.60 pooka SPARG(&callarg, eventlist) = eventlist;
3526 1.60 pooka SPARG(&callarg, nevents) = nevents;
3527 1.60 pooka SPARG(&callarg, timeout) = (const struct timespec50 *)timeout;
3528 1.60 pooka
3529 1.120 pgoyette error = rsys_syscall(SYS_compat_50_kevent, &callarg, sizeof(callarg), retval);
3530 1.63 pooka rsys_seterrno(error);
3531 1.68 pooka if (error == 0) {
3532 1.68 pooka if (sizeof(int) > sizeof(register_t))
3533 1.68 pooka rv = *(int *)retval;
3534 1.68 pooka else
3535 1.69 pooka rv = *retval;
3536 1.60 pooka }
3537 1.68 pooka return rv;
3538 1.60 pooka }
3539 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3540 1.103 pooka __weak_alias(kevent,rump___sysimpl_kevent);
3541 1.103 pooka __weak_alias(_kevent,rump___sysimpl_kevent);
3542 1.103 pooka __strong_alias(_sys_kevent,rump___sysimpl_kevent);
3543 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3544 1.103 pooka #endif /* RUMP_SYS_COMPAT */
3545 1.60 pooka
3546 1.60 pooka int rump___sysimpl_fsync_range(int, int, off_t, off_t);
3547 1.34 pooka int
3548 1.60 pooka rump___sysimpl_fsync_range(int fd, int flags, off_t start, off_t length)
3549 1.34 pooka {
3550 1.93 pooka register_t retval[2];
3551 1.34 pooka int error = 0;
3552 1.68 pooka int rv = -1;
3553 1.34 pooka struct sys_fsync_range_args callarg;
3554 1.34 pooka
3555 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3556 1.34 pooka SPARG(&callarg, fd) = fd;
3557 1.34 pooka SPARG(&callarg, flags) = flags;
3558 1.34 pooka SPARG(&callarg, start) = start;
3559 1.34 pooka SPARG(&callarg, length) = length;
3560 1.34 pooka
3561 1.120 pgoyette error = rsys_syscall(SYS_fsync_range, &callarg, sizeof(callarg), retval);
3562 1.63 pooka rsys_seterrno(error);
3563 1.68 pooka if (error == 0) {
3564 1.68 pooka if (sizeof(int) > sizeof(register_t))
3565 1.68 pooka rv = *(int *)retval;
3566 1.68 pooka else
3567 1.69 pooka rv = *retval;
3568 1.34 pooka }
3569 1.68 pooka return rv;
3570 1.34 pooka }
3571 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3572 1.103 pooka __weak_alias(fsync_range,rump___sysimpl_fsync_range);
3573 1.103 pooka __weak_alias(_fsync_range,rump___sysimpl_fsync_range);
3574 1.103 pooka __strong_alias(_sys_fsync_range,rump___sysimpl_fsync_range);
3575 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3576 1.34 pooka
3577 1.60 pooka int rump___sysimpl_extattrctl(const char *, int, const char *, int, const char *);
3578 1.34 pooka int
3579 1.60 pooka rump___sysimpl_extattrctl(const char * path, int cmd, const char * filename, int attrnamespace, const char * attrname)
3580 1.34 pooka {
3581 1.93 pooka register_t retval[2];
3582 1.34 pooka int error = 0;
3583 1.68 pooka int rv = -1;
3584 1.34 pooka struct sys_extattrctl_args callarg;
3585 1.34 pooka
3586 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3587 1.34 pooka SPARG(&callarg, path) = path;
3588 1.34 pooka SPARG(&callarg, cmd) = cmd;
3589 1.34 pooka SPARG(&callarg, filename) = filename;
3590 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3591 1.34 pooka SPARG(&callarg, attrname) = attrname;
3592 1.34 pooka
3593 1.120 pgoyette error = rsys_syscall(SYS_extattrctl, &callarg, sizeof(callarg), retval);
3594 1.63 pooka rsys_seterrno(error);
3595 1.68 pooka if (error == 0) {
3596 1.68 pooka if (sizeof(int) > sizeof(register_t))
3597 1.68 pooka rv = *(int *)retval;
3598 1.68 pooka else
3599 1.69 pooka rv = *retval;
3600 1.34 pooka }
3601 1.68 pooka return rv;
3602 1.34 pooka }
3603 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3604 1.103 pooka __weak_alias(extattrctl,rump___sysimpl_extattrctl);
3605 1.103 pooka __weak_alias(_extattrctl,rump___sysimpl_extattrctl);
3606 1.103 pooka __strong_alias(_sys_extattrctl,rump___sysimpl_extattrctl);
3607 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3608 1.34 pooka
3609 1.60 pooka int rump___sysimpl_extattr_set_file(const char *, int, const char *, const void *, size_t);
3610 1.34 pooka int
3611 1.60 pooka rump___sysimpl_extattr_set_file(const char * path, int attrnamespace, const char * attrname, const void * data, size_t nbytes)
3612 1.34 pooka {
3613 1.93 pooka register_t retval[2];
3614 1.34 pooka int error = 0;
3615 1.68 pooka int rv = -1;
3616 1.34 pooka struct sys_extattr_set_file_args callarg;
3617 1.34 pooka
3618 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3619 1.34 pooka SPARG(&callarg, path) = path;
3620 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3621 1.34 pooka SPARG(&callarg, attrname) = attrname;
3622 1.34 pooka SPARG(&callarg, data) = data;
3623 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3624 1.34 pooka
3625 1.120 pgoyette error = rsys_syscall(SYS_extattr_set_file, &callarg, sizeof(callarg), retval);
3626 1.63 pooka rsys_seterrno(error);
3627 1.68 pooka if (error == 0) {
3628 1.68 pooka if (sizeof(int) > sizeof(register_t))
3629 1.68 pooka rv = *(int *)retval;
3630 1.68 pooka else
3631 1.69 pooka rv = *retval;
3632 1.34 pooka }
3633 1.68 pooka return rv;
3634 1.34 pooka }
3635 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3636 1.103 pooka __weak_alias(extattr_set_file,rump___sysimpl_extattr_set_file);
3637 1.103 pooka __weak_alias(_extattr_set_file,rump___sysimpl_extattr_set_file);
3638 1.103 pooka __strong_alias(_sys_extattr_set_file,rump___sysimpl_extattr_set_file);
3639 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3640 1.34 pooka
3641 1.60 pooka ssize_t rump___sysimpl_extattr_get_file(const char *, int, const char *, void *, size_t);
3642 1.34 pooka ssize_t
3643 1.60 pooka rump___sysimpl_extattr_get_file(const char * path, int attrnamespace, const char * attrname, void * data, size_t nbytes)
3644 1.34 pooka {
3645 1.93 pooka register_t retval[2];
3646 1.34 pooka int error = 0;
3647 1.68 pooka ssize_t rv = -1;
3648 1.34 pooka struct sys_extattr_get_file_args callarg;
3649 1.34 pooka
3650 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3651 1.34 pooka SPARG(&callarg, path) = path;
3652 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3653 1.34 pooka SPARG(&callarg, attrname) = attrname;
3654 1.34 pooka SPARG(&callarg, data) = data;
3655 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3656 1.34 pooka
3657 1.120 pgoyette error = rsys_syscall(SYS_extattr_get_file, &callarg, sizeof(callarg), retval);
3658 1.63 pooka rsys_seterrno(error);
3659 1.68 pooka if (error == 0) {
3660 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3661 1.68 pooka rv = *(ssize_t *)retval;
3662 1.68 pooka else
3663 1.69 pooka rv = *retval;
3664 1.34 pooka }
3665 1.68 pooka return rv;
3666 1.34 pooka }
3667 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3668 1.103 pooka __weak_alias(extattr_get_file,rump___sysimpl_extattr_get_file);
3669 1.103 pooka __weak_alias(_extattr_get_file,rump___sysimpl_extattr_get_file);
3670 1.103 pooka __strong_alias(_sys_extattr_get_file,rump___sysimpl_extattr_get_file);
3671 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3672 1.34 pooka
3673 1.60 pooka int rump___sysimpl_extattr_delete_file(const char *, int, const char *);
3674 1.34 pooka int
3675 1.60 pooka rump___sysimpl_extattr_delete_file(const char * path, int attrnamespace, const char * attrname)
3676 1.34 pooka {
3677 1.93 pooka register_t retval[2];
3678 1.34 pooka int error = 0;
3679 1.68 pooka int rv = -1;
3680 1.34 pooka struct sys_extattr_delete_file_args callarg;
3681 1.34 pooka
3682 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3683 1.34 pooka SPARG(&callarg, path) = path;
3684 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3685 1.34 pooka SPARG(&callarg, attrname) = attrname;
3686 1.34 pooka
3687 1.120 pgoyette error = rsys_syscall(SYS_extattr_delete_file, &callarg, sizeof(callarg), retval);
3688 1.63 pooka rsys_seterrno(error);
3689 1.68 pooka if (error == 0) {
3690 1.68 pooka if (sizeof(int) > sizeof(register_t))
3691 1.68 pooka rv = *(int *)retval;
3692 1.68 pooka else
3693 1.69 pooka rv = *retval;
3694 1.34 pooka }
3695 1.68 pooka return rv;
3696 1.34 pooka }
3697 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3698 1.103 pooka __weak_alias(extattr_delete_file,rump___sysimpl_extattr_delete_file);
3699 1.103 pooka __weak_alias(_extattr_delete_file,rump___sysimpl_extattr_delete_file);
3700 1.103 pooka __strong_alias(_sys_extattr_delete_file,rump___sysimpl_extattr_delete_file);
3701 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3702 1.34 pooka
3703 1.60 pooka int rump___sysimpl_extattr_set_fd(int, int, const char *, const void *, size_t);
3704 1.34 pooka int
3705 1.60 pooka rump___sysimpl_extattr_set_fd(int fd, int attrnamespace, const char * attrname, const void * data, size_t nbytes)
3706 1.34 pooka {
3707 1.93 pooka register_t retval[2];
3708 1.34 pooka int error = 0;
3709 1.68 pooka int rv = -1;
3710 1.34 pooka struct sys_extattr_set_fd_args callarg;
3711 1.34 pooka
3712 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3713 1.34 pooka SPARG(&callarg, fd) = fd;
3714 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3715 1.34 pooka SPARG(&callarg, attrname) = attrname;
3716 1.34 pooka SPARG(&callarg, data) = data;
3717 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3718 1.34 pooka
3719 1.120 pgoyette error = rsys_syscall(SYS_extattr_set_fd, &callarg, sizeof(callarg), retval);
3720 1.63 pooka rsys_seterrno(error);
3721 1.68 pooka if (error == 0) {
3722 1.68 pooka if (sizeof(int) > sizeof(register_t))
3723 1.68 pooka rv = *(int *)retval;
3724 1.68 pooka else
3725 1.69 pooka rv = *retval;
3726 1.34 pooka }
3727 1.68 pooka return rv;
3728 1.34 pooka }
3729 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3730 1.103 pooka __weak_alias(extattr_set_fd,rump___sysimpl_extattr_set_fd);
3731 1.103 pooka __weak_alias(_extattr_set_fd,rump___sysimpl_extattr_set_fd);
3732 1.103 pooka __strong_alias(_sys_extattr_set_fd,rump___sysimpl_extattr_set_fd);
3733 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3734 1.34 pooka
3735 1.60 pooka ssize_t rump___sysimpl_extattr_get_fd(int, int, const char *, void *, size_t);
3736 1.34 pooka ssize_t
3737 1.60 pooka rump___sysimpl_extattr_get_fd(int fd, int attrnamespace, const char * attrname, void * data, size_t nbytes)
3738 1.34 pooka {
3739 1.93 pooka register_t retval[2];
3740 1.34 pooka int error = 0;
3741 1.68 pooka ssize_t rv = -1;
3742 1.34 pooka struct sys_extattr_get_fd_args callarg;
3743 1.34 pooka
3744 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3745 1.34 pooka SPARG(&callarg, fd) = fd;
3746 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3747 1.34 pooka SPARG(&callarg, attrname) = attrname;
3748 1.34 pooka SPARG(&callarg, data) = data;
3749 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3750 1.34 pooka
3751 1.120 pgoyette error = rsys_syscall(SYS_extattr_get_fd, &callarg, sizeof(callarg), retval);
3752 1.63 pooka rsys_seterrno(error);
3753 1.68 pooka if (error == 0) {
3754 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3755 1.68 pooka rv = *(ssize_t *)retval;
3756 1.68 pooka else
3757 1.69 pooka rv = *retval;
3758 1.34 pooka }
3759 1.68 pooka return rv;
3760 1.34 pooka }
3761 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3762 1.103 pooka __weak_alias(extattr_get_fd,rump___sysimpl_extattr_get_fd);
3763 1.103 pooka __weak_alias(_extattr_get_fd,rump___sysimpl_extattr_get_fd);
3764 1.103 pooka __strong_alias(_sys_extattr_get_fd,rump___sysimpl_extattr_get_fd);
3765 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3766 1.34 pooka
3767 1.60 pooka int rump___sysimpl_extattr_delete_fd(int, int, const char *);
3768 1.34 pooka int
3769 1.60 pooka rump___sysimpl_extattr_delete_fd(int fd, int attrnamespace, const char * attrname)
3770 1.34 pooka {
3771 1.93 pooka register_t retval[2];
3772 1.34 pooka int error = 0;
3773 1.68 pooka int rv = -1;
3774 1.34 pooka struct sys_extattr_delete_fd_args callarg;
3775 1.34 pooka
3776 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3777 1.34 pooka SPARG(&callarg, fd) = fd;
3778 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3779 1.34 pooka SPARG(&callarg, attrname) = attrname;
3780 1.34 pooka
3781 1.120 pgoyette error = rsys_syscall(SYS_extattr_delete_fd, &callarg, sizeof(callarg), retval);
3782 1.63 pooka rsys_seterrno(error);
3783 1.68 pooka if (error == 0) {
3784 1.68 pooka if (sizeof(int) > sizeof(register_t))
3785 1.68 pooka rv = *(int *)retval;
3786 1.68 pooka else
3787 1.69 pooka rv = *retval;
3788 1.34 pooka }
3789 1.68 pooka return rv;
3790 1.34 pooka }
3791 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3792 1.103 pooka __weak_alias(extattr_delete_fd,rump___sysimpl_extattr_delete_fd);
3793 1.103 pooka __weak_alias(_extattr_delete_fd,rump___sysimpl_extattr_delete_fd);
3794 1.103 pooka __strong_alias(_sys_extattr_delete_fd,rump___sysimpl_extattr_delete_fd);
3795 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3796 1.34 pooka
3797 1.60 pooka int rump___sysimpl_extattr_set_link(const char *, int, const char *, const void *, size_t);
3798 1.34 pooka int
3799 1.60 pooka rump___sysimpl_extattr_set_link(const char * path, int attrnamespace, const char * attrname, const void * data, size_t nbytes)
3800 1.34 pooka {
3801 1.93 pooka register_t retval[2];
3802 1.34 pooka int error = 0;
3803 1.68 pooka int rv = -1;
3804 1.34 pooka struct sys_extattr_set_link_args callarg;
3805 1.34 pooka
3806 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3807 1.34 pooka SPARG(&callarg, path) = path;
3808 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3809 1.34 pooka SPARG(&callarg, attrname) = attrname;
3810 1.34 pooka SPARG(&callarg, data) = data;
3811 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3812 1.34 pooka
3813 1.120 pgoyette error = rsys_syscall(SYS_extattr_set_link, &callarg, sizeof(callarg), retval);
3814 1.63 pooka rsys_seterrno(error);
3815 1.68 pooka if (error == 0) {
3816 1.68 pooka if (sizeof(int) > sizeof(register_t))
3817 1.68 pooka rv = *(int *)retval;
3818 1.68 pooka else
3819 1.69 pooka rv = *retval;
3820 1.34 pooka }
3821 1.68 pooka return rv;
3822 1.34 pooka }
3823 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3824 1.103 pooka __weak_alias(extattr_set_link,rump___sysimpl_extattr_set_link);
3825 1.103 pooka __weak_alias(_extattr_set_link,rump___sysimpl_extattr_set_link);
3826 1.103 pooka __strong_alias(_sys_extattr_set_link,rump___sysimpl_extattr_set_link);
3827 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3828 1.34 pooka
3829 1.60 pooka ssize_t rump___sysimpl_extattr_get_link(const char *, int, const char *, void *, size_t);
3830 1.34 pooka ssize_t
3831 1.60 pooka rump___sysimpl_extattr_get_link(const char * path, int attrnamespace, const char * attrname, void * data, size_t nbytes)
3832 1.34 pooka {
3833 1.93 pooka register_t retval[2];
3834 1.34 pooka int error = 0;
3835 1.68 pooka ssize_t rv = -1;
3836 1.34 pooka struct sys_extattr_get_link_args callarg;
3837 1.34 pooka
3838 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3839 1.34 pooka SPARG(&callarg, path) = path;
3840 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3841 1.34 pooka SPARG(&callarg, attrname) = attrname;
3842 1.34 pooka SPARG(&callarg, data) = data;
3843 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3844 1.34 pooka
3845 1.120 pgoyette error = rsys_syscall(SYS_extattr_get_link, &callarg, sizeof(callarg), retval);
3846 1.63 pooka rsys_seterrno(error);
3847 1.68 pooka if (error == 0) {
3848 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3849 1.68 pooka rv = *(ssize_t *)retval;
3850 1.68 pooka else
3851 1.69 pooka rv = *retval;
3852 1.34 pooka }
3853 1.68 pooka return rv;
3854 1.34 pooka }
3855 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3856 1.103 pooka __weak_alias(extattr_get_link,rump___sysimpl_extattr_get_link);
3857 1.103 pooka __weak_alias(_extattr_get_link,rump___sysimpl_extattr_get_link);
3858 1.103 pooka __strong_alias(_sys_extattr_get_link,rump___sysimpl_extattr_get_link);
3859 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3860 1.34 pooka
3861 1.60 pooka int rump___sysimpl_extattr_delete_link(const char *, int, const char *);
3862 1.34 pooka int
3863 1.60 pooka rump___sysimpl_extattr_delete_link(const char * path, int attrnamespace, const char * attrname)
3864 1.34 pooka {
3865 1.93 pooka register_t retval[2];
3866 1.34 pooka int error = 0;
3867 1.68 pooka int rv = -1;
3868 1.34 pooka struct sys_extattr_delete_link_args callarg;
3869 1.34 pooka
3870 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3871 1.34 pooka SPARG(&callarg, path) = path;
3872 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3873 1.34 pooka SPARG(&callarg, attrname) = attrname;
3874 1.34 pooka
3875 1.120 pgoyette error = rsys_syscall(SYS_extattr_delete_link, &callarg, sizeof(callarg), retval);
3876 1.63 pooka rsys_seterrno(error);
3877 1.68 pooka if (error == 0) {
3878 1.68 pooka if (sizeof(int) > sizeof(register_t))
3879 1.68 pooka rv = *(int *)retval;
3880 1.68 pooka else
3881 1.69 pooka rv = *retval;
3882 1.34 pooka }
3883 1.68 pooka return rv;
3884 1.34 pooka }
3885 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3886 1.103 pooka __weak_alias(extattr_delete_link,rump___sysimpl_extattr_delete_link);
3887 1.103 pooka __weak_alias(_extattr_delete_link,rump___sysimpl_extattr_delete_link);
3888 1.103 pooka __strong_alias(_sys_extattr_delete_link,rump___sysimpl_extattr_delete_link);
3889 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3890 1.34 pooka
3891 1.60 pooka ssize_t rump___sysimpl_extattr_list_fd(int, int, void *, size_t);
3892 1.34 pooka ssize_t
3893 1.60 pooka rump___sysimpl_extattr_list_fd(int fd, int attrnamespace, void * data, size_t nbytes)
3894 1.34 pooka {
3895 1.93 pooka register_t retval[2];
3896 1.34 pooka int error = 0;
3897 1.68 pooka ssize_t rv = -1;
3898 1.34 pooka struct sys_extattr_list_fd_args callarg;
3899 1.34 pooka
3900 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3901 1.34 pooka SPARG(&callarg, fd) = fd;
3902 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3903 1.34 pooka SPARG(&callarg, data) = data;
3904 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3905 1.34 pooka
3906 1.120 pgoyette error = rsys_syscall(SYS_extattr_list_fd, &callarg, sizeof(callarg), retval);
3907 1.63 pooka rsys_seterrno(error);
3908 1.68 pooka if (error == 0) {
3909 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3910 1.68 pooka rv = *(ssize_t *)retval;
3911 1.68 pooka else
3912 1.69 pooka rv = *retval;
3913 1.34 pooka }
3914 1.68 pooka return rv;
3915 1.34 pooka }
3916 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3917 1.103 pooka __weak_alias(extattr_list_fd,rump___sysimpl_extattr_list_fd);
3918 1.103 pooka __weak_alias(_extattr_list_fd,rump___sysimpl_extattr_list_fd);
3919 1.103 pooka __strong_alias(_sys_extattr_list_fd,rump___sysimpl_extattr_list_fd);
3920 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3921 1.34 pooka
3922 1.60 pooka ssize_t rump___sysimpl_extattr_list_file(const char *, int, void *, size_t);
3923 1.34 pooka ssize_t
3924 1.60 pooka rump___sysimpl_extattr_list_file(const char * path, int attrnamespace, void * data, size_t nbytes)
3925 1.34 pooka {
3926 1.93 pooka register_t retval[2];
3927 1.34 pooka int error = 0;
3928 1.68 pooka ssize_t rv = -1;
3929 1.34 pooka struct sys_extattr_list_file_args callarg;
3930 1.34 pooka
3931 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3932 1.34 pooka SPARG(&callarg, path) = path;
3933 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3934 1.34 pooka SPARG(&callarg, data) = data;
3935 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3936 1.34 pooka
3937 1.120 pgoyette error = rsys_syscall(SYS_extattr_list_file, &callarg, sizeof(callarg), retval);
3938 1.63 pooka rsys_seterrno(error);
3939 1.68 pooka if (error == 0) {
3940 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3941 1.68 pooka rv = *(ssize_t *)retval;
3942 1.68 pooka else
3943 1.69 pooka rv = *retval;
3944 1.34 pooka }
3945 1.68 pooka return rv;
3946 1.34 pooka }
3947 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3948 1.103 pooka __weak_alias(extattr_list_file,rump___sysimpl_extattr_list_file);
3949 1.103 pooka __weak_alias(_extattr_list_file,rump___sysimpl_extattr_list_file);
3950 1.103 pooka __strong_alias(_sys_extattr_list_file,rump___sysimpl_extattr_list_file);
3951 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3952 1.34 pooka
3953 1.60 pooka ssize_t rump___sysimpl_extattr_list_link(const char *, int, void *, size_t);
3954 1.34 pooka ssize_t
3955 1.60 pooka rump___sysimpl_extattr_list_link(const char * path, int attrnamespace, void * data, size_t nbytes)
3956 1.34 pooka {
3957 1.93 pooka register_t retval[2];
3958 1.34 pooka int error = 0;
3959 1.68 pooka ssize_t rv = -1;
3960 1.34 pooka struct sys_extattr_list_link_args callarg;
3961 1.34 pooka
3962 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3963 1.34 pooka SPARG(&callarg, path) = path;
3964 1.34 pooka SPARG(&callarg, attrnamespace) = attrnamespace;
3965 1.34 pooka SPARG(&callarg, data) = data;
3966 1.34 pooka SPARG(&callarg, nbytes) = nbytes;
3967 1.34 pooka
3968 1.120 pgoyette error = rsys_syscall(SYS_extattr_list_link, &callarg, sizeof(callarg), retval);
3969 1.63 pooka rsys_seterrno(error);
3970 1.68 pooka if (error == 0) {
3971 1.68 pooka if (sizeof(ssize_t) > sizeof(register_t))
3972 1.68 pooka rv = *(ssize_t *)retval;
3973 1.68 pooka else
3974 1.69 pooka rv = *retval;
3975 1.34 pooka }
3976 1.68 pooka return rv;
3977 1.34 pooka }
3978 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
3979 1.103 pooka __weak_alias(extattr_list_link,rump___sysimpl_extattr_list_link);
3980 1.103 pooka __weak_alias(_extattr_list_link,rump___sysimpl_extattr_list_link);
3981 1.103 pooka __strong_alias(_sys_extattr_list_link,rump___sysimpl_extattr_list_link);
3982 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
3983 1.34 pooka
3984 1.103 pooka #ifdef RUMP_SYS_COMPAT
3985 1.61 pooka int rump___sysimpl_pselect(int, fd_set *, fd_set *, fd_set *, const struct timespec *, const sigset_t *);
3986 1.61 pooka int
3987 1.61 pooka rump___sysimpl_pselect(int nd, fd_set * in, fd_set * ou, fd_set * ex, const struct timespec * ts, const sigset_t * mask)
3988 1.61 pooka {
3989 1.93 pooka register_t retval[2];
3990 1.61 pooka int error = 0;
3991 1.68 pooka int rv = -1;
3992 1.61 pooka struct compat_50_sys_pselect_args callarg;
3993 1.61 pooka
3994 1.95 pooka memset(&callarg, 0, sizeof(callarg));
3995 1.61 pooka SPARG(&callarg, nd) = nd;
3996 1.61 pooka SPARG(&callarg, in) = in;
3997 1.61 pooka SPARG(&callarg, ou) = ou;
3998 1.61 pooka SPARG(&callarg, ex) = ex;
3999 1.61 pooka SPARG(&callarg, ts) = (const struct timespec50 *)ts;
4000 1.61 pooka SPARG(&callarg, mask) = mask;
4001 1.61 pooka
4002 1.120 pgoyette error = rsys_syscall(SYS_compat_50_pselect, &callarg, sizeof(callarg), retval);
4003 1.63 pooka rsys_seterrno(error);
4004 1.68 pooka if (error == 0) {
4005 1.68 pooka if (sizeof(int) > sizeof(register_t))
4006 1.68 pooka rv = *(int *)retval;
4007 1.68 pooka else
4008 1.69 pooka rv = *retval;
4009 1.61 pooka }
4010 1.68 pooka return rv;
4011 1.61 pooka }
4012 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4013 1.103 pooka __weak_alias(pselect,rump___sysimpl_pselect);
4014 1.103 pooka __weak_alias(_pselect,rump___sysimpl_pselect);
4015 1.103 pooka __strong_alias(_sys_pselect,rump___sysimpl_pselect);
4016 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4017 1.103 pooka #endif /* RUMP_SYS_COMPAT */
4018 1.61 pooka
4019 1.103 pooka #ifdef RUMP_SYS_COMPAT
4020 1.60 pooka int rump___sysimpl_pollts(struct pollfd *, u_int, const struct timespec *, const sigset_t *);
4021 1.60 pooka int
4022 1.60 pooka rump___sysimpl_pollts(struct pollfd * fds, u_int nfds, const struct timespec * ts, const sigset_t * mask)
4023 1.60 pooka {
4024 1.93 pooka register_t retval[2];
4025 1.60 pooka int error = 0;
4026 1.68 pooka int rv = -1;
4027 1.60 pooka struct compat_50_sys_pollts_args callarg;
4028 1.60 pooka
4029 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4030 1.60 pooka SPARG(&callarg, fds) = fds;
4031 1.60 pooka SPARG(&callarg, nfds) = nfds;
4032 1.60 pooka SPARG(&callarg, ts) = (const struct timespec50 *)ts;
4033 1.60 pooka SPARG(&callarg, mask) = mask;
4034 1.60 pooka
4035 1.120 pgoyette error = rsys_syscall(SYS_compat_50_pollts, &callarg, sizeof(callarg), retval);
4036 1.63 pooka rsys_seterrno(error);
4037 1.68 pooka if (error == 0) {
4038 1.68 pooka if (sizeof(int) > sizeof(register_t))
4039 1.68 pooka rv = *(int *)retval;
4040 1.68 pooka else
4041 1.69 pooka rv = *retval;
4042 1.60 pooka }
4043 1.68 pooka return rv;
4044 1.60 pooka }
4045 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4046 1.103 pooka __weak_alias(pollts,rump___sysimpl_pollts);
4047 1.103 pooka __weak_alias(_pollts,rump___sysimpl_pollts);
4048 1.103 pooka __strong_alias(_sys_pollts,rump___sysimpl_pollts);
4049 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4050 1.103 pooka #endif /* RUMP_SYS_COMPAT */
4051 1.60 pooka
4052 1.73 drochner int rump___sysimpl_setxattr(const char *, const char *, const void *, size_t, int);
4053 1.34 pooka int
4054 1.73 drochner rump___sysimpl_setxattr(const char * path, const char * name, const void * value, size_t size, int flags)
4055 1.34 pooka {
4056 1.93 pooka register_t retval[2];
4057 1.34 pooka int error = 0;
4058 1.68 pooka int rv = -1;
4059 1.34 pooka struct sys_setxattr_args callarg;
4060 1.34 pooka
4061 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4062 1.34 pooka SPARG(&callarg, path) = path;
4063 1.34 pooka SPARG(&callarg, name) = name;
4064 1.34 pooka SPARG(&callarg, value) = value;
4065 1.34 pooka SPARG(&callarg, size) = size;
4066 1.34 pooka SPARG(&callarg, flags) = flags;
4067 1.34 pooka
4068 1.120 pgoyette error = rsys_syscall(SYS_setxattr, &callarg, sizeof(callarg), retval);
4069 1.63 pooka rsys_seterrno(error);
4070 1.68 pooka if (error == 0) {
4071 1.68 pooka if (sizeof(int) > sizeof(register_t))
4072 1.68 pooka rv = *(int *)retval;
4073 1.68 pooka else
4074 1.69 pooka rv = *retval;
4075 1.28 pooka }
4076 1.68 pooka return rv;
4077 1.28 pooka }
4078 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4079 1.103 pooka __weak_alias(setxattr,rump___sysimpl_setxattr);
4080 1.103 pooka __weak_alias(_setxattr,rump___sysimpl_setxattr);
4081 1.103 pooka __strong_alias(_sys_setxattr,rump___sysimpl_setxattr);
4082 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4083 1.28 pooka
4084 1.73 drochner int rump___sysimpl_lsetxattr(const char *, const char *, const void *, size_t, int);
4085 1.10 pooka int
4086 1.73 drochner rump___sysimpl_lsetxattr(const char * path, const char * name, const void * value, size_t size, int flags)
4087 1.1 pooka {
4088 1.93 pooka register_t retval[2];
4089 1.27 pooka int error = 0;
4090 1.68 pooka int rv = -1;
4091 1.34 pooka struct sys_lsetxattr_args callarg;
4092 1.1 pooka
4093 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4094 1.31 pooka SPARG(&callarg, path) = path;
4095 1.34 pooka SPARG(&callarg, name) = name;
4096 1.34 pooka SPARG(&callarg, value) = value;
4097 1.34 pooka SPARG(&callarg, size) = size;
4098 1.34 pooka SPARG(&callarg, flags) = flags;
4099 1.1 pooka
4100 1.120 pgoyette error = rsys_syscall(SYS_lsetxattr, &callarg, sizeof(callarg), retval);
4101 1.63 pooka rsys_seterrno(error);
4102 1.68 pooka if (error == 0) {
4103 1.68 pooka if (sizeof(int) > sizeof(register_t))
4104 1.68 pooka rv = *(int *)retval;
4105 1.68 pooka else
4106 1.69 pooka rv = *retval;
4107 1.27 pooka }
4108 1.68 pooka return rv;
4109 1.1 pooka }
4110 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4111 1.103 pooka __weak_alias(lsetxattr,rump___sysimpl_lsetxattr);
4112 1.103 pooka __weak_alias(_lsetxattr,rump___sysimpl_lsetxattr);
4113 1.103 pooka __strong_alias(_sys_lsetxattr,rump___sysimpl_lsetxattr);
4114 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4115 1.1 pooka
4116 1.73 drochner int rump___sysimpl_fsetxattr(int, const char *, const void *, size_t, int);
4117 1.1 pooka int
4118 1.73 drochner rump___sysimpl_fsetxattr(int fd, const char * name, const void * value, size_t size, int flags)
4119 1.1 pooka {
4120 1.93 pooka register_t retval[2];
4121 1.27 pooka int error = 0;
4122 1.68 pooka int rv = -1;
4123 1.34 pooka struct sys_fsetxattr_args callarg;
4124 1.1 pooka
4125 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4126 1.34 pooka SPARG(&callarg, fd) = fd;
4127 1.34 pooka SPARG(&callarg, name) = name;
4128 1.34 pooka SPARG(&callarg, value) = value;
4129 1.34 pooka SPARG(&callarg, size) = size;
4130 1.34 pooka SPARG(&callarg, flags) = flags;
4131 1.1 pooka
4132 1.120 pgoyette error = rsys_syscall(SYS_fsetxattr, &callarg, sizeof(callarg), retval);
4133 1.63 pooka rsys_seterrno(error);
4134 1.68 pooka if (error == 0) {
4135 1.68 pooka if (sizeof(int) > sizeof(register_t))
4136 1.68 pooka rv = *(int *)retval;
4137 1.68 pooka else
4138 1.69 pooka rv = *retval;
4139 1.27 pooka }
4140 1.68 pooka return rv;
4141 1.1 pooka }
4142 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4143 1.103 pooka __weak_alias(fsetxattr,rump___sysimpl_fsetxattr);
4144 1.103 pooka __weak_alias(_fsetxattr,rump___sysimpl_fsetxattr);
4145 1.103 pooka __strong_alias(_sys_fsetxattr,rump___sysimpl_fsetxattr);
4146 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4147 1.1 pooka
4148 1.60 pooka int rump___sysimpl_getxattr(const char *, const char *, void *, size_t);
4149 1.11 pooka int
4150 1.60 pooka rump___sysimpl_getxattr(const char * path, const char * name, void * value, size_t size)
4151 1.22 pooka {
4152 1.93 pooka register_t retval[2];
4153 1.27 pooka int error = 0;
4154 1.68 pooka int rv = -1;
4155 1.34 pooka struct sys_getxattr_args callarg;
4156 1.22 pooka
4157 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4158 1.34 pooka SPARG(&callarg, path) = path;
4159 1.34 pooka SPARG(&callarg, name) = name;
4160 1.34 pooka SPARG(&callarg, value) = value;
4161 1.34 pooka SPARG(&callarg, size) = size;
4162 1.22 pooka
4163 1.120 pgoyette error = rsys_syscall(SYS_getxattr, &callarg, sizeof(callarg), retval);
4164 1.63 pooka rsys_seterrno(error);
4165 1.68 pooka if (error == 0) {
4166 1.68 pooka if (sizeof(int) > sizeof(register_t))
4167 1.68 pooka rv = *(int *)retval;
4168 1.68 pooka else
4169 1.69 pooka rv = *retval;
4170 1.27 pooka }
4171 1.68 pooka return rv;
4172 1.22 pooka }
4173 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4174 1.103 pooka __weak_alias(getxattr,rump___sysimpl_getxattr);
4175 1.103 pooka __weak_alias(_getxattr,rump___sysimpl_getxattr);
4176 1.103 pooka __strong_alias(_sys_getxattr,rump___sysimpl_getxattr);
4177 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4178 1.22 pooka
4179 1.60 pooka int rump___sysimpl_lgetxattr(const char *, const char *, void *, size_t);
4180 1.34 pooka int
4181 1.60 pooka rump___sysimpl_lgetxattr(const char * path, const char * name, void * value, size_t size)
4182 1.8 pooka {
4183 1.93 pooka register_t retval[2];
4184 1.27 pooka int error = 0;
4185 1.68 pooka int rv = -1;
4186 1.34 pooka struct sys_lgetxattr_args callarg;
4187 1.8 pooka
4188 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4189 1.34 pooka SPARG(&callarg, path) = path;
4190 1.34 pooka SPARG(&callarg, name) = name;
4191 1.34 pooka SPARG(&callarg, value) = value;
4192 1.34 pooka SPARG(&callarg, size) = size;
4193 1.8 pooka
4194 1.120 pgoyette error = rsys_syscall(SYS_lgetxattr, &callarg, sizeof(callarg), retval);
4195 1.63 pooka rsys_seterrno(error);
4196 1.68 pooka if (error == 0) {
4197 1.68 pooka if (sizeof(int) > sizeof(register_t))
4198 1.68 pooka rv = *(int *)retval;
4199 1.68 pooka else
4200 1.69 pooka rv = *retval;
4201 1.27 pooka }
4202 1.68 pooka return rv;
4203 1.8 pooka }
4204 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4205 1.103 pooka __weak_alias(lgetxattr,rump___sysimpl_lgetxattr);
4206 1.103 pooka __weak_alias(_lgetxattr,rump___sysimpl_lgetxattr);
4207 1.103 pooka __strong_alias(_sys_lgetxattr,rump___sysimpl_lgetxattr);
4208 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4209 1.8 pooka
4210 1.60 pooka int rump___sysimpl_fgetxattr(int, const char *, void *, size_t);
4211 1.34 pooka int
4212 1.60 pooka rump___sysimpl_fgetxattr(int fd, const char * name, void * value, size_t size)
4213 1.8 pooka {
4214 1.93 pooka register_t retval[2];
4215 1.27 pooka int error = 0;
4216 1.68 pooka int rv = -1;
4217 1.34 pooka struct sys_fgetxattr_args callarg;
4218 1.8 pooka
4219 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4220 1.31 pooka SPARG(&callarg, fd) = fd;
4221 1.34 pooka SPARG(&callarg, name) = name;
4222 1.34 pooka SPARG(&callarg, value) = value;
4223 1.34 pooka SPARG(&callarg, size) = size;
4224 1.8 pooka
4225 1.120 pgoyette error = rsys_syscall(SYS_fgetxattr, &callarg, sizeof(callarg), retval);
4226 1.63 pooka rsys_seterrno(error);
4227 1.68 pooka if (error == 0) {
4228 1.68 pooka if (sizeof(int) > sizeof(register_t))
4229 1.68 pooka rv = *(int *)retval;
4230 1.68 pooka else
4231 1.69 pooka rv = *retval;
4232 1.27 pooka }
4233 1.68 pooka return rv;
4234 1.8 pooka }
4235 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4236 1.103 pooka __weak_alias(fgetxattr,rump___sysimpl_fgetxattr);
4237 1.103 pooka __weak_alias(_fgetxattr,rump___sysimpl_fgetxattr);
4238 1.103 pooka __strong_alias(_sys_fgetxattr,rump___sysimpl_fgetxattr);
4239 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4240 1.8 pooka
4241 1.60 pooka int rump___sysimpl_listxattr(const char *, char *, size_t);
4242 1.1 pooka int
4243 1.60 pooka rump___sysimpl_listxattr(const char * path, char * list, size_t size)
4244 1.1 pooka {
4245 1.93 pooka register_t retval[2];
4246 1.27 pooka int error = 0;
4247 1.68 pooka int rv = -1;
4248 1.34 pooka struct sys_listxattr_args callarg;
4249 1.1 pooka
4250 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4251 1.31 pooka SPARG(&callarg, path) = path;
4252 1.34 pooka SPARG(&callarg, list) = list;
4253 1.34 pooka SPARG(&callarg, size) = size;
4254 1.1 pooka
4255 1.120 pgoyette error = rsys_syscall(SYS_listxattr, &callarg, sizeof(callarg), retval);
4256 1.63 pooka rsys_seterrno(error);
4257 1.68 pooka if (error == 0) {
4258 1.68 pooka if (sizeof(int) > sizeof(register_t))
4259 1.68 pooka rv = *(int *)retval;
4260 1.68 pooka else
4261 1.69 pooka rv = *retval;
4262 1.27 pooka }
4263 1.68 pooka return rv;
4264 1.1 pooka }
4265 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4266 1.103 pooka __weak_alias(listxattr,rump___sysimpl_listxattr);
4267 1.103 pooka __weak_alias(_listxattr,rump___sysimpl_listxattr);
4268 1.103 pooka __strong_alias(_sys_listxattr,rump___sysimpl_listxattr);
4269 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4270 1.1 pooka
4271 1.60 pooka int rump___sysimpl_llistxattr(const char *, char *, size_t);
4272 1.1 pooka int
4273 1.60 pooka rump___sysimpl_llistxattr(const char * path, char * list, size_t size)
4274 1.13 pooka {
4275 1.93 pooka register_t retval[2];
4276 1.27 pooka int error = 0;
4277 1.68 pooka int rv = -1;
4278 1.34 pooka struct sys_llistxattr_args callarg;
4279 1.13 pooka
4280 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4281 1.34 pooka SPARG(&callarg, path) = path;
4282 1.34 pooka SPARG(&callarg, list) = list;
4283 1.34 pooka SPARG(&callarg, size) = size;
4284 1.13 pooka
4285 1.120 pgoyette error = rsys_syscall(SYS_llistxattr, &callarg, sizeof(callarg), retval);
4286 1.63 pooka rsys_seterrno(error);
4287 1.68 pooka if (error == 0) {
4288 1.68 pooka if (sizeof(int) > sizeof(register_t))
4289 1.68 pooka rv = *(int *)retval;
4290 1.68 pooka else
4291 1.69 pooka rv = *retval;
4292 1.27 pooka }
4293 1.68 pooka return rv;
4294 1.13 pooka }
4295 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4296 1.103 pooka __weak_alias(llistxattr,rump___sysimpl_llistxattr);
4297 1.103 pooka __weak_alias(_llistxattr,rump___sysimpl_llistxattr);
4298 1.103 pooka __strong_alias(_sys_llistxattr,rump___sysimpl_llistxattr);
4299 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4300 1.13 pooka
4301 1.60 pooka int rump___sysimpl_flistxattr(int, char *, size_t);
4302 1.13 pooka int
4303 1.60 pooka rump___sysimpl_flistxattr(int fd, char * list, size_t size)
4304 1.1 pooka {
4305 1.93 pooka register_t retval[2];
4306 1.27 pooka int error = 0;
4307 1.68 pooka int rv = -1;
4308 1.34 pooka struct sys_flistxattr_args callarg;
4309 1.1 pooka
4310 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4311 1.34 pooka SPARG(&callarg, fd) = fd;
4312 1.34 pooka SPARG(&callarg, list) = list;
4313 1.34 pooka SPARG(&callarg, size) = size;
4314 1.1 pooka
4315 1.120 pgoyette error = rsys_syscall(SYS_flistxattr, &callarg, sizeof(callarg), retval);
4316 1.63 pooka rsys_seterrno(error);
4317 1.68 pooka if (error == 0) {
4318 1.68 pooka if (sizeof(int) > sizeof(register_t))
4319 1.68 pooka rv = *(int *)retval;
4320 1.68 pooka else
4321 1.69 pooka rv = *retval;
4322 1.27 pooka }
4323 1.68 pooka return rv;
4324 1.1 pooka }
4325 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4326 1.103 pooka __weak_alias(flistxattr,rump___sysimpl_flistxattr);
4327 1.103 pooka __weak_alias(_flistxattr,rump___sysimpl_flistxattr);
4328 1.103 pooka __strong_alias(_sys_flistxattr,rump___sysimpl_flistxattr);
4329 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4330 1.1 pooka
4331 1.60 pooka int rump___sysimpl_removexattr(const char *, const char *);
4332 1.1 pooka int
4333 1.60 pooka rump___sysimpl_removexattr(const char * path, const char * name)
4334 1.1 pooka {
4335 1.93 pooka register_t retval[2];
4336 1.27 pooka int error = 0;
4337 1.68 pooka int rv = -1;
4338 1.34 pooka struct sys_removexattr_args callarg;
4339 1.1 pooka
4340 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4341 1.31 pooka SPARG(&callarg, path) = path;
4342 1.34 pooka SPARG(&callarg, name) = name;
4343 1.1 pooka
4344 1.120 pgoyette error = rsys_syscall(SYS_removexattr, &callarg, sizeof(callarg), retval);
4345 1.63 pooka rsys_seterrno(error);
4346 1.68 pooka if (error == 0) {
4347 1.68 pooka if (sizeof(int) > sizeof(register_t))
4348 1.68 pooka rv = *(int *)retval;
4349 1.68 pooka else
4350 1.69 pooka rv = *retval;
4351 1.27 pooka }
4352 1.68 pooka return rv;
4353 1.1 pooka }
4354 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4355 1.103 pooka __weak_alias(removexattr,rump___sysimpl_removexattr);
4356 1.103 pooka __weak_alias(_removexattr,rump___sysimpl_removexattr);
4357 1.103 pooka __strong_alias(_sys_removexattr,rump___sysimpl_removexattr);
4358 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4359 1.1 pooka
4360 1.60 pooka int rump___sysimpl_lremovexattr(const char *, const char *);
4361 1.10 pooka int
4362 1.60 pooka rump___sysimpl_lremovexattr(const char * path, const char * name)
4363 1.11 pooka {
4364 1.93 pooka register_t retval[2];
4365 1.27 pooka int error = 0;
4366 1.68 pooka int rv = -1;
4367 1.34 pooka struct sys_lremovexattr_args callarg;
4368 1.11 pooka
4369 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4370 1.31 pooka SPARG(&callarg, path) = path;
4371 1.34 pooka SPARG(&callarg, name) = name;
4372 1.11 pooka
4373 1.120 pgoyette error = rsys_syscall(SYS_lremovexattr, &callarg, sizeof(callarg), retval);
4374 1.63 pooka rsys_seterrno(error);
4375 1.68 pooka if (error == 0) {
4376 1.68 pooka if (sizeof(int) > sizeof(register_t))
4377 1.68 pooka rv = *(int *)retval;
4378 1.68 pooka else
4379 1.69 pooka rv = *retval;
4380 1.27 pooka }
4381 1.68 pooka return rv;
4382 1.11 pooka }
4383 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4384 1.103 pooka __weak_alias(lremovexattr,rump___sysimpl_lremovexattr);
4385 1.103 pooka __weak_alias(_lremovexattr,rump___sysimpl_lremovexattr);
4386 1.103 pooka __strong_alias(_sys_lremovexattr,rump___sysimpl_lremovexattr);
4387 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4388 1.11 pooka
4389 1.60 pooka int rump___sysimpl_fremovexattr(int, const char *);
4390 1.32 pooka int
4391 1.60 pooka rump___sysimpl_fremovexattr(int fd, const char * name)
4392 1.32 pooka {
4393 1.93 pooka register_t retval[2];
4394 1.32 pooka int error = 0;
4395 1.68 pooka int rv = -1;
4396 1.34 pooka struct sys_fremovexattr_args callarg;
4397 1.34 pooka
4398 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4399 1.34 pooka SPARG(&callarg, fd) = fd;
4400 1.34 pooka SPARG(&callarg, name) = name;
4401 1.32 pooka
4402 1.120 pgoyette error = rsys_syscall(SYS_fremovexattr, &callarg, sizeof(callarg), retval);
4403 1.63 pooka rsys_seterrno(error);
4404 1.68 pooka if (error == 0) {
4405 1.68 pooka if (sizeof(int) > sizeof(register_t))
4406 1.68 pooka rv = *(int *)retval;
4407 1.68 pooka else
4408 1.69 pooka rv = *retval;
4409 1.32 pooka }
4410 1.68 pooka return rv;
4411 1.32 pooka }
4412 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4413 1.103 pooka __weak_alias(fremovexattr,rump___sysimpl_fremovexattr);
4414 1.103 pooka __weak_alias(_fremovexattr,rump___sysimpl_fremovexattr);
4415 1.103 pooka __strong_alias(_sys_fremovexattr,rump___sysimpl_fremovexattr);
4416 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4417 1.32 pooka
4418 1.103 pooka #ifdef RUMP_SYS_COMPAT
4419 1.60 pooka int rump___sysimpl_stat30(const char *, struct stat *);
4420 1.60 pooka int
4421 1.60 pooka rump___sysimpl_stat30(const char * path, struct stat * ub)
4422 1.60 pooka {
4423 1.93 pooka register_t retval[2];
4424 1.60 pooka int error = 0;
4425 1.68 pooka int rv = -1;
4426 1.60 pooka struct compat_50_sys___stat30_args callarg;
4427 1.60 pooka
4428 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4429 1.60 pooka SPARG(&callarg, path) = path;
4430 1.60 pooka SPARG(&callarg, ub) = (struct stat30 *)ub;
4431 1.60 pooka
4432 1.120 pgoyette error = rsys_syscall(SYS_compat_50___stat30, &callarg, sizeof(callarg), retval);
4433 1.63 pooka rsys_seterrno(error);
4434 1.68 pooka if (error == 0) {
4435 1.68 pooka if (sizeof(int) > sizeof(register_t))
4436 1.68 pooka rv = *(int *)retval;
4437 1.68 pooka else
4438 1.69 pooka rv = *retval;
4439 1.60 pooka }
4440 1.68 pooka return rv;
4441 1.60 pooka }
4442 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4443 1.103 pooka __weak_alias(stat,rump___sysimpl_stat30);
4444 1.103 pooka __weak_alias(__stat30,rump___sysimpl_stat30);
4445 1.103 pooka __weak_alias(___stat30,rump___sysimpl_stat30);
4446 1.103 pooka __strong_alias(_sys___stat30,rump___sysimpl_stat30);
4447 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4448 1.103 pooka #endif /* RUMP_SYS_COMPAT */
4449 1.60 pooka
4450 1.103 pooka #ifdef RUMP_SYS_COMPAT
4451 1.60 pooka int rump___sysimpl_fstat30(int, struct stat *);
4452 1.60 pooka int
4453 1.60 pooka rump___sysimpl_fstat30(int fd, struct stat * sb)
4454 1.60 pooka {
4455 1.93 pooka register_t retval[2];
4456 1.60 pooka int error = 0;
4457 1.68 pooka int rv = -1;
4458 1.60 pooka struct compat_50_sys___fstat30_args callarg;
4459 1.60 pooka
4460 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4461 1.60 pooka SPARG(&callarg, fd) = fd;
4462 1.60 pooka SPARG(&callarg, sb) = (struct stat30 *)sb;
4463 1.60 pooka
4464 1.120 pgoyette error = rsys_syscall(SYS_compat_50___fstat30, &callarg, sizeof(callarg), retval);
4465 1.63 pooka rsys_seterrno(error);
4466 1.68 pooka if (error == 0) {
4467 1.68 pooka if (sizeof(int) > sizeof(register_t))
4468 1.68 pooka rv = *(int *)retval;
4469 1.68 pooka else
4470 1.69 pooka rv = *retval;
4471 1.60 pooka }
4472 1.68 pooka return rv;
4473 1.60 pooka }
4474 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4475 1.103 pooka __weak_alias(fstat,rump___sysimpl_fstat30);
4476 1.103 pooka __weak_alias(__fstat30,rump___sysimpl_fstat30);
4477 1.103 pooka __weak_alias(___fstat30,rump___sysimpl_fstat30);
4478 1.103 pooka __strong_alias(_sys___fstat30,rump___sysimpl_fstat30);
4479 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4480 1.103 pooka #endif /* RUMP_SYS_COMPAT */
4481 1.60 pooka
4482 1.103 pooka #ifdef RUMP_SYS_COMPAT
4483 1.60 pooka int rump___sysimpl_lstat30(const char *, struct stat *);
4484 1.60 pooka int
4485 1.60 pooka rump___sysimpl_lstat30(const char * path, struct stat * ub)
4486 1.60 pooka {
4487 1.93 pooka register_t retval[2];
4488 1.60 pooka int error = 0;
4489 1.68 pooka int rv = -1;
4490 1.60 pooka struct compat_50_sys___lstat30_args callarg;
4491 1.60 pooka
4492 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4493 1.60 pooka SPARG(&callarg, path) = path;
4494 1.60 pooka SPARG(&callarg, ub) = (struct stat30 *)ub;
4495 1.60 pooka
4496 1.120 pgoyette error = rsys_syscall(SYS_compat_50___lstat30, &callarg, sizeof(callarg), retval);
4497 1.63 pooka rsys_seterrno(error);
4498 1.68 pooka if (error == 0) {
4499 1.68 pooka if (sizeof(int) > sizeof(register_t))
4500 1.68 pooka rv = *(int *)retval;
4501 1.68 pooka else
4502 1.69 pooka rv = *retval;
4503 1.60 pooka }
4504 1.68 pooka return rv;
4505 1.60 pooka }
4506 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4507 1.103 pooka __weak_alias(lstat,rump___sysimpl_lstat30);
4508 1.103 pooka __weak_alias(__lstat30,rump___sysimpl_lstat30);
4509 1.103 pooka __weak_alias(___lstat30,rump___sysimpl_lstat30);
4510 1.103 pooka __strong_alias(_sys___lstat30,rump___sysimpl_lstat30);
4511 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4512 1.103 pooka #endif /* RUMP_SYS_COMPAT */
4513 1.60 pooka
4514 1.60 pooka int rump___sysimpl_getdents30(int, char *, size_t);
4515 1.11 pooka int
4516 1.60 pooka rump___sysimpl_getdents30(int fd, char * buf, size_t count)
4517 1.10 pooka {
4518 1.93 pooka register_t retval[2];
4519 1.27 pooka int error = 0;
4520 1.68 pooka int rv = -1;
4521 1.34 pooka struct sys___getdents30_args callarg;
4522 1.10 pooka
4523 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4524 1.34 pooka SPARG(&callarg, fd) = fd;
4525 1.31 pooka SPARG(&callarg, buf) = buf;
4526 1.34 pooka SPARG(&callarg, count) = count;
4527 1.10 pooka
4528 1.120 pgoyette error = rsys_syscall(SYS___getdents30, &callarg, sizeof(callarg), retval);
4529 1.63 pooka rsys_seterrno(error);
4530 1.68 pooka if (error == 0) {
4531 1.68 pooka if (sizeof(int) > sizeof(register_t))
4532 1.68 pooka rv = *(int *)retval;
4533 1.68 pooka else
4534 1.69 pooka rv = *retval;
4535 1.27 pooka }
4536 1.68 pooka return rv;
4537 1.23 christos }
4538 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4539 1.103 pooka __weak_alias(getdents,rump___sysimpl_getdents30);
4540 1.103 pooka __weak_alias(__getdents30,rump___sysimpl_getdents30);
4541 1.103 pooka __weak_alias(___getdents30,rump___sysimpl_getdents30);
4542 1.103 pooka __strong_alias(_sys___getdents30,rump___sysimpl_getdents30);
4543 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4544 1.23 christos
4545 1.60 pooka int rump___sysimpl_socket30(int, int, int);
4546 1.23 christos int
4547 1.60 pooka rump___sysimpl_socket30(int domain, int type, int protocol)
4548 1.23 christos {
4549 1.93 pooka register_t retval[2];
4550 1.27 pooka int error = 0;
4551 1.68 pooka int rv = -1;
4552 1.31 pooka struct sys___socket30_args callarg;
4553 1.23 christos
4554 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4555 1.31 pooka SPARG(&callarg, domain) = domain;
4556 1.31 pooka SPARG(&callarg, type) = type;
4557 1.31 pooka SPARG(&callarg, protocol) = protocol;
4558 1.23 christos
4559 1.120 pgoyette error = rsys_syscall(SYS___socket30, &callarg, sizeof(callarg), retval);
4560 1.63 pooka rsys_seterrno(error);
4561 1.68 pooka if (error == 0) {
4562 1.68 pooka if (sizeof(int) > sizeof(register_t))
4563 1.68 pooka rv = *(int *)retval;
4564 1.68 pooka else
4565 1.69 pooka rv = *retval;
4566 1.27 pooka }
4567 1.68 pooka return rv;
4568 1.23 christos }
4569 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4570 1.103 pooka __weak_alias(socket,rump___sysimpl_socket30);
4571 1.103 pooka __weak_alias(__socket30,rump___sysimpl_socket30);
4572 1.103 pooka __weak_alias(___socket30,rump___sysimpl_socket30);
4573 1.103 pooka __strong_alias(_sys___socket30,rump___sysimpl_socket30);
4574 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4575 1.23 christos
4576 1.60 pooka int rump___sysimpl_getfh30(const char *, void *, size_t *);
4577 1.23 christos int
4578 1.60 pooka rump___sysimpl_getfh30(const char * fname, void * fhp, size_t * fh_size)
4579 1.23 christos {
4580 1.93 pooka register_t retval[2];
4581 1.27 pooka int error = 0;
4582 1.68 pooka int rv = -1;
4583 1.31 pooka struct sys___getfh30_args callarg;
4584 1.23 christos
4585 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4586 1.31 pooka SPARG(&callarg, fname) = fname;
4587 1.31 pooka SPARG(&callarg, fhp) = fhp;
4588 1.31 pooka SPARG(&callarg, fh_size) = fh_size;
4589 1.23 christos
4590 1.120 pgoyette error = rsys_syscall(SYS___getfh30, &callarg, sizeof(callarg), retval);
4591 1.63 pooka rsys_seterrno(error);
4592 1.68 pooka if (error == 0) {
4593 1.68 pooka if (sizeof(int) > sizeof(register_t))
4594 1.68 pooka rv = *(int *)retval;
4595 1.68 pooka else
4596 1.69 pooka rv = *retval;
4597 1.27 pooka }
4598 1.68 pooka return rv;
4599 1.10 pooka }
4600 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4601 1.103 pooka __weak_alias(getfh,rump___sysimpl_getfh30);
4602 1.103 pooka __weak_alias(__getfh30,rump___sysimpl_getfh30);
4603 1.103 pooka __weak_alias(___getfh30,rump___sysimpl_getfh30);
4604 1.103 pooka __strong_alias(_sys___getfh30,rump___sysimpl_getfh30);
4605 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4606 1.10 pooka
4607 1.60 pooka int rump___sysimpl_fhopen40(const void *, size_t, int);
4608 1.36 pooka int
4609 1.60 pooka rump___sysimpl_fhopen40(const void * fhp, size_t fh_size, int flags)
4610 1.36 pooka {
4611 1.93 pooka register_t retval[2];
4612 1.36 pooka int error = 0;
4613 1.68 pooka int rv = -1;
4614 1.36 pooka struct sys___fhopen40_args callarg;
4615 1.36 pooka
4616 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4617 1.36 pooka SPARG(&callarg, fhp) = fhp;
4618 1.36 pooka SPARG(&callarg, fh_size) = fh_size;
4619 1.36 pooka SPARG(&callarg, flags) = flags;
4620 1.36 pooka
4621 1.120 pgoyette error = rsys_syscall(SYS___fhopen40, &callarg, sizeof(callarg), retval);
4622 1.63 pooka rsys_seterrno(error);
4623 1.68 pooka if (error == 0) {
4624 1.68 pooka if (sizeof(int) > sizeof(register_t))
4625 1.68 pooka rv = *(int *)retval;
4626 1.68 pooka else
4627 1.69 pooka rv = *retval;
4628 1.36 pooka }
4629 1.68 pooka return rv;
4630 1.36 pooka }
4631 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4632 1.103 pooka __weak_alias(fhopen,rump___sysimpl_fhopen40);
4633 1.103 pooka __weak_alias(__fhopen40,rump___sysimpl_fhopen40);
4634 1.103 pooka __weak_alias(___fhopen40,rump___sysimpl_fhopen40);
4635 1.103 pooka __strong_alias(_sys___fhopen40,rump___sysimpl_fhopen40);
4636 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4637 1.36 pooka
4638 1.103 pooka #ifdef RUMP_SYS_COMPAT
4639 1.61 pooka int rump___sysimpl_fhstat40(const void *, size_t, struct stat *);
4640 1.61 pooka int
4641 1.61 pooka rump___sysimpl_fhstat40(const void * fhp, size_t fh_size, struct stat * sb)
4642 1.61 pooka {
4643 1.93 pooka register_t retval[2];
4644 1.61 pooka int error = 0;
4645 1.68 pooka int rv = -1;
4646 1.61 pooka struct compat_50_sys___fhstat40_args callarg;
4647 1.61 pooka
4648 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4649 1.61 pooka SPARG(&callarg, fhp) = fhp;
4650 1.61 pooka SPARG(&callarg, fh_size) = fh_size;
4651 1.61 pooka SPARG(&callarg, sb) = (struct stat30 *)sb;
4652 1.61 pooka
4653 1.120 pgoyette error = rsys_syscall(SYS_compat_50___fhstat40, &callarg, sizeof(callarg), retval);
4654 1.63 pooka rsys_seterrno(error);
4655 1.68 pooka if (error == 0) {
4656 1.68 pooka if (sizeof(int) > sizeof(register_t))
4657 1.68 pooka rv = *(int *)retval;
4658 1.68 pooka else
4659 1.69 pooka rv = *retval;
4660 1.61 pooka }
4661 1.68 pooka return rv;
4662 1.61 pooka }
4663 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4664 1.103 pooka __weak_alias(fhstat,rump___sysimpl_fhstat40);
4665 1.103 pooka __weak_alias(__fhstat40,rump___sysimpl_fhstat40);
4666 1.103 pooka __weak_alias(___fhstat40,rump___sysimpl_fhstat40);
4667 1.103 pooka __strong_alias(_sys___fhstat40,rump___sysimpl_fhstat40);
4668 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4669 1.103 pooka #endif /* RUMP_SYS_COMPAT */
4670 1.61 pooka
4671 1.99 pooka int rump___sysimpl_aio_cancel(int, struct aiocb *);
4672 1.99 pooka int
4673 1.99 pooka rump___sysimpl_aio_cancel(int fildes, struct aiocb * aiocbp)
4674 1.99 pooka {
4675 1.99 pooka register_t retval[2];
4676 1.99 pooka int error = 0;
4677 1.99 pooka int rv = -1;
4678 1.99 pooka struct sys_aio_cancel_args callarg;
4679 1.99 pooka
4680 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4681 1.99 pooka SPARG(&callarg, fildes) = fildes;
4682 1.99 pooka SPARG(&callarg, aiocbp) = aiocbp;
4683 1.99 pooka
4684 1.120 pgoyette error = rsys_syscall(SYS_aio_cancel, &callarg, sizeof(callarg), retval);
4685 1.99 pooka rsys_seterrno(error);
4686 1.99 pooka if (error == 0) {
4687 1.99 pooka if (sizeof(int) > sizeof(register_t))
4688 1.99 pooka rv = *(int *)retval;
4689 1.99 pooka else
4690 1.99 pooka rv = *retval;
4691 1.99 pooka }
4692 1.99 pooka return rv;
4693 1.99 pooka }
4694 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4695 1.103 pooka __weak_alias(aio_cancel,rump___sysimpl_aio_cancel);
4696 1.103 pooka __weak_alias(_aio_cancel,rump___sysimpl_aio_cancel);
4697 1.103 pooka __strong_alias(_sys_aio_cancel,rump___sysimpl_aio_cancel);
4698 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4699 1.99 pooka
4700 1.99 pooka int rump___sysimpl_aio_error(const struct aiocb *);
4701 1.99 pooka int
4702 1.99 pooka rump___sysimpl_aio_error(const struct aiocb * aiocbp)
4703 1.99 pooka {
4704 1.99 pooka register_t retval[2];
4705 1.99 pooka int error = 0;
4706 1.99 pooka int rv = -1;
4707 1.99 pooka struct sys_aio_error_args callarg;
4708 1.99 pooka
4709 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4710 1.99 pooka SPARG(&callarg, aiocbp) = aiocbp;
4711 1.99 pooka
4712 1.120 pgoyette error = rsys_syscall(SYS_aio_error, &callarg, sizeof(callarg), retval);
4713 1.99 pooka rsys_seterrno(error);
4714 1.99 pooka if (error == 0) {
4715 1.99 pooka if (sizeof(int) > sizeof(register_t))
4716 1.99 pooka rv = *(int *)retval;
4717 1.99 pooka else
4718 1.99 pooka rv = *retval;
4719 1.99 pooka }
4720 1.99 pooka return rv;
4721 1.99 pooka }
4722 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4723 1.103 pooka __weak_alias(aio_error,rump___sysimpl_aio_error);
4724 1.103 pooka __weak_alias(_aio_error,rump___sysimpl_aio_error);
4725 1.103 pooka __strong_alias(_sys_aio_error,rump___sysimpl_aio_error);
4726 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4727 1.99 pooka
4728 1.99 pooka int rump___sysimpl_aio_fsync(int, struct aiocb *);
4729 1.99 pooka int
4730 1.99 pooka rump___sysimpl_aio_fsync(int op, struct aiocb * aiocbp)
4731 1.99 pooka {
4732 1.99 pooka register_t retval[2];
4733 1.99 pooka int error = 0;
4734 1.99 pooka int rv = -1;
4735 1.99 pooka struct sys_aio_fsync_args callarg;
4736 1.99 pooka
4737 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4738 1.99 pooka SPARG(&callarg, op) = op;
4739 1.99 pooka SPARG(&callarg, aiocbp) = aiocbp;
4740 1.99 pooka
4741 1.120 pgoyette error = rsys_syscall(SYS_aio_fsync, &callarg, sizeof(callarg), retval);
4742 1.99 pooka rsys_seterrno(error);
4743 1.99 pooka if (error == 0) {
4744 1.99 pooka if (sizeof(int) > sizeof(register_t))
4745 1.99 pooka rv = *(int *)retval;
4746 1.99 pooka else
4747 1.99 pooka rv = *retval;
4748 1.99 pooka }
4749 1.99 pooka return rv;
4750 1.99 pooka }
4751 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4752 1.103 pooka __weak_alias(aio_fsync,rump___sysimpl_aio_fsync);
4753 1.103 pooka __weak_alias(_aio_fsync,rump___sysimpl_aio_fsync);
4754 1.103 pooka __strong_alias(_sys_aio_fsync,rump___sysimpl_aio_fsync);
4755 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4756 1.99 pooka
4757 1.99 pooka int rump___sysimpl_aio_read(struct aiocb *);
4758 1.99 pooka int
4759 1.99 pooka rump___sysimpl_aio_read(struct aiocb * aiocbp)
4760 1.99 pooka {
4761 1.99 pooka register_t retval[2];
4762 1.99 pooka int error = 0;
4763 1.99 pooka int rv = -1;
4764 1.99 pooka struct sys_aio_read_args callarg;
4765 1.99 pooka
4766 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4767 1.99 pooka SPARG(&callarg, aiocbp) = aiocbp;
4768 1.99 pooka
4769 1.120 pgoyette error = rsys_syscall(SYS_aio_read, &callarg, sizeof(callarg), retval);
4770 1.99 pooka rsys_seterrno(error);
4771 1.99 pooka if (error == 0) {
4772 1.99 pooka if (sizeof(int) > sizeof(register_t))
4773 1.99 pooka rv = *(int *)retval;
4774 1.99 pooka else
4775 1.99 pooka rv = *retval;
4776 1.99 pooka }
4777 1.99 pooka return rv;
4778 1.99 pooka }
4779 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4780 1.103 pooka __weak_alias(aio_read,rump___sysimpl_aio_read);
4781 1.103 pooka __weak_alias(_aio_read,rump___sysimpl_aio_read);
4782 1.103 pooka __strong_alias(_sys_aio_read,rump___sysimpl_aio_read);
4783 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4784 1.99 pooka
4785 1.99 pooka int rump___sysimpl_aio_return(struct aiocb *);
4786 1.99 pooka int
4787 1.99 pooka rump___sysimpl_aio_return(struct aiocb * aiocbp)
4788 1.99 pooka {
4789 1.99 pooka register_t retval[2];
4790 1.99 pooka int error = 0;
4791 1.99 pooka int rv = -1;
4792 1.99 pooka struct sys_aio_return_args callarg;
4793 1.99 pooka
4794 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4795 1.99 pooka SPARG(&callarg, aiocbp) = aiocbp;
4796 1.99 pooka
4797 1.120 pgoyette error = rsys_syscall(SYS_aio_return, &callarg, sizeof(callarg), retval);
4798 1.99 pooka rsys_seterrno(error);
4799 1.99 pooka if (error == 0) {
4800 1.99 pooka if (sizeof(int) > sizeof(register_t))
4801 1.99 pooka rv = *(int *)retval;
4802 1.99 pooka else
4803 1.99 pooka rv = *retval;
4804 1.99 pooka }
4805 1.99 pooka return rv;
4806 1.99 pooka }
4807 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4808 1.103 pooka __weak_alias(aio_return,rump___sysimpl_aio_return);
4809 1.103 pooka __weak_alias(_aio_return,rump___sysimpl_aio_return);
4810 1.103 pooka __strong_alias(_sys_aio_return,rump___sysimpl_aio_return);
4811 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4812 1.99 pooka
4813 1.99 pooka int rump___sysimpl_aio_write(struct aiocb *);
4814 1.99 pooka int
4815 1.99 pooka rump___sysimpl_aio_write(struct aiocb * aiocbp)
4816 1.99 pooka {
4817 1.99 pooka register_t retval[2];
4818 1.99 pooka int error = 0;
4819 1.99 pooka int rv = -1;
4820 1.99 pooka struct sys_aio_write_args callarg;
4821 1.99 pooka
4822 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4823 1.99 pooka SPARG(&callarg, aiocbp) = aiocbp;
4824 1.99 pooka
4825 1.120 pgoyette error = rsys_syscall(SYS_aio_write, &callarg, sizeof(callarg), retval);
4826 1.99 pooka rsys_seterrno(error);
4827 1.99 pooka if (error == 0) {
4828 1.99 pooka if (sizeof(int) > sizeof(register_t))
4829 1.99 pooka rv = *(int *)retval;
4830 1.99 pooka else
4831 1.99 pooka rv = *retval;
4832 1.99 pooka }
4833 1.99 pooka return rv;
4834 1.99 pooka }
4835 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4836 1.103 pooka __weak_alias(aio_write,rump___sysimpl_aio_write);
4837 1.103 pooka __weak_alias(_aio_write,rump___sysimpl_aio_write);
4838 1.103 pooka __strong_alias(_sys_aio_write,rump___sysimpl_aio_write);
4839 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4840 1.99 pooka
4841 1.99 pooka int rump___sysimpl_lio_listio(int, struct aiocb *const *, int, struct sigevent *);
4842 1.99 pooka int
4843 1.99 pooka rump___sysimpl_lio_listio(int mode, struct aiocb *const * list, int nent, struct sigevent * sig)
4844 1.99 pooka {
4845 1.99 pooka register_t retval[2];
4846 1.99 pooka int error = 0;
4847 1.99 pooka int rv = -1;
4848 1.99 pooka struct sys_lio_listio_args callarg;
4849 1.99 pooka
4850 1.99 pooka memset(&callarg, 0, sizeof(callarg));
4851 1.99 pooka SPARG(&callarg, mode) = mode;
4852 1.99 pooka SPARG(&callarg, list) = list;
4853 1.99 pooka SPARG(&callarg, nent) = nent;
4854 1.99 pooka SPARG(&callarg, sig) = sig;
4855 1.99 pooka
4856 1.120 pgoyette error = rsys_syscall(SYS_lio_listio, &callarg, sizeof(callarg), retval);
4857 1.99 pooka rsys_seterrno(error);
4858 1.99 pooka if (error == 0) {
4859 1.99 pooka if (sizeof(int) > sizeof(register_t))
4860 1.99 pooka rv = *(int *)retval;
4861 1.99 pooka else
4862 1.99 pooka rv = *retval;
4863 1.99 pooka }
4864 1.99 pooka return rv;
4865 1.99 pooka }
4866 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4867 1.103 pooka __weak_alias(lio_listio,rump___sysimpl_lio_listio);
4868 1.103 pooka __weak_alias(_lio_listio,rump___sysimpl_lio_listio);
4869 1.103 pooka __strong_alias(_sys_lio_listio,rump___sysimpl_lio_listio);
4870 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4871 1.99 pooka
4872 1.60 pooka int rump___sysimpl_mount50(const char *, const char *, int, void *, size_t);
4873 1.33 pooka int
4874 1.60 pooka rump___sysimpl_mount50(const char * type, const char * path, int flags, void * data, size_t data_len)
4875 1.33 pooka {
4876 1.93 pooka register_t retval[2];
4877 1.33 pooka int error = 0;
4878 1.68 pooka int rv = -1;
4879 1.33 pooka struct sys___mount50_args callarg;
4880 1.33 pooka
4881 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4882 1.33 pooka SPARG(&callarg, type) = type;
4883 1.33 pooka SPARG(&callarg, path) = path;
4884 1.33 pooka SPARG(&callarg, flags) = flags;
4885 1.33 pooka SPARG(&callarg, data) = data;
4886 1.33 pooka SPARG(&callarg, data_len) = data_len;
4887 1.33 pooka
4888 1.120 pgoyette error = rsys_syscall(SYS___mount50, &callarg, sizeof(callarg), retval);
4889 1.63 pooka rsys_seterrno(error);
4890 1.68 pooka if (error == 0) {
4891 1.68 pooka if (sizeof(int) > sizeof(register_t))
4892 1.68 pooka rv = *(int *)retval;
4893 1.68 pooka else
4894 1.69 pooka rv = *retval;
4895 1.33 pooka }
4896 1.68 pooka return rv;
4897 1.33 pooka }
4898 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4899 1.103 pooka __weak_alias(mount,rump___sysimpl_mount50);
4900 1.103 pooka __weak_alias(__mount50,rump___sysimpl_mount50);
4901 1.103 pooka __weak_alias(___mount50,rump___sysimpl_mount50);
4902 1.103 pooka __strong_alias(_sys___mount50,rump___sysimpl_mount50);
4903 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4904 1.33 pooka
4905 1.60 pooka int rump___sysimpl_posix_fadvise50(int, off_t, off_t, int);
4906 1.54 pooka int
4907 1.60 pooka rump___sysimpl_posix_fadvise50(int fd, off_t offset, off_t len, int advice)
4908 1.54 pooka {
4909 1.93 pooka register_t retval[2];
4910 1.68 pooka int rv = -1;
4911 1.54 pooka struct sys___posix_fadvise50_args callarg;
4912 1.54 pooka
4913 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4914 1.54 pooka SPARG(&callarg, fd) = fd;
4915 1.54 pooka SPARG(&callarg, PAD) = 0;
4916 1.54 pooka SPARG(&callarg, offset) = offset;
4917 1.54 pooka SPARG(&callarg, len) = len;
4918 1.54 pooka SPARG(&callarg, advice) = advice;
4919 1.54 pooka
4920 1.119 pgoyette (void)rsys_syscall(SYS___posix_fadvise50, &callarg, sizeof(callarg), retval);
4921 1.68 pooka if (sizeof(int) > sizeof(register_t))
4922 1.68 pooka rv = *(int *)retval;
4923 1.68 pooka else
4924 1.69 pooka rv = *retval;
4925 1.68 pooka return rv;
4926 1.54 pooka }
4927 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4928 1.103 pooka __weak_alias(posix_fadvise,rump___sysimpl_posix_fadvise50);
4929 1.103 pooka __weak_alias(__posix_fadvise50,rump___sysimpl_posix_fadvise50);
4930 1.103 pooka __weak_alias(___posix_fadvise50,rump___sysimpl_posix_fadvise50);
4931 1.103 pooka __strong_alias(_sys___posix_fadvise50,rump___sysimpl_posix_fadvise50);
4932 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4933 1.54 pooka
4934 1.60 pooka int rump___sysimpl_select50(int, fd_set *, fd_set *, fd_set *, struct timeval *);
4935 1.34 pooka int
4936 1.60 pooka rump___sysimpl_select50(int nd, fd_set * in, fd_set * ou, fd_set * ex, struct timeval * tv)
4937 1.34 pooka {
4938 1.93 pooka register_t retval[2];
4939 1.34 pooka int error = 0;
4940 1.68 pooka int rv = -1;
4941 1.34 pooka struct sys___select50_args callarg;
4942 1.34 pooka
4943 1.95 pooka memset(&callarg, 0, sizeof(callarg));
4944 1.34 pooka SPARG(&callarg, nd) = nd;
4945 1.34 pooka SPARG(&callarg, in) = in;
4946 1.34 pooka SPARG(&callarg, ou) = ou;
4947 1.34 pooka SPARG(&callarg, ex) = ex;
4948 1.34 pooka SPARG(&callarg, tv) = tv;
4949 1.34 pooka
4950 1.120 pgoyette error = rsys_syscall(SYS___select50, &callarg, sizeof(callarg), retval);
4951 1.63 pooka rsys_seterrno(error);
4952 1.68 pooka if (error == 0) {
4953 1.68 pooka if (sizeof(int) > sizeof(register_t))
4954 1.68 pooka rv = *(int *)retval;
4955 1.68 pooka else
4956 1.69 pooka rv = *retval;
4957 1.34 pooka }
4958 1.68 pooka return rv;
4959 1.34 pooka }
4960 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4961 1.103 pooka __weak_alias(select,rump___sysimpl_select50);
4962 1.103 pooka __weak_alias(__select50,rump___sysimpl_select50);
4963 1.103 pooka __weak_alias(___select50,rump___sysimpl_select50);
4964 1.103 pooka __strong_alias(_sys___select50,rump___sysimpl_select50);
4965 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4966 1.34 pooka
4967 1.98 pooka int rump___sysimpl_gettimeofday50(struct timeval *, void *);
4968 1.98 pooka int
4969 1.98 pooka rump___sysimpl_gettimeofday50(struct timeval * tp, void * tzp)
4970 1.98 pooka {
4971 1.98 pooka register_t retval[2];
4972 1.98 pooka int error = 0;
4973 1.98 pooka int rv = -1;
4974 1.98 pooka struct sys___gettimeofday50_args callarg;
4975 1.98 pooka
4976 1.98 pooka memset(&callarg, 0, sizeof(callarg));
4977 1.98 pooka SPARG(&callarg, tp) = tp;
4978 1.98 pooka SPARG(&callarg, tzp) = tzp;
4979 1.98 pooka
4980 1.120 pgoyette error = rsys_syscall(SYS___gettimeofday50, &callarg, sizeof(callarg), retval);
4981 1.98 pooka rsys_seterrno(error);
4982 1.98 pooka if (error == 0) {
4983 1.98 pooka if (sizeof(int) > sizeof(register_t))
4984 1.98 pooka rv = *(int *)retval;
4985 1.98 pooka else
4986 1.98 pooka rv = *retval;
4987 1.98 pooka }
4988 1.98 pooka return rv;
4989 1.98 pooka }
4990 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
4991 1.103 pooka __weak_alias(gettimeofday,rump___sysimpl_gettimeofday50);
4992 1.103 pooka __weak_alias(__gettimeofday50,rump___sysimpl_gettimeofday50);
4993 1.103 pooka __weak_alias(___gettimeofday50,rump___sysimpl_gettimeofday50);
4994 1.103 pooka __strong_alias(_sys___gettimeofday50,rump___sysimpl_gettimeofday50);
4995 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
4996 1.98 pooka
4997 1.98 pooka int rump___sysimpl_settimeofday50(const struct timeval *, const void *);
4998 1.98 pooka int
4999 1.98 pooka rump___sysimpl_settimeofday50(const struct timeval * tv, const void * tzp)
5000 1.98 pooka {
5001 1.98 pooka register_t retval[2];
5002 1.98 pooka int error = 0;
5003 1.98 pooka int rv = -1;
5004 1.98 pooka struct sys___settimeofday50_args callarg;
5005 1.98 pooka
5006 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5007 1.98 pooka SPARG(&callarg, tv) = tv;
5008 1.98 pooka SPARG(&callarg, tzp) = tzp;
5009 1.98 pooka
5010 1.120 pgoyette error = rsys_syscall(SYS___settimeofday50, &callarg, sizeof(callarg), retval);
5011 1.98 pooka rsys_seterrno(error);
5012 1.98 pooka if (error == 0) {
5013 1.98 pooka if (sizeof(int) > sizeof(register_t))
5014 1.98 pooka rv = *(int *)retval;
5015 1.98 pooka else
5016 1.98 pooka rv = *retval;
5017 1.98 pooka }
5018 1.98 pooka return rv;
5019 1.98 pooka }
5020 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5021 1.103 pooka __weak_alias(settimeofday,rump___sysimpl_settimeofday50);
5022 1.103 pooka __weak_alias(__settimeofday50,rump___sysimpl_settimeofday50);
5023 1.103 pooka __weak_alias(___settimeofday50,rump___sysimpl_settimeofday50);
5024 1.103 pooka __strong_alias(_sys___settimeofday50,rump___sysimpl_settimeofday50);
5025 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5026 1.98 pooka
5027 1.60 pooka int rump___sysimpl_utimes50(const char *, const struct timeval *);
5028 1.10 pooka int
5029 1.60 pooka rump___sysimpl_utimes50(const char * path, const struct timeval * tptr)
5030 1.22 pooka {
5031 1.93 pooka register_t retval[2];
5032 1.27 pooka int error = 0;
5033 1.68 pooka int rv = -1;
5034 1.31 pooka struct sys___utimes50_args callarg;
5035 1.22 pooka
5036 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5037 1.31 pooka SPARG(&callarg, path) = path;
5038 1.31 pooka SPARG(&callarg, tptr) = tptr;
5039 1.22 pooka
5040 1.120 pgoyette error = rsys_syscall(SYS___utimes50, &callarg, sizeof(callarg), retval);
5041 1.63 pooka rsys_seterrno(error);
5042 1.68 pooka if (error == 0) {
5043 1.68 pooka if (sizeof(int) > sizeof(register_t))
5044 1.68 pooka rv = *(int *)retval;
5045 1.68 pooka else
5046 1.69 pooka rv = *retval;
5047 1.27 pooka }
5048 1.68 pooka return rv;
5049 1.22 pooka }
5050 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5051 1.103 pooka __weak_alias(utimes,rump___sysimpl_utimes50);
5052 1.103 pooka __weak_alias(__utimes50,rump___sysimpl_utimes50);
5053 1.103 pooka __weak_alias(___utimes50,rump___sysimpl_utimes50);
5054 1.103 pooka __strong_alias(_sys___utimes50,rump___sysimpl_utimes50);
5055 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5056 1.22 pooka
5057 1.98 pooka int rump___sysimpl_adjtime50(const struct timeval *, struct timeval *);
5058 1.98 pooka int
5059 1.98 pooka rump___sysimpl_adjtime50(const struct timeval * delta, struct timeval * olddelta)
5060 1.98 pooka {
5061 1.98 pooka register_t retval[2];
5062 1.98 pooka int error = 0;
5063 1.98 pooka int rv = -1;
5064 1.98 pooka struct sys___adjtime50_args callarg;
5065 1.98 pooka
5066 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5067 1.98 pooka SPARG(&callarg, delta) = delta;
5068 1.98 pooka SPARG(&callarg, olddelta) = olddelta;
5069 1.98 pooka
5070 1.120 pgoyette error = rsys_syscall(SYS___adjtime50, &callarg, sizeof(callarg), retval);
5071 1.98 pooka rsys_seterrno(error);
5072 1.98 pooka if (error == 0) {
5073 1.98 pooka if (sizeof(int) > sizeof(register_t))
5074 1.98 pooka rv = *(int *)retval;
5075 1.98 pooka else
5076 1.98 pooka rv = *retval;
5077 1.98 pooka }
5078 1.98 pooka return rv;
5079 1.98 pooka }
5080 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5081 1.103 pooka __weak_alias(adjtime,rump___sysimpl_adjtime50);
5082 1.103 pooka __weak_alias(__adjtime50,rump___sysimpl_adjtime50);
5083 1.103 pooka __weak_alias(___adjtime50,rump___sysimpl_adjtime50);
5084 1.103 pooka __strong_alias(_sys___adjtime50,rump___sysimpl_adjtime50);
5085 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5086 1.98 pooka
5087 1.60 pooka int rump___sysimpl_futimes50(int, const struct timeval *);
5088 1.34 pooka int
5089 1.60 pooka rump___sysimpl_futimes50(int fd, const struct timeval * tptr)
5090 1.34 pooka {
5091 1.93 pooka register_t retval[2];
5092 1.34 pooka int error = 0;
5093 1.68 pooka int rv = -1;
5094 1.34 pooka struct sys___futimes50_args callarg;
5095 1.34 pooka
5096 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5097 1.34 pooka SPARG(&callarg, fd) = fd;
5098 1.34 pooka SPARG(&callarg, tptr) = tptr;
5099 1.34 pooka
5100 1.120 pgoyette error = rsys_syscall(SYS___futimes50, &callarg, sizeof(callarg), retval);
5101 1.63 pooka rsys_seterrno(error);
5102 1.68 pooka if (error == 0) {
5103 1.68 pooka if (sizeof(int) > sizeof(register_t))
5104 1.68 pooka rv = *(int *)retval;
5105 1.68 pooka else
5106 1.69 pooka rv = *retval;
5107 1.34 pooka }
5108 1.68 pooka return rv;
5109 1.34 pooka }
5110 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5111 1.103 pooka __weak_alias(futimes,rump___sysimpl_futimes50);
5112 1.103 pooka __weak_alias(__futimes50,rump___sysimpl_futimes50);
5113 1.103 pooka __weak_alias(___futimes50,rump___sysimpl_futimes50);
5114 1.103 pooka __strong_alias(_sys___futimes50,rump___sysimpl_futimes50);
5115 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5116 1.34 pooka
5117 1.60 pooka int rump___sysimpl_lutimes50(const char *, const struct timeval *);
5118 1.22 pooka int
5119 1.60 pooka rump___sysimpl_lutimes50(const char * path, const struct timeval * tptr)
5120 1.10 pooka {
5121 1.93 pooka register_t retval[2];
5122 1.27 pooka int error = 0;
5123 1.68 pooka int rv = -1;
5124 1.31 pooka struct sys___lutimes50_args callarg;
5125 1.10 pooka
5126 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5127 1.31 pooka SPARG(&callarg, path) = path;
5128 1.31 pooka SPARG(&callarg, tptr) = tptr;
5129 1.10 pooka
5130 1.120 pgoyette error = rsys_syscall(SYS___lutimes50, &callarg, sizeof(callarg), retval);
5131 1.63 pooka rsys_seterrno(error);
5132 1.68 pooka if (error == 0) {
5133 1.68 pooka if (sizeof(int) > sizeof(register_t))
5134 1.68 pooka rv = *(int *)retval;
5135 1.68 pooka else
5136 1.69 pooka rv = *retval;
5137 1.27 pooka }
5138 1.68 pooka return rv;
5139 1.10 pooka }
5140 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5141 1.103 pooka __weak_alias(lutimes,rump___sysimpl_lutimes50);
5142 1.103 pooka __weak_alias(__lutimes50,rump___sysimpl_lutimes50);
5143 1.103 pooka __weak_alias(___lutimes50,rump___sysimpl_lutimes50);
5144 1.103 pooka __strong_alias(_sys___lutimes50,rump___sysimpl_lutimes50);
5145 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5146 1.10 pooka
5147 1.98 pooka int rump___sysimpl_setitimer50(int, const struct itimerval *, struct itimerval *);
5148 1.98 pooka int
5149 1.98 pooka rump___sysimpl_setitimer50(int which, const struct itimerval * itv, struct itimerval * oitv)
5150 1.98 pooka {
5151 1.98 pooka register_t retval[2];
5152 1.98 pooka int error = 0;
5153 1.98 pooka int rv = -1;
5154 1.98 pooka struct sys___setitimer50_args callarg;
5155 1.98 pooka
5156 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5157 1.98 pooka SPARG(&callarg, which) = which;
5158 1.98 pooka SPARG(&callarg, itv) = itv;
5159 1.98 pooka SPARG(&callarg, oitv) = oitv;
5160 1.98 pooka
5161 1.120 pgoyette error = rsys_syscall(SYS___setitimer50, &callarg, sizeof(callarg), retval);
5162 1.98 pooka rsys_seterrno(error);
5163 1.98 pooka if (error == 0) {
5164 1.98 pooka if (sizeof(int) > sizeof(register_t))
5165 1.98 pooka rv = *(int *)retval;
5166 1.98 pooka else
5167 1.98 pooka rv = *retval;
5168 1.98 pooka }
5169 1.98 pooka return rv;
5170 1.98 pooka }
5171 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5172 1.103 pooka __weak_alias(setitimer,rump___sysimpl_setitimer50);
5173 1.103 pooka __weak_alias(__setitimer50,rump___sysimpl_setitimer50);
5174 1.103 pooka __weak_alias(___setitimer50,rump___sysimpl_setitimer50);
5175 1.103 pooka __strong_alias(_sys___setitimer50,rump___sysimpl_setitimer50);
5176 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5177 1.98 pooka
5178 1.98 pooka int rump___sysimpl_getitimer50(int, struct itimerval *);
5179 1.98 pooka int
5180 1.98 pooka rump___sysimpl_getitimer50(int which, struct itimerval * itv)
5181 1.98 pooka {
5182 1.98 pooka register_t retval[2];
5183 1.98 pooka int error = 0;
5184 1.98 pooka int rv = -1;
5185 1.98 pooka struct sys___getitimer50_args callarg;
5186 1.98 pooka
5187 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5188 1.98 pooka SPARG(&callarg, which) = which;
5189 1.98 pooka SPARG(&callarg, itv) = itv;
5190 1.98 pooka
5191 1.120 pgoyette error = rsys_syscall(SYS___getitimer50, &callarg, sizeof(callarg), retval);
5192 1.98 pooka rsys_seterrno(error);
5193 1.98 pooka if (error == 0) {
5194 1.98 pooka if (sizeof(int) > sizeof(register_t))
5195 1.98 pooka rv = *(int *)retval;
5196 1.98 pooka else
5197 1.98 pooka rv = *retval;
5198 1.98 pooka }
5199 1.98 pooka return rv;
5200 1.98 pooka }
5201 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5202 1.103 pooka __weak_alias(getitimer,rump___sysimpl_getitimer50);
5203 1.103 pooka __weak_alias(__getitimer50,rump___sysimpl_getitimer50);
5204 1.103 pooka __weak_alias(___getitimer50,rump___sysimpl_getitimer50);
5205 1.103 pooka __strong_alias(_sys___getitimer50,rump___sysimpl_getitimer50);
5206 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5207 1.98 pooka
5208 1.98 pooka int rump___sysimpl_clock_gettime50(clockid_t, struct timespec *);
5209 1.98 pooka int
5210 1.98 pooka rump___sysimpl_clock_gettime50(clockid_t clock_id, struct timespec * tp)
5211 1.98 pooka {
5212 1.98 pooka register_t retval[2];
5213 1.98 pooka int error = 0;
5214 1.98 pooka int rv = -1;
5215 1.98 pooka struct sys___clock_gettime50_args callarg;
5216 1.98 pooka
5217 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5218 1.98 pooka SPARG(&callarg, clock_id) = clock_id;
5219 1.98 pooka SPARG(&callarg, tp) = tp;
5220 1.98 pooka
5221 1.120 pgoyette error = rsys_syscall(SYS___clock_gettime50, &callarg, sizeof(callarg), retval);
5222 1.98 pooka rsys_seterrno(error);
5223 1.98 pooka if (error == 0) {
5224 1.98 pooka if (sizeof(int) > sizeof(register_t))
5225 1.98 pooka rv = *(int *)retval;
5226 1.98 pooka else
5227 1.98 pooka rv = *retval;
5228 1.98 pooka }
5229 1.98 pooka return rv;
5230 1.98 pooka }
5231 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5232 1.103 pooka __weak_alias(clock_gettime,rump___sysimpl_clock_gettime50);
5233 1.103 pooka __weak_alias(__clock_gettime50,rump___sysimpl_clock_gettime50);
5234 1.103 pooka __weak_alias(___clock_gettime50,rump___sysimpl_clock_gettime50);
5235 1.103 pooka __strong_alias(_sys___clock_gettime50,rump___sysimpl_clock_gettime50);
5236 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5237 1.98 pooka
5238 1.98 pooka int rump___sysimpl_clock_settime50(clockid_t, const struct timespec *);
5239 1.98 pooka int
5240 1.98 pooka rump___sysimpl_clock_settime50(clockid_t clock_id, const struct timespec * tp)
5241 1.98 pooka {
5242 1.98 pooka register_t retval[2];
5243 1.98 pooka int error = 0;
5244 1.98 pooka int rv = -1;
5245 1.98 pooka struct sys___clock_settime50_args callarg;
5246 1.98 pooka
5247 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5248 1.98 pooka SPARG(&callarg, clock_id) = clock_id;
5249 1.98 pooka SPARG(&callarg, tp) = tp;
5250 1.98 pooka
5251 1.120 pgoyette error = rsys_syscall(SYS___clock_settime50, &callarg, sizeof(callarg), retval);
5252 1.98 pooka rsys_seterrno(error);
5253 1.98 pooka if (error == 0) {
5254 1.98 pooka if (sizeof(int) > sizeof(register_t))
5255 1.98 pooka rv = *(int *)retval;
5256 1.98 pooka else
5257 1.98 pooka rv = *retval;
5258 1.98 pooka }
5259 1.98 pooka return rv;
5260 1.98 pooka }
5261 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5262 1.103 pooka __weak_alias(clock_settime,rump___sysimpl_clock_settime50);
5263 1.103 pooka __weak_alias(__clock_settime50,rump___sysimpl_clock_settime50);
5264 1.103 pooka __weak_alias(___clock_settime50,rump___sysimpl_clock_settime50);
5265 1.103 pooka __strong_alias(_sys___clock_settime50,rump___sysimpl_clock_settime50);
5266 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5267 1.98 pooka
5268 1.98 pooka int rump___sysimpl_clock_getres50(clockid_t, struct timespec *);
5269 1.98 pooka int
5270 1.98 pooka rump___sysimpl_clock_getres50(clockid_t clock_id, struct timespec * tp)
5271 1.98 pooka {
5272 1.98 pooka register_t retval[2];
5273 1.98 pooka int error = 0;
5274 1.98 pooka int rv = -1;
5275 1.98 pooka struct sys___clock_getres50_args callarg;
5276 1.98 pooka
5277 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5278 1.98 pooka SPARG(&callarg, clock_id) = clock_id;
5279 1.98 pooka SPARG(&callarg, tp) = tp;
5280 1.98 pooka
5281 1.120 pgoyette error = rsys_syscall(SYS___clock_getres50, &callarg, sizeof(callarg), retval);
5282 1.98 pooka rsys_seterrno(error);
5283 1.98 pooka if (error == 0) {
5284 1.98 pooka if (sizeof(int) > sizeof(register_t))
5285 1.98 pooka rv = *(int *)retval;
5286 1.98 pooka else
5287 1.98 pooka rv = *retval;
5288 1.98 pooka }
5289 1.98 pooka return rv;
5290 1.98 pooka }
5291 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5292 1.103 pooka __weak_alias(clock_getres,rump___sysimpl_clock_getres50);
5293 1.103 pooka __weak_alias(__clock_getres50,rump___sysimpl_clock_getres50);
5294 1.103 pooka __weak_alias(___clock_getres50,rump___sysimpl_clock_getres50);
5295 1.103 pooka __strong_alias(_sys___clock_getres50,rump___sysimpl_clock_getres50);
5296 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5297 1.98 pooka
5298 1.98 pooka int rump___sysimpl_nanosleep50(const struct timespec *, struct timespec *);
5299 1.98 pooka int
5300 1.98 pooka rump___sysimpl_nanosleep50(const struct timespec * rqtp, struct timespec * rmtp)
5301 1.98 pooka {
5302 1.98 pooka register_t retval[2];
5303 1.98 pooka int error = 0;
5304 1.98 pooka int rv = -1;
5305 1.98 pooka struct sys___nanosleep50_args callarg;
5306 1.98 pooka
5307 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5308 1.98 pooka SPARG(&callarg, rqtp) = rqtp;
5309 1.98 pooka SPARG(&callarg, rmtp) = rmtp;
5310 1.98 pooka
5311 1.120 pgoyette error = rsys_syscall(SYS___nanosleep50, &callarg, sizeof(callarg), retval);
5312 1.98 pooka rsys_seterrno(error);
5313 1.98 pooka if (error == 0) {
5314 1.98 pooka if (sizeof(int) > sizeof(register_t))
5315 1.98 pooka rv = *(int *)retval;
5316 1.98 pooka else
5317 1.98 pooka rv = *retval;
5318 1.98 pooka }
5319 1.98 pooka return rv;
5320 1.98 pooka }
5321 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5322 1.103 pooka __weak_alias(nanosleep,rump___sysimpl_nanosleep50);
5323 1.103 pooka __weak_alias(__nanosleep50,rump___sysimpl_nanosleep50);
5324 1.103 pooka __weak_alias(___nanosleep50,rump___sysimpl_nanosleep50);
5325 1.103 pooka __strong_alias(_sys___nanosleep50,rump___sysimpl_nanosleep50);
5326 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5327 1.98 pooka
5328 1.60 pooka int rump___sysimpl_kevent50(int, const struct kevent *, size_t, struct kevent *, size_t, const struct timespec *);
5329 1.32 pooka int
5330 1.60 pooka rump___sysimpl_kevent50(int fd, const struct kevent * changelist, size_t nchanges, struct kevent * eventlist, size_t nevents, const struct timespec * timeout)
5331 1.32 pooka {
5332 1.93 pooka register_t retval[2];
5333 1.32 pooka int error = 0;
5334 1.68 pooka int rv = -1;
5335 1.32 pooka struct sys___kevent50_args callarg;
5336 1.32 pooka
5337 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5338 1.32 pooka SPARG(&callarg, fd) = fd;
5339 1.32 pooka SPARG(&callarg, changelist) = changelist;
5340 1.32 pooka SPARG(&callarg, nchanges) = nchanges;
5341 1.32 pooka SPARG(&callarg, eventlist) = eventlist;
5342 1.32 pooka SPARG(&callarg, nevents) = nevents;
5343 1.32 pooka SPARG(&callarg, timeout) = timeout;
5344 1.32 pooka
5345 1.120 pgoyette error = rsys_syscall(SYS___kevent50, &callarg, sizeof(callarg), retval);
5346 1.63 pooka rsys_seterrno(error);
5347 1.68 pooka if (error == 0) {
5348 1.68 pooka if (sizeof(int) > sizeof(register_t))
5349 1.68 pooka rv = *(int *)retval;
5350 1.68 pooka else
5351 1.69 pooka rv = *retval;
5352 1.32 pooka }
5353 1.68 pooka return rv;
5354 1.32 pooka }
5355 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5356 1.103 pooka __weak_alias(kevent,rump___sysimpl_kevent50);
5357 1.103 pooka __weak_alias(__kevent50,rump___sysimpl_kevent50);
5358 1.103 pooka __weak_alias(___kevent50,rump___sysimpl_kevent50);
5359 1.103 pooka __strong_alias(_sys___kevent50,rump___sysimpl_kevent50);
5360 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5361 1.32 pooka
5362 1.60 pooka int rump___sysimpl_pselect50(int, fd_set *, fd_set *, fd_set *, const struct timespec *, const sigset_t *);
5363 1.34 pooka int
5364 1.60 pooka rump___sysimpl_pselect50(int nd, fd_set * in, fd_set * ou, fd_set * ex, const struct timespec * ts, const sigset_t * mask)
5365 1.34 pooka {
5366 1.93 pooka register_t retval[2];
5367 1.34 pooka int error = 0;
5368 1.68 pooka int rv = -1;
5369 1.34 pooka struct sys___pselect50_args callarg;
5370 1.34 pooka
5371 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5372 1.34 pooka SPARG(&callarg, nd) = nd;
5373 1.34 pooka SPARG(&callarg, in) = in;
5374 1.34 pooka SPARG(&callarg, ou) = ou;
5375 1.34 pooka SPARG(&callarg, ex) = ex;
5376 1.34 pooka SPARG(&callarg, ts) = ts;
5377 1.34 pooka SPARG(&callarg, mask) = mask;
5378 1.34 pooka
5379 1.120 pgoyette error = rsys_syscall(SYS___pselect50, &callarg, sizeof(callarg), retval);
5380 1.63 pooka rsys_seterrno(error);
5381 1.68 pooka if (error == 0) {
5382 1.68 pooka if (sizeof(int) > sizeof(register_t))
5383 1.68 pooka rv = *(int *)retval;
5384 1.68 pooka else
5385 1.69 pooka rv = *retval;
5386 1.34 pooka }
5387 1.68 pooka return rv;
5388 1.34 pooka }
5389 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5390 1.103 pooka __weak_alias(pselect,rump___sysimpl_pselect50);
5391 1.103 pooka __weak_alias(__pselect50,rump___sysimpl_pselect50);
5392 1.103 pooka __weak_alias(___pselect50,rump___sysimpl_pselect50);
5393 1.103 pooka __strong_alias(_sys___pselect50,rump___sysimpl_pselect50);
5394 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5395 1.34 pooka
5396 1.60 pooka int rump___sysimpl_pollts50(struct pollfd *, u_int, const struct timespec *, const sigset_t *);
5397 1.34 pooka int
5398 1.60 pooka rump___sysimpl_pollts50(struct pollfd * fds, u_int nfds, const struct timespec * ts, const sigset_t * mask)
5399 1.34 pooka {
5400 1.93 pooka register_t retval[2];
5401 1.34 pooka int error = 0;
5402 1.68 pooka int rv = -1;
5403 1.34 pooka struct sys___pollts50_args callarg;
5404 1.34 pooka
5405 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5406 1.34 pooka SPARG(&callarg, fds) = fds;
5407 1.34 pooka SPARG(&callarg, nfds) = nfds;
5408 1.34 pooka SPARG(&callarg, ts) = ts;
5409 1.34 pooka SPARG(&callarg, mask) = mask;
5410 1.34 pooka
5411 1.120 pgoyette error = rsys_syscall(SYS___pollts50, &callarg, sizeof(callarg), retval);
5412 1.63 pooka rsys_seterrno(error);
5413 1.68 pooka if (error == 0) {
5414 1.68 pooka if (sizeof(int) > sizeof(register_t))
5415 1.68 pooka rv = *(int *)retval;
5416 1.68 pooka else
5417 1.69 pooka rv = *retval;
5418 1.34 pooka }
5419 1.68 pooka return rv;
5420 1.34 pooka }
5421 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5422 1.103 pooka __weak_alias(pollts,rump___sysimpl_pollts50);
5423 1.103 pooka __weak_alias(__pollts50,rump___sysimpl_pollts50);
5424 1.103 pooka __weak_alias(___pollts50,rump___sysimpl_pollts50);
5425 1.103 pooka __strong_alias(_sys___pollts50,rump___sysimpl_pollts50);
5426 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5427 1.34 pooka
5428 1.99 pooka int rump___sysimpl_aio_suspend50(const struct aiocb *const *, int, const struct timespec *);
5429 1.99 pooka int
5430 1.99 pooka rump___sysimpl_aio_suspend50(const struct aiocb *const * list, int nent, const struct timespec * timeout)
5431 1.99 pooka {
5432 1.99 pooka register_t retval[2];
5433 1.99 pooka int error = 0;
5434 1.99 pooka int rv = -1;
5435 1.99 pooka struct sys___aio_suspend50_args callarg;
5436 1.99 pooka
5437 1.99 pooka memset(&callarg, 0, sizeof(callarg));
5438 1.99 pooka SPARG(&callarg, list) = list;
5439 1.99 pooka SPARG(&callarg, nent) = nent;
5440 1.99 pooka SPARG(&callarg, timeout) = timeout;
5441 1.99 pooka
5442 1.120 pgoyette error = rsys_syscall(SYS___aio_suspend50, &callarg, sizeof(callarg), retval);
5443 1.99 pooka rsys_seterrno(error);
5444 1.99 pooka if (error == 0) {
5445 1.99 pooka if (sizeof(int) > sizeof(register_t))
5446 1.99 pooka rv = *(int *)retval;
5447 1.99 pooka else
5448 1.99 pooka rv = *retval;
5449 1.99 pooka }
5450 1.99 pooka return rv;
5451 1.99 pooka }
5452 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5453 1.103 pooka __weak_alias(aio_suspend,rump___sysimpl_aio_suspend50);
5454 1.103 pooka __weak_alias(__aio_suspend50,rump___sysimpl_aio_suspend50);
5455 1.103 pooka __weak_alias(___aio_suspend50,rump___sysimpl_aio_suspend50);
5456 1.103 pooka __strong_alias(_sys___aio_suspend50,rump___sysimpl_aio_suspend50);
5457 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5458 1.99 pooka
5459 1.60 pooka int rump___sysimpl_stat50(const char *, struct stat *);
5460 1.10 pooka int
5461 1.60 pooka rump___sysimpl_stat50(const char * path, struct stat * ub)
5462 1.10 pooka {
5463 1.93 pooka register_t retval[2];
5464 1.27 pooka int error = 0;
5465 1.68 pooka int rv = -1;
5466 1.31 pooka struct sys___stat50_args callarg;
5467 1.10 pooka
5468 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5469 1.31 pooka SPARG(&callarg, path) = path;
5470 1.31 pooka SPARG(&callarg, ub) = ub;
5471 1.10 pooka
5472 1.120 pgoyette error = rsys_syscall(SYS___stat50, &callarg, sizeof(callarg), retval);
5473 1.63 pooka rsys_seterrno(error);
5474 1.68 pooka if (error == 0) {
5475 1.68 pooka if (sizeof(int) > sizeof(register_t))
5476 1.68 pooka rv = *(int *)retval;
5477 1.68 pooka else
5478 1.69 pooka rv = *retval;
5479 1.27 pooka }
5480 1.68 pooka return rv;
5481 1.10 pooka }
5482 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5483 1.103 pooka __weak_alias(stat,rump___sysimpl_stat50);
5484 1.103 pooka __weak_alias(__stat50,rump___sysimpl_stat50);
5485 1.103 pooka __weak_alias(___stat50,rump___sysimpl_stat50);
5486 1.103 pooka __strong_alias(_sys___stat50,rump___sysimpl_stat50);
5487 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5488 1.18 pooka
5489 1.60 pooka int rump___sysimpl_fstat50(int, struct stat *);
5490 1.34 pooka int
5491 1.60 pooka rump___sysimpl_fstat50(int fd, struct stat * sb)
5492 1.34 pooka {
5493 1.93 pooka register_t retval[2];
5494 1.34 pooka int error = 0;
5495 1.68 pooka int rv = -1;
5496 1.34 pooka struct sys___fstat50_args callarg;
5497 1.34 pooka
5498 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5499 1.34 pooka SPARG(&callarg, fd) = fd;
5500 1.34 pooka SPARG(&callarg, sb) = sb;
5501 1.34 pooka
5502 1.120 pgoyette error = rsys_syscall(SYS___fstat50, &callarg, sizeof(callarg), retval);
5503 1.63 pooka rsys_seterrno(error);
5504 1.68 pooka if (error == 0) {
5505 1.68 pooka if (sizeof(int) > sizeof(register_t))
5506 1.68 pooka rv = *(int *)retval;
5507 1.68 pooka else
5508 1.69 pooka rv = *retval;
5509 1.34 pooka }
5510 1.68 pooka return rv;
5511 1.34 pooka }
5512 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5513 1.103 pooka __weak_alias(fstat,rump___sysimpl_fstat50);
5514 1.103 pooka __weak_alias(__fstat50,rump___sysimpl_fstat50);
5515 1.103 pooka __weak_alias(___fstat50,rump___sysimpl_fstat50);
5516 1.103 pooka __strong_alias(_sys___fstat50,rump___sysimpl_fstat50);
5517 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5518 1.34 pooka
5519 1.60 pooka int rump___sysimpl_lstat50(const char *, struct stat *);
5520 1.18 pooka int
5521 1.60 pooka rump___sysimpl_lstat50(const char * path, struct stat * ub)
5522 1.18 pooka {
5523 1.93 pooka register_t retval[2];
5524 1.27 pooka int error = 0;
5525 1.68 pooka int rv = -1;
5526 1.31 pooka struct sys___lstat50_args callarg;
5527 1.18 pooka
5528 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5529 1.31 pooka SPARG(&callarg, path) = path;
5530 1.31 pooka SPARG(&callarg, ub) = ub;
5531 1.18 pooka
5532 1.120 pgoyette error = rsys_syscall(SYS___lstat50, &callarg, sizeof(callarg), retval);
5533 1.63 pooka rsys_seterrno(error);
5534 1.68 pooka if (error == 0) {
5535 1.68 pooka if (sizeof(int) > sizeof(register_t))
5536 1.68 pooka rv = *(int *)retval;
5537 1.68 pooka else
5538 1.69 pooka rv = *retval;
5539 1.27 pooka }
5540 1.68 pooka return rv;
5541 1.18 pooka }
5542 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5543 1.103 pooka __weak_alias(lstat,rump___sysimpl_lstat50);
5544 1.103 pooka __weak_alias(__lstat50,rump___sysimpl_lstat50);
5545 1.103 pooka __weak_alias(___lstat50,rump___sysimpl_lstat50);
5546 1.103 pooka __strong_alias(_sys___lstat50,rump___sysimpl_lstat50);
5547 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5548 1.22 pooka
5549 1.98 pooka int rump___sysimpl_timer_settime50(timer_t, int, const struct itimerspec *, struct itimerspec *);
5550 1.98 pooka int
5551 1.98 pooka rump___sysimpl_timer_settime50(timer_t timerid, int flags, const struct itimerspec * value, struct itimerspec * ovalue)
5552 1.98 pooka {
5553 1.98 pooka register_t retval[2];
5554 1.98 pooka int error = 0;
5555 1.98 pooka int rv = -1;
5556 1.98 pooka struct sys___timer_settime50_args callarg;
5557 1.98 pooka
5558 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5559 1.98 pooka SPARG(&callarg, timerid) = timerid;
5560 1.98 pooka SPARG(&callarg, flags) = flags;
5561 1.98 pooka SPARG(&callarg, value) = value;
5562 1.98 pooka SPARG(&callarg, ovalue) = ovalue;
5563 1.98 pooka
5564 1.120 pgoyette error = rsys_syscall(SYS___timer_settime50, &callarg, sizeof(callarg), retval);
5565 1.98 pooka rsys_seterrno(error);
5566 1.98 pooka if (error == 0) {
5567 1.98 pooka if (sizeof(int) > sizeof(register_t))
5568 1.98 pooka rv = *(int *)retval;
5569 1.98 pooka else
5570 1.98 pooka rv = *retval;
5571 1.98 pooka }
5572 1.98 pooka return rv;
5573 1.98 pooka }
5574 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5575 1.103 pooka __weak_alias(timer_settime,rump___sysimpl_timer_settime50);
5576 1.103 pooka __weak_alias(__timer_settime50,rump___sysimpl_timer_settime50);
5577 1.103 pooka __weak_alias(___timer_settime50,rump___sysimpl_timer_settime50);
5578 1.103 pooka __strong_alias(_sys___timer_settime50,rump___sysimpl_timer_settime50);
5579 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5580 1.98 pooka
5581 1.98 pooka int rump___sysimpl_timer_gettime50(timer_t, struct itimerspec *);
5582 1.98 pooka int
5583 1.98 pooka rump___sysimpl_timer_gettime50(timer_t timerid, struct itimerspec * value)
5584 1.98 pooka {
5585 1.98 pooka register_t retval[2];
5586 1.98 pooka int error = 0;
5587 1.98 pooka int rv = -1;
5588 1.98 pooka struct sys___timer_gettime50_args callarg;
5589 1.98 pooka
5590 1.98 pooka memset(&callarg, 0, sizeof(callarg));
5591 1.98 pooka SPARG(&callarg, timerid) = timerid;
5592 1.98 pooka SPARG(&callarg, value) = value;
5593 1.98 pooka
5594 1.120 pgoyette error = rsys_syscall(SYS___timer_gettime50, &callarg, sizeof(callarg), retval);
5595 1.98 pooka rsys_seterrno(error);
5596 1.98 pooka if (error == 0) {
5597 1.98 pooka if (sizeof(int) > sizeof(register_t))
5598 1.98 pooka rv = *(int *)retval;
5599 1.98 pooka else
5600 1.98 pooka rv = *retval;
5601 1.98 pooka }
5602 1.98 pooka return rv;
5603 1.98 pooka }
5604 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5605 1.103 pooka __weak_alias(timer_gettime,rump___sysimpl_timer_gettime50);
5606 1.103 pooka __weak_alias(__timer_gettime50,rump___sysimpl_timer_gettime50);
5607 1.103 pooka __weak_alias(___timer_gettime50,rump___sysimpl_timer_gettime50);
5608 1.103 pooka __strong_alias(_sys___timer_gettime50,rump___sysimpl_timer_gettime50);
5609 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5610 1.98 pooka
5611 1.60 pooka int rump___sysimpl_mknod50(const char *, mode_t, dev_t);
5612 1.22 pooka int
5613 1.60 pooka rump___sysimpl_mknod50(const char * path, mode_t mode, dev_t dev)
5614 1.22 pooka {
5615 1.93 pooka register_t retval[2];
5616 1.27 pooka int error = 0;
5617 1.68 pooka int rv = -1;
5618 1.31 pooka struct sys___mknod50_args callarg;
5619 1.22 pooka
5620 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5621 1.31 pooka SPARG(&callarg, path) = path;
5622 1.31 pooka SPARG(&callarg, mode) = mode;
5623 1.31 pooka SPARG(&callarg, dev) = dev;
5624 1.22 pooka
5625 1.120 pgoyette error = rsys_syscall(SYS___mknod50, &callarg, sizeof(callarg), retval);
5626 1.63 pooka rsys_seterrno(error);
5627 1.68 pooka if (error == 0) {
5628 1.68 pooka if (sizeof(int) > sizeof(register_t))
5629 1.68 pooka rv = *(int *)retval;
5630 1.68 pooka else
5631 1.69 pooka rv = *retval;
5632 1.27 pooka }
5633 1.68 pooka return rv;
5634 1.22 pooka }
5635 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5636 1.103 pooka __weak_alias(mknod,rump___sysimpl_mknod50);
5637 1.103 pooka __weak_alias(__mknod50,rump___sysimpl_mknod50);
5638 1.103 pooka __weak_alias(___mknod50,rump___sysimpl_mknod50);
5639 1.103 pooka __strong_alias(_sys___mknod50,rump___sysimpl_mknod50);
5640 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5641 1.29 pooka
5642 1.60 pooka int rump___sysimpl_fhstat50(const void *, size_t, struct stat *);
5643 1.34 pooka int
5644 1.60 pooka rump___sysimpl_fhstat50(const void * fhp, size_t fh_size, struct stat * sb)
5645 1.34 pooka {
5646 1.93 pooka register_t retval[2];
5647 1.34 pooka int error = 0;
5648 1.68 pooka int rv = -1;
5649 1.34 pooka struct sys___fhstat50_args callarg;
5650 1.34 pooka
5651 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5652 1.34 pooka SPARG(&callarg, fhp) = fhp;
5653 1.34 pooka SPARG(&callarg, fh_size) = fh_size;
5654 1.34 pooka SPARG(&callarg, sb) = sb;
5655 1.34 pooka
5656 1.120 pgoyette error = rsys_syscall(SYS___fhstat50, &callarg, sizeof(callarg), retval);
5657 1.63 pooka rsys_seterrno(error);
5658 1.68 pooka if (error == 0) {
5659 1.68 pooka if (sizeof(int) > sizeof(register_t))
5660 1.68 pooka rv = *(int *)retval;
5661 1.68 pooka else
5662 1.69 pooka rv = *retval;
5663 1.34 pooka }
5664 1.68 pooka return rv;
5665 1.34 pooka }
5666 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5667 1.103 pooka __weak_alias(fhstat,rump___sysimpl_fhstat50);
5668 1.103 pooka __weak_alias(__fhstat50,rump___sysimpl_fhstat50);
5669 1.103 pooka __weak_alias(___fhstat50,rump___sysimpl_fhstat50);
5670 1.103 pooka __strong_alias(_sys___fhstat50,rump___sysimpl_fhstat50);
5671 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5672 1.34 pooka
5673 1.72 christos int rump___sysimpl_pipe2(int *, int);
5674 1.72 christos int
5675 1.72 christos rump___sysimpl_pipe2(int * fildes, int flags)
5676 1.72 christos {
5677 1.93 pooka register_t retval[2];
5678 1.72 christos int error = 0;
5679 1.72 christos int rv = -1;
5680 1.72 christos struct sys_pipe2_args callarg;
5681 1.72 christos
5682 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5683 1.72 christos SPARG(&callarg, fildes) = fildes;
5684 1.72 christos SPARG(&callarg, flags) = flags;
5685 1.72 christos
5686 1.120 pgoyette error = rsys_syscall(SYS_pipe2, &callarg, sizeof(callarg), retval);
5687 1.72 christos rsys_seterrno(error);
5688 1.72 christos if (error == 0) {
5689 1.72 christos if (sizeof(int) > sizeof(register_t))
5690 1.72 christos rv = *(int *)retval;
5691 1.72 christos else
5692 1.72 christos rv = *retval;
5693 1.72 christos }
5694 1.72 christos return rv;
5695 1.72 christos }
5696 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5697 1.103 pooka __weak_alias(pipe2,rump___sysimpl_pipe2);
5698 1.103 pooka __weak_alias(_pipe2,rump___sysimpl_pipe2);
5699 1.103 pooka __strong_alias(_sys_pipe2,rump___sysimpl_pipe2);
5700 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5701 1.72 christos
5702 1.72 christos int rump___sysimpl_dup3(int, int, int);
5703 1.72 christos int
5704 1.72 christos rump___sysimpl_dup3(int from, int to, int flags)
5705 1.72 christos {
5706 1.93 pooka register_t retval[2];
5707 1.72 christos int error = 0;
5708 1.72 christos int rv = -1;
5709 1.72 christos struct sys_dup3_args callarg;
5710 1.72 christos
5711 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5712 1.72 christos SPARG(&callarg, from) = from;
5713 1.72 christos SPARG(&callarg, to) = to;
5714 1.72 christos SPARG(&callarg, flags) = flags;
5715 1.72 christos
5716 1.120 pgoyette error = rsys_syscall(SYS_dup3, &callarg, sizeof(callarg), retval);
5717 1.72 christos rsys_seterrno(error);
5718 1.72 christos if (error == 0) {
5719 1.72 christos if (sizeof(int) > sizeof(register_t))
5720 1.72 christos rv = *(int *)retval;
5721 1.72 christos else
5722 1.72 christos rv = *retval;
5723 1.72 christos }
5724 1.72 christos return rv;
5725 1.72 christos }
5726 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5727 1.103 pooka __weak_alias(dup3,rump___sysimpl_dup3);
5728 1.103 pooka __weak_alias(_dup3,rump___sysimpl_dup3);
5729 1.103 pooka __strong_alias(_sys_dup3,rump___sysimpl_dup3);
5730 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5731 1.72 christos
5732 1.72 christos int rump___sysimpl_kqueue1(int);
5733 1.72 christos int
5734 1.72 christos rump___sysimpl_kqueue1(int flags)
5735 1.72 christos {
5736 1.93 pooka register_t retval[2];
5737 1.72 christos int error = 0;
5738 1.72 christos int rv = -1;
5739 1.72 christos struct sys_kqueue1_args callarg;
5740 1.72 christos
5741 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5742 1.72 christos SPARG(&callarg, flags) = flags;
5743 1.72 christos
5744 1.120 pgoyette error = rsys_syscall(SYS_kqueue1, &callarg, sizeof(callarg), retval);
5745 1.72 christos rsys_seterrno(error);
5746 1.72 christos if (error == 0) {
5747 1.72 christos if (sizeof(int) > sizeof(register_t))
5748 1.72 christos rv = *(int *)retval;
5749 1.72 christos else
5750 1.72 christos rv = *retval;
5751 1.72 christos }
5752 1.72 christos return rv;
5753 1.72 christos }
5754 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5755 1.103 pooka __weak_alias(kqueue1,rump___sysimpl_kqueue1);
5756 1.103 pooka __weak_alias(_kqueue1,rump___sysimpl_kqueue1);
5757 1.103 pooka __strong_alias(_sys_kqueue1,rump___sysimpl_kqueue1);
5758 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5759 1.72 christos
5760 1.72 christos int rump___sysimpl_paccept(int, struct sockaddr *, socklen_t *, const sigset_t *, int);
5761 1.72 christos int
5762 1.72 christos rump___sysimpl_paccept(int s, struct sockaddr * name, socklen_t * anamelen, const sigset_t * mask, int flags)
5763 1.72 christos {
5764 1.93 pooka register_t retval[2];
5765 1.72 christos int error = 0;
5766 1.72 christos int rv = -1;
5767 1.72 christos struct sys_paccept_args callarg;
5768 1.72 christos
5769 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5770 1.72 christos SPARG(&callarg, s) = s;
5771 1.72 christos SPARG(&callarg, name) = name;
5772 1.72 christos SPARG(&callarg, anamelen) = anamelen;
5773 1.72 christos SPARG(&callarg, mask) = mask;
5774 1.72 christos SPARG(&callarg, flags) = flags;
5775 1.72 christos
5776 1.120 pgoyette error = rsys_syscall(SYS_paccept, &callarg, sizeof(callarg), retval);
5777 1.72 christos rsys_seterrno(error);
5778 1.72 christos if (error == 0) {
5779 1.72 christos if (sizeof(int) > sizeof(register_t))
5780 1.72 christos rv = *(int *)retval;
5781 1.72 christos else
5782 1.72 christos rv = *retval;
5783 1.72 christos }
5784 1.72 christos return rv;
5785 1.72 christos }
5786 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5787 1.103 pooka __weak_alias(paccept,rump___sysimpl_paccept);
5788 1.103 pooka __weak_alias(_paccept,rump___sysimpl_paccept);
5789 1.103 pooka __strong_alias(_sys_paccept,rump___sysimpl_paccept);
5790 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5791 1.72 christos
5792 1.74 manu int rump___sysimpl_linkat(int, const char *, int, const char *, int);
5793 1.74 manu int
5794 1.74 manu rump___sysimpl_linkat(int fd1, const char * name1, int fd2, const char * name2, int flags)
5795 1.74 manu {
5796 1.93 pooka register_t retval[2];
5797 1.74 manu int error = 0;
5798 1.74 manu int rv = -1;
5799 1.74 manu struct sys_linkat_args callarg;
5800 1.74 manu
5801 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5802 1.74 manu SPARG(&callarg, fd1) = fd1;
5803 1.74 manu SPARG(&callarg, name1) = name1;
5804 1.74 manu SPARG(&callarg, fd2) = fd2;
5805 1.74 manu SPARG(&callarg, name2) = name2;
5806 1.74 manu SPARG(&callarg, flags) = flags;
5807 1.74 manu
5808 1.120 pgoyette error = rsys_syscall(SYS_linkat, &callarg, sizeof(callarg), retval);
5809 1.74 manu rsys_seterrno(error);
5810 1.74 manu if (error == 0) {
5811 1.74 manu if (sizeof(int) > sizeof(register_t))
5812 1.74 manu rv = *(int *)retval;
5813 1.74 manu else
5814 1.74 manu rv = *retval;
5815 1.74 manu }
5816 1.74 manu return rv;
5817 1.74 manu }
5818 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5819 1.103 pooka __weak_alias(linkat,rump___sysimpl_linkat);
5820 1.103 pooka __weak_alias(_linkat,rump___sysimpl_linkat);
5821 1.103 pooka __strong_alias(_sys_linkat,rump___sysimpl_linkat);
5822 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5823 1.74 manu
5824 1.74 manu int rump___sysimpl_renameat(int, const char *, int, const char *);
5825 1.74 manu int
5826 1.74 manu rump___sysimpl_renameat(int fromfd, const char * from, int tofd, const char * to)
5827 1.74 manu {
5828 1.93 pooka register_t retval[2];
5829 1.74 manu int error = 0;
5830 1.74 manu int rv = -1;
5831 1.74 manu struct sys_renameat_args callarg;
5832 1.74 manu
5833 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5834 1.74 manu SPARG(&callarg, fromfd) = fromfd;
5835 1.74 manu SPARG(&callarg, from) = from;
5836 1.74 manu SPARG(&callarg, tofd) = tofd;
5837 1.74 manu SPARG(&callarg, to) = to;
5838 1.74 manu
5839 1.120 pgoyette error = rsys_syscall(SYS_renameat, &callarg, sizeof(callarg), retval);
5840 1.74 manu rsys_seterrno(error);
5841 1.74 manu if (error == 0) {
5842 1.74 manu if (sizeof(int) > sizeof(register_t))
5843 1.74 manu rv = *(int *)retval;
5844 1.74 manu else
5845 1.74 manu rv = *retval;
5846 1.74 manu }
5847 1.74 manu return rv;
5848 1.74 manu }
5849 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5850 1.103 pooka __weak_alias(renameat,rump___sysimpl_renameat);
5851 1.103 pooka __weak_alias(_renameat,rump___sysimpl_renameat);
5852 1.103 pooka __strong_alias(_sys_renameat,rump___sysimpl_renameat);
5853 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5854 1.74 manu
5855 1.74 manu int rump___sysimpl_mkfifoat(int, const char *, mode_t);
5856 1.74 manu int
5857 1.74 manu rump___sysimpl_mkfifoat(int fd, const char * path, mode_t mode)
5858 1.74 manu {
5859 1.93 pooka register_t retval[2];
5860 1.74 manu int error = 0;
5861 1.74 manu int rv = -1;
5862 1.74 manu struct sys_mkfifoat_args callarg;
5863 1.74 manu
5864 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5865 1.74 manu SPARG(&callarg, fd) = fd;
5866 1.74 manu SPARG(&callarg, path) = path;
5867 1.74 manu SPARG(&callarg, mode) = mode;
5868 1.74 manu
5869 1.120 pgoyette error = rsys_syscall(SYS_mkfifoat, &callarg, sizeof(callarg), retval);
5870 1.74 manu rsys_seterrno(error);
5871 1.74 manu if (error == 0) {
5872 1.74 manu if (sizeof(int) > sizeof(register_t))
5873 1.74 manu rv = *(int *)retval;
5874 1.74 manu else
5875 1.74 manu rv = *retval;
5876 1.74 manu }
5877 1.74 manu return rv;
5878 1.74 manu }
5879 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5880 1.103 pooka __weak_alias(mkfifoat,rump___sysimpl_mkfifoat);
5881 1.103 pooka __weak_alias(_mkfifoat,rump___sysimpl_mkfifoat);
5882 1.103 pooka __strong_alias(_sys_mkfifoat,rump___sysimpl_mkfifoat);
5883 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5884 1.74 manu
5885 1.92 njoly int rump___sysimpl_mknodat(int, const char *, mode_t, dev_t);
5886 1.74 manu int
5887 1.92 njoly rump___sysimpl_mknodat(int fd, const char * path, mode_t mode, dev_t dev)
5888 1.74 manu {
5889 1.93 pooka register_t retval[2];
5890 1.74 manu int error = 0;
5891 1.74 manu int rv = -1;
5892 1.74 manu struct sys_mknodat_args callarg;
5893 1.74 manu
5894 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5895 1.74 manu SPARG(&callarg, fd) = fd;
5896 1.74 manu SPARG(&callarg, path) = path;
5897 1.74 manu SPARG(&callarg, mode) = mode;
5898 1.92 njoly SPARG(&callarg, PAD) = 0;
5899 1.74 manu SPARG(&callarg, dev) = dev;
5900 1.74 manu
5901 1.120 pgoyette error = rsys_syscall(SYS_mknodat, &callarg, sizeof(callarg), retval);
5902 1.74 manu rsys_seterrno(error);
5903 1.74 manu if (error == 0) {
5904 1.74 manu if (sizeof(int) > sizeof(register_t))
5905 1.74 manu rv = *(int *)retval;
5906 1.74 manu else
5907 1.74 manu rv = *retval;
5908 1.74 manu }
5909 1.74 manu return rv;
5910 1.74 manu }
5911 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5912 1.103 pooka __weak_alias(mknodat,rump___sysimpl_mknodat);
5913 1.103 pooka __weak_alias(_mknodat,rump___sysimpl_mknodat);
5914 1.103 pooka __strong_alias(_sys_mknodat,rump___sysimpl_mknodat);
5915 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5916 1.74 manu
5917 1.74 manu int rump___sysimpl_mkdirat(int, const char *, mode_t);
5918 1.74 manu int
5919 1.74 manu rump___sysimpl_mkdirat(int fd, const char * path, mode_t mode)
5920 1.74 manu {
5921 1.93 pooka register_t retval[2];
5922 1.74 manu int error = 0;
5923 1.74 manu int rv = -1;
5924 1.74 manu struct sys_mkdirat_args callarg;
5925 1.74 manu
5926 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5927 1.74 manu SPARG(&callarg, fd) = fd;
5928 1.74 manu SPARG(&callarg, path) = path;
5929 1.74 manu SPARG(&callarg, mode) = mode;
5930 1.74 manu
5931 1.120 pgoyette error = rsys_syscall(SYS_mkdirat, &callarg, sizeof(callarg), retval);
5932 1.74 manu rsys_seterrno(error);
5933 1.74 manu if (error == 0) {
5934 1.74 manu if (sizeof(int) > sizeof(register_t))
5935 1.74 manu rv = *(int *)retval;
5936 1.74 manu else
5937 1.74 manu rv = *retval;
5938 1.74 manu }
5939 1.74 manu return rv;
5940 1.74 manu }
5941 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5942 1.103 pooka __weak_alias(mkdirat,rump___sysimpl_mkdirat);
5943 1.103 pooka __weak_alias(_mkdirat,rump___sysimpl_mkdirat);
5944 1.103 pooka __strong_alias(_sys_mkdirat,rump___sysimpl_mkdirat);
5945 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5946 1.74 manu
5947 1.74 manu int rump___sysimpl_faccessat(int, const char *, int, int);
5948 1.74 manu int
5949 1.74 manu rump___sysimpl_faccessat(int fd, const char * path, int amode, int flag)
5950 1.74 manu {
5951 1.93 pooka register_t retval[2];
5952 1.74 manu int error = 0;
5953 1.74 manu int rv = -1;
5954 1.74 manu struct sys_faccessat_args callarg;
5955 1.74 manu
5956 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5957 1.74 manu SPARG(&callarg, fd) = fd;
5958 1.74 manu SPARG(&callarg, path) = path;
5959 1.74 manu SPARG(&callarg, amode) = amode;
5960 1.74 manu SPARG(&callarg, flag) = flag;
5961 1.74 manu
5962 1.120 pgoyette error = rsys_syscall(SYS_faccessat, &callarg, sizeof(callarg), retval);
5963 1.74 manu rsys_seterrno(error);
5964 1.74 manu if (error == 0) {
5965 1.74 manu if (sizeof(int) > sizeof(register_t))
5966 1.74 manu rv = *(int *)retval;
5967 1.74 manu else
5968 1.74 manu rv = *retval;
5969 1.74 manu }
5970 1.74 manu return rv;
5971 1.74 manu }
5972 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
5973 1.103 pooka __weak_alias(faccessat,rump___sysimpl_faccessat);
5974 1.103 pooka __weak_alias(_faccessat,rump___sysimpl_faccessat);
5975 1.103 pooka __strong_alias(_sys_faccessat,rump___sysimpl_faccessat);
5976 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
5977 1.74 manu
5978 1.74 manu int rump___sysimpl_fchmodat(int, const char *, mode_t, int);
5979 1.74 manu int
5980 1.74 manu rump___sysimpl_fchmodat(int fd, const char * path, mode_t mode, int flag)
5981 1.74 manu {
5982 1.93 pooka register_t retval[2];
5983 1.74 manu int error = 0;
5984 1.74 manu int rv = -1;
5985 1.74 manu struct sys_fchmodat_args callarg;
5986 1.74 manu
5987 1.95 pooka memset(&callarg, 0, sizeof(callarg));
5988 1.74 manu SPARG(&callarg, fd) = fd;
5989 1.74 manu SPARG(&callarg, path) = path;
5990 1.74 manu SPARG(&callarg, mode) = mode;
5991 1.74 manu SPARG(&callarg, flag) = flag;
5992 1.74 manu
5993 1.120 pgoyette error = rsys_syscall(SYS_fchmodat, &callarg, sizeof(callarg), retval);
5994 1.74 manu rsys_seterrno(error);
5995 1.74 manu if (error == 0) {
5996 1.74 manu if (sizeof(int) > sizeof(register_t))
5997 1.74 manu rv = *(int *)retval;
5998 1.74 manu else
5999 1.74 manu rv = *retval;
6000 1.74 manu }
6001 1.74 manu return rv;
6002 1.74 manu }
6003 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6004 1.103 pooka __weak_alias(fchmodat,rump___sysimpl_fchmodat);
6005 1.103 pooka __weak_alias(_fchmodat,rump___sysimpl_fchmodat);
6006 1.103 pooka __strong_alias(_sys_fchmodat,rump___sysimpl_fchmodat);
6007 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6008 1.74 manu
6009 1.74 manu int rump___sysimpl_fchownat(int, const char *, uid_t, gid_t, int);
6010 1.74 manu int
6011 1.74 manu rump___sysimpl_fchownat(int fd, const char * path, uid_t owner, gid_t group, int flag)
6012 1.74 manu {
6013 1.93 pooka register_t retval[2];
6014 1.74 manu int error = 0;
6015 1.74 manu int rv = -1;
6016 1.74 manu struct sys_fchownat_args callarg;
6017 1.74 manu
6018 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6019 1.74 manu SPARG(&callarg, fd) = fd;
6020 1.74 manu SPARG(&callarg, path) = path;
6021 1.74 manu SPARG(&callarg, owner) = owner;
6022 1.74 manu SPARG(&callarg, group) = group;
6023 1.74 manu SPARG(&callarg, flag) = flag;
6024 1.74 manu
6025 1.120 pgoyette error = rsys_syscall(SYS_fchownat, &callarg, sizeof(callarg), retval);
6026 1.74 manu rsys_seterrno(error);
6027 1.74 manu if (error == 0) {
6028 1.74 manu if (sizeof(int) > sizeof(register_t))
6029 1.74 manu rv = *(int *)retval;
6030 1.74 manu else
6031 1.74 manu rv = *retval;
6032 1.74 manu }
6033 1.74 manu return rv;
6034 1.74 manu }
6035 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6036 1.103 pooka __weak_alias(fchownat,rump___sysimpl_fchownat);
6037 1.103 pooka __weak_alias(_fchownat,rump___sysimpl_fchownat);
6038 1.103 pooka __strong_alias(_sys_fchownat,rump___sysimpl_fchownat);
6039 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6040 1.74 manu
6041 1.74 manu int rump___sysimpl_fstatat(int, const char *, struct stat *, int);
6042 1.74 manu int
6043 1.74 manu rump___sysimpl_fstatat(int fd, const char * path, struct stat * buf, int flag)
6044 1.74 manu {
6045 1.93 pooka register_t retval[2];
6046 1.74 manu int error = 0;
6047 1.74 manu int rv = -1;
6048 1.74 manu struct sys_fstatat_args callarg;
6049 1.74 manu
6050 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6051 1.74 manu SPARG(&callarg, fd) = fd;
6052 1.74 manu SPARG(&callarg, path) = path;
6053 1.74 manu SPARG(&callarg, buf) = buf;
6054 1.74 manu SPARG(&callarg, flag) = flag;
6055 1.74 manu
6056 1.120 pgoyette error = rsys_syscall(SYS_fstatat, &callarg, sizeof(callarg), retval);
6057 1.74 manu rsys_seterrno(error);
6058 1.74 manu if (error == 0) {
6059 1.74 manu if (sizeof(int) > sizeof(register_t))
6060 1.74 manu rv = *(int *)retval;
6061 1.74 manu else
6062 1.74 manu rv = *retval;
6063 1.74 manu }
6064 1.74 manu return rv;
6065 1.74 manu }
6066 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6067 1.103 pooka __weak_alias(fstatat,rump___sysimpl_fstatat);
6068 1.103 pooka __weak_alias(_fstatat,rump___sysimpl_fstatat);
6069 1.103 pooka __strong_alias(_sys_fstatat,rump___sysimpl_fstatat);
6070 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6071 1.74 manu
6072 1.74 manu int rump___sysimpl_utimensat(int, const char *, const struct timespec *, int);
6073 1.74 manu int
6074 1.74 manu rump___sysimpl_utimensat(int fd, const char * path, const struct timespec * tptr, int flag)
6075 1.74 manu {
6076 1.93 pooka register_t retval[2];
6077 1.74 manu int error = 0;
6078 1.74 manu int rv = -1;
6079 1.74 manu struct sys_utimensat_args callarg;
6080 1.74 manu
6081 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6082 1.74 manu SPARG(&callarg, fd) = fd;
6083 1.74 manu SPARG(&callarg, path) = path;
6084 1.74 manu SPARG(&callarg, tptr) = tptr;
6085 1.74 manu SPARG(&callarg, flag) = flag;
6086 1.74 manu
6087 1.120 pgoyette error = rsys_syscall(SYS_utimensat, &callarg, sizeof(callarg), retval);
6088 1.74 manu rsys_seterrno(error);
6089 1.74 manu if (error == 0) {
6090 1.74 manu if (sizeof(int) > sizeof(register_t))
6091 1.74 manu rv = *(int *)retval;
6092 1.74 manu else
6093 1.74 manu rv = *retval;
6094 1.74 manu }
6095 1.74 manu return rv;
6096 1.74 manu }
6097 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6098 1.103 pooka __weak_alias(utimensat,rump___sysimpl_utimensat);
6099 1.103 pooka __weak_alias(_utimensat,rump___sysimpl_utimensat);
6100 1.103 pooka __strong_alias(_sys_utimensat,rump___sysimpl_utimensat);
6101 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6102 1.74 manu
6103 1.74 manu int rump___sysimpl_openat(int, const char *, int, mode_t);
6104 1.74 manu int
6105 1.74 manu rump___sysimpl_openat(int fd, const char * path, int oflags, mode_t mode)
6106 1.74 manu {
6107 1.93 pooka register_t retval[2];
6108 1.74 manu int error = 0;
6109 1.74 manu int rv = -1;
6110 1.74 manu struct sys_openat_args callarg;
6111 1.74 manu
6112 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6113 1.74 manu SPARG(&callarg, fd) = fd;
6114 1.74 manu SPARG(&callarg, path) = path;
6115 1.74 manu SPARG(&callarg, oflags) = oflags;
6116 1.74 manu SPARG(&callarg, mode) = mode;
6117 1.74 manu
6118 1.120 pgoyette error = rsys_syscall(SYS_openat, &callarg, sizeof(callarg), retval);
6119 1.74 manu rsys_seterrno(error);
6120 1.74 manu if (error == 0) {
6121 1.74 manu if (sizeof(int) > sizeof(register_t))
6122 1.74 manu rv = *(int *)retval;
6123 1.74 manu else
6124 1.74 manu rv = *retval;
6125 1.74 manu }
6126 1.74 manu return rv;
6127 1.74 manu }
6128 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6129 1.103 pooka __weak_alias(openat,rump___sysimpl_openat);
6130 1.103 pooka __weak_alias(_openat,rump___sysimpl_openat);
6131 1.103 pooka __strong_alias(_sys_openat,rump___sysimpl_openat);
6132 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6133 1.74 manu
6134 1.105 christos ssize_t rump___sysimpl_readlinkat(int, const char *, char *, size_t);
6135 1.105 christos ssize_t
6136 1.74 manu rump___sysimpl_readlinkat(int fd, const char * path, char * buf, size_t bufsize)
6137 1.74 manu {
6138 1.93 pooka register_t retval[2];
6139 1.74 manu int error = 0;
6140 1.105 christos ssize_t rv = -1;
6141 1.74 manu struct sys_readlinkat_args callarg;
6142 1.74 manu
6143 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6144 1.74 manu SPARG(&callarg, fd) = fd;
6145 1.74 manu SPARG(&callarg, path) = path;
6146 1.74 manu SPARG(&callarg, buf) = buf;
6147 1.74 manu SPARG(&callarg, bufsize) = bufsize;
6148 1.74 manu
6149 1.120 pgoyette error = rsys_syscall(SYS_readlinkat, &callarg, sizeof(callarg), retval);
6150 1.74 manu rsys_seterrno(error);
6151 1.74 manu if (error == 0) {
6152 1.105 christos if (sizeof(ssize_t) > sizeof(register_t))
6153 1.105 christos rv = *(ssize_t *)retval;
6154 1.74 manu else
6155 1.74 manu rv = *retval;
6156 1.74 manu }
6157 1.74 manu return rv;
6158 1.74 manu }
6159 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6160 1.103 pooka __weak_alias(readlinkat,rump___sysimpl_readlinkat);
6161 1.103 pooka __weak_alias(_readlinkat,rump___sysimpl_readlinkat);
6162 1.103 pooka __strong_alias(_sys_readlinkat,rump___sysimpl_readlinkat);
6163 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6164 1.74 manu
6165 1.74 manu int rump___sysimpl_symlinkat(const char *, int, const char *);
6166 1.74 manu int
6167 1.74 manu rump___sysimpl_symlinkat(const char * path1, int fd, const char * path2)
6168 1.74 manu {
6169 1.93 pooka register_t retval[2];
6170 1.74 manu int error = 0;
6171 1.74 manu int rv = -1;
6172 1.74 manu struct sys_symlinkat_args callarg;
6173 1.74 manu
6174 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6175 1.74 manu SPARG(&callarg, path1) = path1;
6176 1.74 manu SPARG(&callarg, fd) = fd;
6177 1.74 manu SPARG(&callarg, path2) = path2;
6178 1.74 manu
6179 1.120 pgoyette error = rsys_syscall(SYS_symlinkat, &callarg, sizeof(callarg), retval);
6180 1.74 manu rsys_seterrno(error);
6181 1.74 manu if (error == 0) {
6182 1.74 manu if (sizeof(int) > sizeof(register_t))
6183 1.74 manu rv = *(int *)retval;
6184 1.74 manu else
6185 1.74 manu rv = *retval;
6186 1.74 manu }
6187 1.74 manu return rv;
6188 1.74 manu }
6189 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6190 1.103 pooka __weak_alias(symlinkat,rump___sysimpl_symlinkat);
6191 1.103 pooka __weak_alias(_symlinkat,rump___sysimpl_symlinkat);
6192 1.103 pooka __strong_alias(_sys_symlinkat,rump___sysimpl_symlinkat);
6193 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6194 1.74 manu
6195 1.74 manu int rump___sysimpl_unlinkat(int, const char *, int);
6196 1.74 manu int
6197 1.74 manu rump___sysimpl_unlinkat(int fd, const char * path, int flag)
6198 1.74 manu {
6199 1.93 pooka register_t retval[2];
6200 1.74 manu int error = 0;
6201 1.74 manu int rv = -1;
6202 1.74 manu struct sys_unlinkat_args callarg;
6203 1.74 manu
6204 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6205 1.74 manu SPARG(&callarg, fd) = fd;
6206 1.74 manu SPARG(&callarg, path) = path;
6207 1.74 manu SPARG(&callarg, flag) = flag;
6208 1.74 manu
6209 1.120 pgoyette error = rsys_syscall(SYS_unlinkat, &callarg, sizeof(callarg), retval);
6210 1.74 manu rsys_seterrno(error);
6211 1.74 manu if (error == 0) {
6212 1.74 manu if (sizeof(int) > sizeof(register_t))
6213 1.74 manu rv = *(int *)retval;
6214 1.74 manu else
6215 1.74 manu rv = *retval;
6216 1.74 manu }
6217 1.74 manu return rv;
6218 1.74 manu }
6219 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6220 1.103 pooka __weak_alias(unlinkat,rump___sysimpl_unlinkat);
6221 1.103 pooka __weak_alias(_unlinkat,rump___sysimpl_unlinkat);
6222 1.103 pooka __strong_alias(_sys_unlinkat,rump___sysimpl_unlinkat);
6223 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6224 1.74 manu
6225 1.75 dholland int rump___sysimpl_futimens(int, const struct timespec *);
6226 1.75 dholland int
6227 1.75 dholland rump___sysimpl_futimens(int fd, const struct timespec * tptr)
6228 1.75 dholland {
6229 1.93 pooka register_t retval[2];
6230 1.75 dholland int error = 0;
6231 1.75 dholland int rv = -1;
6232 1.75 dholland struct sys_futimens_args callarg;
6233 1.75 dholland
6234 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6235 1.75 dholland SPARG(&callarg, fd) = fd;
6236 1.75 dholland SPARG(&callarg, tptr) = tptr;
6237 1.75 dholland
6238 1.120 pgoyette error = rsys_syscall(SYS_futimens, &callarg, sizeof(callarg), retval);
6239 1.75 dholland rsys_seterrno(error);
6240 1.75 dholland if (error == 0) {
6241 1.75 dholland if (sizeof(int) > sizeof(register_t))
6242 1.75 dholland rv = *(int *)retval;
6243 1.75 dholland else
6244 1.75 dholland rv = *retval;
6245 1.75 dholland }
6246 1.75 dholland return rv;
6247 1.75 dholland }
6248 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6249 1.103 pooka __weak_alias(futimens,rump___sysimpl_futimens);
6250 1.103 pooka __weak_alias(_futimens,rump___sysimpl_futimens);
6251 1.103 pooka __strong_alias(_sys_futimens,rump___sysimpl_futimens);
6252 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6253 1.75 dholland
6254 1.75 dholland int rump___sysimpl___quotactl(const char *, struct quotactl_args *);
6255 1.75 dholland int
6256 1.75 dholland rump___sysimpl___quotactl(const char * path, struct quotactl_args * args)
6257 1.75 dholland {
6258 1.93 pooka register_t retval[2];
6259 1.75 dholland int error = 0;
6260 1.75 dholland int rv = -1;
6261 1.75 dholland struct sys___quotactl_args callarg;
6262 1.75 dholland
6263 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6264 1.75 dholland SPARG(&callarg, path) = path;
6265 1.75 dholland SPARG(&callarg, args) = args;
6266 1.75 dholland
6267 1.120 pgoyette error = rsys_syscall(SYS___quotactl, &callarg, sizeof(callarg), retval);
6268 1.75 dholland rsys_seterrno(error);
6269 1.75 dholland if (error == 0) {
6270 1.75 dholland if (sizeof(int) > sizeof(register_t))
6271 1.75 dholland rv = *(int *)retval;
6272 1.75 dholland else
6273 1.75 dholland rv = *retval;
6274 1.75 dholland }
6275 1.75 dholland return rv;
6276 1.75 dholland }
6277 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6278 1.103 pooka __weak_alias(__quotactl,rump___sysimpl___quotactl);
6279 1.103 pooka __weak_alias(___quotactl,rump___sysimpl___quotactl);
6280 1.103 pooka __strong_alias(_sys___quotactl,rump___sysimpl___quotactl);
6281 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6282 1.75 dholland
6283 1.89 pooka int rump___sysimpl_recvmmsg(int, struct mmsghdr *, unsigned int, unsigned int, struct timespec *);
6284 1.89 pooka int
6285 1.89 pooka rump___sysimpl_recvmmsg(int s, struct mmsghdr * mmsg, unsigned int vlen, unsigned int flags, struct timespec * timeout)
6286 1.89 pooka {
6287 1.93 pooka register_t retval[2];
6288 1.89 pooka int error = 0;
6289 1.89 pooka int rv = -1;
6290 1.89 pooka struct sys_recvmmsg_args callarg;
6291 1.89 pooka
6292 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6293 1.89 pooka SPARG(&callarg, s) = s;
6294 1.89 pooka SPARG(&callarg, mmsg) = mmsg;
6295 1.89 pooka SPARG(&callarg, vlen) = vlen;
6296 1.89 pooka SPARG(&callarg, flags) = flags;
6297 1.89 pooka SPARG(&callarg, timeout) = timeout;
6298 1.89 pooka
6299 1.120 pgoyette error = rsys_syscall(SYS_recvmmsg, &callarg, sizeof(callarg), retval);
6300 1.89 pooka rsys_seterrno(error);
6301 1.89 pooka if (error == 0) {
6302 1.89 pooka if (sizeof(int) > sizeof(register_t))
6303 1.89 pooka rv = *(int *)retval;
6304 1.89 pooka else
6305 1.89 pooka rv = *retval;
6306 1.89 pooka }
6307 1.89 pooka return rv;
6308 1.89 pooka }
6309 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6310 1.103 pooka __weak_alias(recvmmsg,rump___sysimpl_recvmmsg);
6311 1.103 pooka __weak_alias(_recvmmsg,rump___sysimpl_recvmmsg);
6312 1.103 pooka __strong_alias(_sys_recvmmsg,rump___sysimpl_recvmmsg);
6313 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6314 1.89 pooka
6315 1.89 pooka int rump___sysimpl_sendmmsg(int, struct mmsghdr *, unsigned int, unsigned int);
6316 1.89 pooka int
6317 1.89 pooka rump___sysimpl_sendmmsg(int s, struct mmsghdr * mmsg, unsigned int vlen, unsigned int flags)
6318 1.89 pooka {
6319 1.93 pooka register_t retval[2];
6320 1.89 pooka int error = 0;
6321 1.89 pooka int rv = -1;
6322 1.89 pooka struct sys_sendmmsg_args callarg;
6323 1.89 pooka
6324 1.95 pooka memset(&callarg, 0, sizeof(callarg));
6325 1.89 pooka SPARG(&callarg, s) = s;
6326 1.89 pooka SPARG(&callarg, mmsg) = mmsg;
6327 1.89 pooka SPARG(&callarg, vlen) = vlen;
6328 1.89 pooka SPARG(&callarg, flags) = flags;
6329 1.89 pooka
6330 1.120 pgoyette error = rsys_syscall(SYS_sendmmsg, &callarg, sizeof(callarg), retval);
6331 1.89 pooka rsys_seterrno(error);
6332 1.89 pooka if (error == 0) {
6333 1.89 pooka if (sizeof(int) > sizeof(register_t))
6334 1.89 pooka rv = *(int *)retval;
6335 1.89 pooka else
6336 1.89 pooka rv = *retval;
6337 1.89 pooka }
6338 1.89 pooka return rv;
6339 1.89 pooka }
6340 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6341 1.103 pooka __weak_alias(sendmmsg,rump___sysimpl_sendmmsg);
6342 1.103 pooka __weak_alias(_sendmmsg,rump___sysimpl_sendmmsg);
6343 1.103 pooka __strong_alias(_sys_sendmmsg,rump___sysimpl_sendmmsg);
6344 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6345 1.89 pooka
6346 1.98 pooka int rump___sysimpl_clock_nanosleep(clockid_t, int, const struct timespec *, struct timespec *);
6347 1.98 pooka int
6348 1.98 pooka rump___sysimpl_clock_nanosleep(clockid_t clock_id, int flags, const struct timespec * rqtp, struct timespec * rmtp)
6349 1.98 pooka {
6350 1.98 pooka register_t retval[2];
6351 1.98 pooka int rv = -1;
6352 1.98 pooka struct sys_clock_nanosleep_args callarg;
6353 1.98 pooka
6354 1.98 pooka memset(&callarg, 0, sizeof(callarg));
6355 1.98 pooka SPARG(&callarg, clock_id) = clock_id;
6356 1.98 pooka SPARG(&callarg, flags) = flags;
6357 1.98 pooka SPARG(&callarg, rqtp) = rqtp;
6358 1.98 pooka SPARG(&callarg, rmtp) = rmtp;
6359 1.98 pooka
6360 1.119 pgoyette (void)rsys_syscall(SYS_clock_nanosleep, &callarg, sizeof(callarg), retval);
6361 1.116 pgoyette if (sizeof(int) > sizeof(register_t))
6362 1.116 pgoyette rv = *(int *)retval;
6363 1.116 pgoyette else
6364 1.116 pgoyette rv = *retval;
6365 1.98 pooka return rv;
6366 1.98 pooka }
6367 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6368 1.103 pooka __weak_alias(clock_nanosleep,rump___sysimpl_clock_nanosleep);
6369 1.103 pooka __weak_alias(_clock_nanosleep,rump___sysimpl_clock_nanosleep);
6370 1.103 pooka __strong_alias(_sys_clock_nanosleep,rump___sysimpl_clock_nanosleep);
6371 1.103 pooka #endif /* RUMP_KERNEL_IS_LIBC */
6372 1.98 pooka
6373 1.104 dholland int rump___sysimpl_posix_fallocate(int, off_t, off_t);
6374 1.104 dholland int
6375 1.104 dholland rump___sysimpl_posix_fallocate(int fd, off_t pos, off_t len)
6376 1.104 dholland {
6377 1.104 dholland register_t retval[2];
6378 1.104 dholland int rv = -1;
6379 1.104 dholland struct sys_posix_fallocate_args callarg;
6380 1.104 dholland
6381 1.104 dholland memset(&callarg, 0, sizeof(callarg));
6382 1.104 dholland SPARG(&callarg, fd) = fd;
6383 1.104 dholland SPARG(&callarg, PAD) = 0;
6384 1.104 dholland SPARG(&callarg, pos) = pos;
6385 1.104 dholland SPARG(&callarg, len) = len;
6386 1.104 dholland
6387 1.119 pgoyette (void)rsys_syscall(SYS_posix_fallocate, &callarg, sizeof(callarg), retval);
6388 1.105 christos if (sizeof(int) > sizeof(register_t))
6389 1.105 christos rv = *(int *)retval;
6390 1.105 christos else
6391 1.105 christos rv = *retval;
6392 1.104 dholland return rv;
6393 1.104 dholland }
6394 1.104 dholland #ifdef RUMP_KERNEL_IS_LIBC
6395 1.104 dholland __weak_alias(posix_fallocate,rump___sysimpl_posix_fallocate);
6396 1.104 dholland __weak_alias(_posix_fallocate,rump___sysimpl_posix_fallocate);
6397 1.104 dholland __strong_alias(_sys_posix_fallocate,rump___sysimpl_posix_fallocate);
6398 1.104 dholland #endif /* RUMP_KERNEL_IS_LIBC */
6399 1.104 dholland
6400 1.104 dholland int rump___sysimpl_fdiscard(int, off_t, off_t);
6401 1.104 dholland int
6402 1.104 dholland rump___sysimpl_fdiscard(int fd, off_t pos, off_t len)
6403 1.104 dholland {
6404 1.104 dholland register_t retval[2];
6405 1.104 dholland int error = 0;
6406 1.104 dholland int rv = -1;
6407 1.104 dholland struct sys_fdiscard_args callarg;
6408 1.104 dholland
6409 1.104 dholland memset(&callarg, 0, sizeof(callarg));
6410 1.104 dholland SPARG(&callarg, fd) = fd;
6411 1.104 dholland SPARG(&callarg, PAD) = 0;
6412 1.104 dholland SPARG(&callarg, pos) = pos;
6413 1.104 dholland SPARG(&callarg, len) = len;
6414 1.104 dholland
6415 1.120 pgoyette error = rsys_syscall(SYS_fdiscard, &callarg, sizeof(callarg), retval);
6416 1.104 dholland rsys_seterrno(error);
6417 1.104 dholland if (error == 0) {
6418 1.104 dholland if (sizeof(int) > sizeof(register_t))
6419 1.104 dholland rv = *(int *)retval;
6420 1.104 dholland else
6421 1.104 dholland rv = *retval;
6422 1.104 dholland }
6423 1.104 dholland return rv;
6424 1.104 dholland }
6425 1.104 dholland #ifdef RUMP_KERNEL_IS_LIBC
6426 1.104 dholland __weak_alias(fdiscard,rump___sysimpl_fdiscard);
6427 1.104 dholland __weak_alias(_fdiscard,rump___sysimpl_fdiscard);
6428 1.104 dholland __strong_alias(_sys_fdiscard,rump___sysimpl_fdiscard);
6429 1.104 dholland #endif /* RUMP_KERNEL_IS_LIBC */
6430 1.104 dholland
6431 1.155 christos int rump___sysimpl_clock_getcpuclockid2(idtype_t, id_t, clockid_t *);
6432 1.155 christos int
6433 1.155 christos rump___sysimpl_clock_getcpuclockid2(idtype_t idtype, id_t id, clockid_t * clock_id)
6434 1.155 christos {
6435 1.155 christos register_t retval[2];
6436 1.155 christos int error = 0;
6437 1.155 christos int rv = -1;
6438 1.155 christos struct sys_clock_getcpuclockid2_args callarg;
6439 1.155 christos
6440 1.155 christos memset(&callarg, 0, sizeof(callarg));
6441 1.155 christos SPARG(&callarg, idtype) = idtype;
6442 1.155 christos SPARG(&callarg, id) = id;
6443 1.155 christos SPARG(&callarg, clock_id) = clock_id;
6444 1.155 christos
6445 1.155 christos error = rsys_syscall(SYS_clock_getcpuclockid2, &callarg, sizeof(callarg), retval);
6446 1.155 christos rsys_seterrno(error);
6447 1.155 christos if (error == 0) {
6448 1.155 christos if (sizeof(int) > sizeof(register_t))
6449 1.155 christos rv = *(int *)retval;
6450 1.155 christos else
6451 1.155 christos rv = *retval;
6452 1.155 christos }
6453 1.155 christos return rv;
6454 1.155 christos }
6455 1.155 christos #ifdef RUMP_KERNEL_IS_LIBC
6456 1.155 christos __weak_alias(clock_getcpuclockid2,rump___sysimpl_clock_getcpuclockid2);
6457 1.155 christos __weak_alias(_clock_getcpuclockid2,rump___sysimpl_clock_getcpuclockid2);
6458 1.155 christos __strong_alias(_sys_clock_getcpuclockid2,rump___sysimpl_clock_getcpuclockid2);
6459 1.155 christos #endif /* RUMP_KERNEL_IS_LIBC */
6460 1.155 christos
6461 1.142 christos int rump___sysimpl_getvfsstat90(struct statvfs *, size_t, int);
6462 1.142 christos int
6463 1.142 christos rump___sysimpl_getvfsstat90(struct statvfs * buf, size_t bufsize, int flags)
6464 1.142 christos {
6465 1.142 christos register_t retval[2];
6466 1.142 christos int error = 0;
6467 1.142 christos int rv = -1;
6468 1.142 christos struct sys___getvfsstat90_args callarg;
6469 1.142 christos
6470 1.142 christos memset(&callarg, 0, sizeof(callarg));
6471 1.142 christos SPARG(&callarg, buf) = buf;
6472 1.142 christos SPARG(&callarg, bufsize) = bufsize;
6473 1.142 christos SPARG(&callarg, flags) = flags;
6474 1.142 christos
6475 1.142 christos error = rsys_syscall(SYS___getvfsstat90, &callarg, sizeof(callarg), retval);
6476 1.142 christos rsys_seterrno(error);
6477 1.142 christos if (error == 0) {
6478 1.142 christos if (sizeof(int) > sizeof(register_t))
6479 1.142 christos rv = *(int *)retval;
6480 1.142 christos else
6481 1.142 christos rv = *retval;
6482 1.142 christos }
6483 1.142 christos return rv;
6484 1.142 christos }
6485 1.142 christos #ifdef RUMP_KERNEL_IS_LIBC
6486 1.142 christos __weak_alias(getvfsstat,rump___sysimpl_getvfsstat90);
6487 1.142 christos __weak_alias(__getvfsstat90,rump___sysimpl_getvfsstat90);
6488 1.142 christos __weak_alias(___getvfsstat90,rump___sysimpl_getvfsstat90);
6489 1.142 christos __strong_alias(_sys___getvfsstat90,rump___sysimpl_getvfsstat90);
6490 1.142 christos #endif /* RUMP_KERNEL_IS_LIBC */
6491 1.142 christos
6492 1.142 christos int rump___sysimpl_statvfs190(const char *, struct statvfs *, int);
6493 1.142 christos int
6494 1.142 christos rump___sysimpl_statvfs190(const char * path, struct statvfs * buf, int flags)
6495 1.142 christos {
6496 1.142 christos register_t retval[2];
6497 1.142 christos int error = 0;
6498 1.142 christos int rv = -1;
6499 1.142 christos struct sys___statvfs190_args callarg;
6500 1.142 christos
6501 1.142 christos memset(&callarg, 0, sizeof(callarg));
6502 1.142 christos SPARG(&callarg, path) = path;
6503 1.142 christos SPARG(&callarg, buf) = buf;
6504 1.142 christos SPARG(&callarg, flags) = flags;
6505 1.142 christos
6506 1.142 christos error = rsys_syscall(SYS___statvfs190, &callarg, sizeof(callarg), retval);
6507 1.142 christos rsys_seterrno(error);
6508 1.142 christos if (error == 0) {
6509 1.142 christos if (sizeof(int) > sizeof(register_t))
6510 1.142 christos rv = *(int *)retval;
6511 1.142 christos else
6512 1.142 christos rv = *retval;
6513 1.142 christos }
6514 1.142 christos return rv;
6515 1.142 christos }
6516 1.142 christos #ifdef RUMP_KERNEL_IS_LIBC
6517 1.142 christos __weak_alias(statvfs1,rump___sysimpl_statvfs190);
6518 1.142 christos __weak_alias(__statvfs190,rump___sysimpl_statvfs190);
6519 1.142 christos __weak_alias(___statvfs190,rump___sysimpl_statvfs190);
6520 1.142 christos __strong_alias(_sys___statvfs190,rump___sysimpl_statvfs190);
6521 1.142 christos #endif /* RUMP_KERNEL_IS_LIBC */
6522 1.142 christos
6523 1.142 christos int rump___sysimpl_fstatvfs190(int, struct statvfs *, int);
6524 1.142 christos int
6525 1.142 christos rump___sysimpl_fstatvfs190(int fd, struct statvfs * buf, int flags)
6526 1.142 christos {
6527 1.142 christos register_t retval[2];
6528 1.142 christos int error = 0;
6529 1.142 christos int rv = -1;
6530 1.142 christos struct sys___fstatvfs190_args callarg;
6531 1.142 christos
6532 1.142 christos memset(&callarg, 0, sizeof(callarg));
6533 1.142 christos SPARG(&callarg, fd) = fd;
6534 1.142 christos SPARG(&callarg, buf) = buf;
6535 1.142 christos SPARG(&callarg, flags) = flags;
6536 1.142 christos
6537 1.142 christos error = rsys_syscall(SYS___fstatvfs190, &callarg, sizeof(callarg), retval);
6538 1.142 christos rsys_seterrno(error);
6539 1.142 christos if (error == 0) {
6540 1.142 christos if (sizeof(int) > sizeof(register_t))
6541 1.142 christos rv = *(int *)retval;
6542 1.142 christos else
6543 1.142 christos rv = *retval;
6544 1.142 christos }
6545 1.142 christos return rv;
6546 1.142 christos }
6547 1.142 christos #ifdef RUMP_KERNEL_IS_LIBC
6548 1.142 christos __weak_alias(fstatvfs1,rump___sysimpl_fstatvfs190);
6549 1.142 christos __weak_alias(__fstatvfs190,rump___sysimpl_fstatvfs190);
6550 1.142 christos __weak_alias(___fstatvfs190,rump___sysimpl_fstatvfs190);
6551 1.142 christos __strong_alias(_sys___fstatvfs190,rump___sysimpl_fstatvfs190);
6552 1.142 christos #endif /* RUMP_KERNEL_IS_LIBC */
6553 1.142 christos
6554 1.142 christos int rump___sysimpl_fhstatvfs190(const void *, size_t, struct statvfs *, int);
6555 1.142 christos int
6556 1.142 christos rump___sysimpl_fhstatvfs190(const void * fhp, size_t fh_size, struct statvfs * buf, int flags)
6557 1.142 christos {
6558 1.142 christos register_t retval[2];
6559 1.142 christos int error = 0;
6560 1.142 christos int rv = -1;
6561 1.142 christos struct sys___fhstatvfs190_args callarg;
6562 1.142 christos
6563 1.142 christos memset(&callarg, 0, sizeof(callarg));
6564 1.142 christos SPARG(&callarg, fhp) = fhp;
6565 1.142 christos SPARG(&callarg, fh_size) = fh_size;
6566 1.142 christos SPARG(&callarg, buf) = buf;
6567 1.142 christos SPARG(&callarg, flags) = flags;
6568 1.142 christos
6569 1.142 christos error = rsys_syscall(SYS___fhstatvfs190, &callarg, sizeof(callarg), retval);
6570 1.142 christos rsys_seterrno(error);
6571 1.142 christos if (error == 0) {
6572 1.142 christos if (sizeof(int) > sizeof(register_t))
6573 1.142 christos rv = *(int *)retval;
6574 1.142 christos else
6575 1.142 christos rv = *retval;
6576 1.142 christos }
6577 1.142 christos return rv;
6578 1.142 christos }
6579 1.142 christos #ifdef RUMP_KERNEL_IS_LIBC
6580 1.142 christos __weak_alias(fhstatvfs1,rump___sysimpl_fhstatvfs190);
6581 1.142 christos __weak_alias(__fhstatvfs190,rump___sysimpl_fhstatvfs190);
6582 1.142 christos __weak_alias(___fhstatvfs190,rump___sysimpl_fhstatvfs190);
6583 1.142 christos __strong_alias(_sys___fhstatvfs190,rump___sysimpl_fhstatvfs190);
6584 1.142 christos #endif /* RUMP_KERNEL_IS_LIBC */
6585 1.142 christos
6586 1.150 christos long rump___sysimpl_lpathconf(const char *, int);
6587 1.150 christos long
6588 1.150 christos rump___sysimpl_lpathconf(const char * path, int name)
6589 1.150 christos {
6590 1.150 christos register_t retval[2];
6591 1.150 christos int error = 0;
6592 1.150 christos long rv = -1;
6593 1.150 christos struct sys_lpathconf_args callarg;
6594 1.150 christos
6595 1.150 christos memset(&callarg, 0, sizeof(callarg));
6596 1.150 christos SPARG(&callarg, path) = path;
6597 1.150 christos SPARG(&callarg, name) = name;
6598 1.150 christos
6599 1.150 christos error = rsys_syscall(SYS_lpathconf, &callarg, sizeof(callarg), retval);
6600 1.150 christos rsys_seterrno(error);
6601 1.150 christos if (error == 0) {
6602 1.150 christos if (sizeof(long) > sizeof(register_t))
6603 1.150 christos rv = *(long *)retval;
6604 1.150 christos else
6605 1.150 christos rv = *retval;
6606 1.150 christos }
6607 1.150 christos return rv;
6608 1.150 christos }
6609 1.150 christos #ifdef RUMP_KERNEL_IS_LIBC
6610 1.150 christos __weak_alias(lpathconf,rump___sysimpl_lpathconf);
6611 1.150 christos __weak_alias(_lpathconf,rump___sysimpl_lpathconf);
6612 1.150 christos __strong_alias(_sys_lpathconf,rump___sysimpl_lpathconf);
6613 1.150 christos #endif /* RUMP_KERNEL_IS_LIBC */
6614 1.150 christos
6615 1.40 pooka int rump_sys_pipe(int *);
6616 1.40 pooka int
6617 1.40 pooka rump_sys_pipe(int *fd)
6618 1.40 pooka {
6619 1.93 pooka register_t retval[2];
6620 1.40 pooka int error = 0;
6621 1.40 pooka
6622 1.68 pooka error = rsys_syscall(SYS_pipe, NULL, 0, retval);
6623 1.40 pooka if (error) {
6624 1.53 pooka rsys_seterrno(error);
6625 1.40 pooka } else {
6626 1.68 pooka fd[0] = retval[0];
6627 1.68 pooka fd[1] = retval[1];
6628 1.40 pooka }
6629 1.40 pooka return error ? -1 : 0;
6630 1.40 pooka }
6631 1.103 pooka #ifdef RUMP_KERNEL_IS_LIBC
6632 1.103 pooka __weak_alias(pipe,rump_sys_pipe);
6633 1.103 pooka __weak_alias(_pipe,rump_sys_pipe);
6634 1.103 pooka __strong_alias(_sys_pipe,rump_sys_pipe);
6635 1.103 pooka #endif
6636 1.40 pooka
6637 1.53 pooka #ifndef RUMP_CLIENT
6638 1.100 pooka int rumpns_enosys(void);
6639 1.29 pooka #define s(type) sizeof(type)
6640 1.29 pooka #define n(type) (sizeof(type)/sizeof (register_t))
6641 1.29 pooka #define ns(type) n(type), s(type)
6642 1.29 pooka
6643 1.29 pooka struct sysent rump_sysent[] = {
6644 1.107 christos {
6645 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6646 1.107 christos }, /* 0 = syscall */
6647 1.107 christos {
6648 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6649 1.107 christos }, /* 1 = exit */
6650 1.107 christos {
6651 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6652 1.107 christos }, /* 2 = fork */
6653 1.107 christos {
6654 1.107 christos ns(struct sys_read_args),
6655 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6656 1.107 christos }, /* 3 = read */
6657 1.107 christos {
6658 1.107 christos ns(struct sys_write_args),
6659 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6660 1.107 christos }, /* 4 = write */
6661 1.107 christos {
6662 1.107 christos ns(struct sys_open_args),
6663 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6664 1.107 christos }, /* 5 = open */
6665 1.107 christos {
6666 1.107 christos ns(struct sys_close_args),
6667 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6668 1.107 christos }, /* 6 = close */
6669 1.107 christos {
6670 1.107 christos .sy_flags = SYCALL_NOSYS,
6671 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6672 1.107 christos }, /* 7 = wait4 */
6673 1.107 christos {
6674 1.107 christos .sy_flags = SYCALL_NOSYS,
6675 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6676 1.107 christos }, /* 8 = ocreat */
6677 1.107 christos {
6678 1.107 christos ns(struct sys_link_args),
6679 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6680 1.107 christos }, /* 9 = link */
6681 1.107 christos {
6682 1.107 christos ns(struct sys_unlink_args),
6683 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6684 1.107 christos }, /* 10 = unlink */
6685 1.107 christos {
6686 1.107 christos .sy_flags = SYCALL_NOSYS,
6687 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6688 1.107 christos }, /* 11 = filler */
6689 1.107 christos {
6690 1.107 christos ns(struct sys_chdir_args),
6691 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6692 1.107 christos }, /* 12 = chdir */
6693 1.107 christos {
6694 1.107 christos ns(struct sys_fchdir_args),
6695 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6696 1.107 christos }, /* 13 = fchdir */
6697 1.107 christos {
6698 1.107 christos ns(struct compat_50_sys_mknod_args),
6699 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6700 1.107 christos }, /* 14 = compat_50_mknod */
6701 1.107 christos {
6702 1.107 christos ns(struct sys_chmod_args),
6703 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6704 1.107 christos }, /* 15 = chmod */
6705 1.107 christos {
6706 1.107 christos ns(struct sys_chown_args),
6707 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6708 1.107 christos }, /* 16 = chown */
6709 1.107 christos {
6710 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6711 1.107 christos }, /* 17 = break */
6712 1.107 christos {
6713 1.107 christos .sy_flags = SYCALL_NOSYS,
6714 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6715 1.107 christos }, /* 18 = getfsstat */
6716 1.107 christos {
6717 1.107 christos .sy_flags = SYCALL_NOSYS,
6718 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6719 1.107 christos }, /* 19 = olseek */
6720 1.107 christos {
6721 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6722 1.107 christos }, /* 20 = getpid */
6723 1.107 christos {
6724 1.107 christos .sy_flags = SYCALL_NOSYS,
6725 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6726 1.107 christos }, /* 21 = mount */
6727 1.107 christos {
6728 1.107 christos ns(struct sys_unmount_args),
6729 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6730 1.107 christos }, /* 22 = unmount */
6731 1.107 christos {
6732 1.107 christos ns(struct sys_setuid_args),
6733 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6734 1.107 christos }, /* 23 = setuid */
6735 1.107 christos {
6736 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6737 1.107 christos }, /* 24 = getuid */
6738 1.107 christos {
6739 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6740 1.107 christos }, /* 25 = geteuid */
6741 1.107 christos {
6742 1.130 pgoyette .sy_flags = SYCALL_NOSYS,
6743 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6744 1.107 christos }, /* 26 = ptrace */
6745 1.107 christos {
6746 1.107 christos ns(struct sys_recvmsg_args),
6747 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6748 1.107 christos }, /* 27 = recvmsg */
6749 1.107 christos {
6750 1.107 christos ns(struct sys_sendmsg_args),
6751 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6752 1.107 christos }, /* 28 = sendmsg */
6753 1.107 christos {
6754 1.107 christos ns(struct sys_recvfrom_args),
6755 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6756 1.107 christos }, /* 29 = recvfrom */
6757 1.107 christos {
6758 1.107 christos ns(struct sys_accept_args),
6759 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6760 1.107 christos }, /* 30 = accept */
6761 1.107 christos {
6762 1.107 christos ns(struct sys_getpeername_args),
6763 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6764 1.107 christos }, /* 31 = getpeername */
6765 1.107 christos {
6766 1.107 christos ns(struct sys_getsockname_args),
6767 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6768 1.107 christos }, /* 32 = getsockname */
6769 1.107 christos {
6770 1.107 christos ns(struct sys_access_args),
6771 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6772 1.107 christos }, /* 33 = access */
6773 1.107 christos {
6774 1.107 christos ns(struct sys_chflags_args),
6775 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6776 1.107 christos }, /* 34 = chflags */
6777 1.107 christos {
6778 1.107 christos ns(struct sys_fchflags_args),
6779 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6780 1.107 christos }, /* 35 = fchflags */
6781 1.107 christos {
6782 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6783 1.107 christos }, /* 36 = sync */
6784 1.107 christos {
6785 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6786 1.107 christos }, /* 37 = kill */
6787 1.107 christos {
6788 1.107 christos .sy_flags = SYCALL_NOSYS,
6789 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6790 1.107 christos }, /* 38 = stat43 */
6791 1.107 christos {
6792 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6793 1.107 christos }, /* 39 = getppid */
6794 1.107 christos {
6795 1.107 christos .sy_flags = SYCALL_NOSYS,
6796 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6797 1.107 christos }, /* 40 = lstat43 */
6798 1.107 christos {
6799 1.107 christos ns(struct sys_dup_args),
6800 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6801 1.107 christos }, /* 41 = dup */
6802 1.107 christos {
6803 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6804 1.107 christos }, /* 42 = pipe */
6805 1.107 christos {
6806 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6807 1.107 christos }, /* 43 = getegid */
6808 1.107 christos {
6809 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6810 1.107 christos }, /* 44 = profil */
6811 1.107 christos {
6812 1.107 christos ns(struct sys_ktrace_args),
6813 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6814 1.107 christos }, /* 45 = ktrace */
6815 1.107 christos {
6816 1.107 christos .sy_flags = SYCALL_NOSYS,
6817 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6818 1.107 christos }, /* 46 = sigaction13 */
6819 1.107 christos {
6820 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6821 1.107 christos }, /* 47 = getgid */
6822 1.107 christos {
6823 1.107 christos .sy_flags = SYCALL_NOSYS,
6824 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6825 1.107 christos }, /* 48 = sigprocmask13 */
6826 1.107 christos {
6827 1.107 christos ns(struct sys___getlogin_args),
6828 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6829 1.107 christos }, /* 49 = __getlogin */
6830 1.107 christos {
6831 1.107 christos ns(struct sys___setlogin_args),
6832 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6833 1.107 christos }, /* 50 = __setlogin */
6834 1.107 christos {
6835 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6836 1.107 christos }, /* 51 = acct */
6837 1.107 christos {
6838 1.107 christos .sy_flags = SYCALL_NOSYS,
6839 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6840 1.107 christos }, /* 52 = sigpending13 */
6841 1.107 christos {
6842 1.107 christos .sy_flags = SYCALL_NOSYS,
6843 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6844 1.107 christos }, /* 53 = sigaltstack13 */
6845 1.107 christos {
6846 1.107 christos ns(struct sys_ioctl_args),
6847 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6848 1.107 christos }, /* 54 = ioctl */
6849 1.107 christos {
6850 1.107 christos .sy_flags = SYCALL_NOSYS,
6851 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6852 1.107 christos }, /* 55 = oreboot */
6853 1.107 christos {
6854 1.107 christos ns(struct sys_revoke_args),
6855 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6856 1.107 christos }, /* 56 = revoke */
6857 1.107 christos {
6858 1.107 christos ns(struct sys_symlink_args),
6859 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6860 1.107 christos }, /* 57 = symlink */
6861 1.107 christos {
6862 1.107 christos ns(struct sys_readlink_args),
6863 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6864 1.107 christos }, /* 58 = readlink */
6865 1.107 christos {
6866 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6867 1.107 christos }, /* 59 = execve */
6868 1.107 christos {
6869 1.107 christos ns(struct sys_umask_args),
6870 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6871 1.107 christos }, /* 60 = umask */
6872 1.107 christos {
6873 1.107 christos ns(struct sys_chroot_args),
6874 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6875 1.107 christos }, /* 61 = chroot */
6876 1.107 christos {
6877 1.107 christos .sy_flags = SYCALL_NOSYS,
6878 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6879 1.107 christos }, /* 62 = fstat43 */
6880 1.107 christos {
6881 1.107 christos .sy_flags = SYCALL_NOSYS,
6882 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6883 1.107 christos }, /* 63 = ogetkerninfo */
6884 1.107 christos {
6885 1.107 christos .sy_flags = SYCALL_NOSYS,
6886 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6887 1.107 christos }, /* 64 = ogetpagesize */
6888 1.107 christos {
6889 1.107 christos .sy_flags = SYCALL_NOSYS,
6890 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6891 1.107 christos }, /* 65 = msync */
6892 1.107 christos {
6893 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6894 1.107 christos }, /* 66 = vfork */
6895 1.107 christos {
6896 1.107 christos .sy_flags = SYCALL_NOSYS,
6897 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6898 1.107 christos }, /* 67 = filler */
6899 1.107 christos {
6900 1.107 christos .sy_flags = SYCALL_NOSYS,
6901 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6902 1.107 christos }, /* 68 = filler */
6903 1.107 christos {
6904 1.135 kamil .sy_flags = SYCALL_NOSYS,
6905 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6906 1.135 kamil }, /* 69 = filler */
6907 1.107 christos {
6908 1.134 kamil .sy_flags = SYCALL_NOSYS,
6909 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6910 1.134 kamil }, /* 70 = filler */
6911 1.107 christos {
6912 1.107 christos .sy_flags = SYCALL_NOSYS,
6913 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6914 1.107 christos }, /* 71 = ommap */
6915 1.107 christos {
6916 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6917 1.137 kamil }, /* 72 = vadvise */
6918 1.107 christos {
6919 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6920 1.107 christos }, /* 73 = munmap */
6921 1.107 christos {
6922 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6923 1.107 christos }, /* 74 = mprotect */
6924 1.107 christos {
6925 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6926 1.107 christos }, /* 75 = madvise */
6927 1.107 christos {
6928 1.107 christos .sy_flags = SYCALL_NOSYS,
6929 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6930 1.107 christos }, /* 76 = filler */
6931 1.107 christos {
6932 1.107 christos .sy_flags = SYCALL_NOSYS,
6933 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6934 1.107 christos }, /* 77 = filler */
6935 1.107 christos {
6936 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6937 1.107 christos }, /* 78 = mincore */
6938 1.107 christos {
6939 1.107 christos ns(struct sys_getgroups_args),
6940 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6941 1.107 christos }, /* 79 = getgroups */
6942 1.107 christos {
6943 1.107 christos ns(struct sys_setgroups_args),
6944 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6945 1.107 christos }, /* 80 = setgroups */
6946 1.107 christos {
6947 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6948 1.107 christos }, /* 81 = getpgrp */
6949 1.107 christos {
6950 1.107 christos ns(struct sys_setpgid_args),
6951 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6952 1.107 christos }, /* 82 = setpgid */
6953 1.107 christos {
6954 1.107 christos .sy_flags = SYCALL_NOSYS,
6955 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6956 1.107 christos }, /* 83 = setitimer */
6957 1.107 christos {
6958 1.107 christos .sy_flags = SYCALL_NOSYS,
6959 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6960 1.107 christos }, /* 84 = owait */
6961 1.107 christos {
6962 1.107 christos .sy_flags = SYCALL_NOSYS,
6963 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6964 1.107 christos }, /* 85 = oswapon */
6965 1.107 christos {
6966 1.107 christos .sy_flags = SYCALL_NOSYS,
6967 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6968 1.107 christos }, /* 86 = getitimer */
6969 1.107 christos {
6970 1.107 christos .sy_flags = SYCALL_NOSYS,
6971 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6972 1.107 christos }, /* 87 = ogethostname */
6973 1.107 christos {
6974 1.107 christos .sy_flags = SYCALL_NOSYS,
6975 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6976 1.107 christos }, /* 88 = osethostname */
6977 1.107 christos {
6978 1.107 christos .sy_flags = SYCALL_NOSYS,
6979 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6980 1.107 christos }, /* 89 = ogetdtablesize */
6981 1.107 christos {
6982 1.107 christos ns(struct sys_dup2_args),
6983 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6984 1.107 christos }, /* 90 = dup2 */
6985 1.107 christos {
6986 1.154 riastrad ns(struct sys_getrandom_args),
6987 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6988 1.154 riastrad }, /* 91 = getrandom */
6989 1.107 christos {
6990 1.107 christos ns(struct sys_fcntl_args),
6991 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
6992 1.107 christos }, /* 92 = fcntl */
6993 1.107 christos {
6994 1.107 christos ns(struct compat_50_sys_select_args),
6995 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
6996 1.107 christos }, /* 93 = compat_50_select */
6997 1.107 christos {
6998 1.107 christos .sy_flags = SYCALL_NOSYS,
6999 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7000 1.107 christos }, /* 94 = filler */
7001 1.107 christos {
7002 1.107 christos ns(struct sys_fsync_args),
7003 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7004 1.107 christos }, /* 95 = fsync */
7005 1.107 christos {
7006 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7007 1.107 christos }, /* 96 = setpriority */
7008 1.107 christos {
7009 1.107 christos .sy_flags = SYCALL_NOSYS,
7010 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7011 1.107 christos }, /* 97 = socket */
7012 1.107 christos {
7013 1.107 christos ns(struct sys_connect_args),
7014 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7015 1.107 christos }, /* 98 = connect */
7016 1.107 christos {
7017 1.107 christos .sy_flags = SYCALL_NOSYS,
7018 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7019 1.107 christos }, /* 99 = oaccept */
7020 1.107 christos {
7021 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7022 1.107 christos }, /* 100 = getpriority */
7023 1.107 christos {
7024 1.107 christos .sy_flags = SYCALL_NOSYS,
7025 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7026 1.107 christos }, /* 101 = osend */
7027 1.107 christos {
7028 1.107 christos .sy_flags = SYCALL_NOSYS,
7029 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7030 1.107 christos }, /* 102 = orecv */
7031 1.107 christos {
7032 1.107 christos .sy_flags = SYCALL_NOSYS,
7033 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7034 1.107 christos }, /* 103 = sigreturn13 */
7035 1.107 christos {
7036 1.107 christos ns(struct sys_bind_args),
7037 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7038 1.107 christos }, /* 104 = bind */
7039 1.107 christos {
7040 1.107 christos ns(struct sys_setsockopt_args),
7041 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7042 1.107 christos }, /* 105 = setsockopt */
7043 1.107 christos {
7044 1.107 christos ns(struct sys_listen_args),
7045 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7046 1.107 christos }, /* 106 = listen */
7047 1.107 christos {
7048 1.107 christos .sy_flags = SYCALL_NOSYS,
7049 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7050 1.107 christos }, /* 107 = filler */
7051 1.107 christos {
7052 1.107 christos .sy_flags = SYCALL_NOSYS,
7053 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7054 1.107 christos }, /* 108 = osigvec */
7055 1.107 christos {
7056 1.107 christos .sy_flags = SYCALL_NOSYS,
7057 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7058 1.107 christos }, /* 109 = osigblock */
7059 1.107 christos {
7060 1.107 christos .sy_flags = SYCALL_NOSYS,
7061 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7062 1.107 christos }, /* 110 = osigsetmask */
7063 1.107 christos {
7064 1.107 christos .sy_flags = SYCALL_NOSYS,
7065 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7066 1.107 christos }, /* 111 = sigsuspend13 */
7067 1.107 christos {
7068 1.107 christos .sy_flags = SYCALL_NOSYS,
7069 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7070 1.107 christos }, /* 112 = osigstack */
7071 1.107 christos {
7072 1.107 christos .sy_flags = SYCALL_NOSYS,
7073 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7074 1.107 christos }, /* 113 = orecvmsg */
7075 1.107 christos {
7076 1.107 christos .sy_flags = SYCALL_NOSYS,
7077 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7078 1.107 christos }, /* 114 = osendmsg */
7079 1.107 christos {
7080 1.107 christos .sy_flags = SYCALL_NOSYS,
7081 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7082 1.107 christos }, /* 115 = filler */
7083 1.107 christos {
7084 1.107 christos .sy_flags = SYCALL_NOSYS,
7085 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7086 1.107 christos }, /* 116 = gettimeofday */
7087 1.107 christos {
7088 1.107 christos .sy_flags = SYCALL_NOSYS,
7089 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7090 1.107 christos }, /* 117 = getrusage */
7091 1.107 christos {
7092 1.107 christos ns(struct sys_getsockopt_args),
7093 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7094 1.107 christos }, /* 118 = getsockopt */
7095 1.107 christos {
7096 1.107 christos .sy_flags = SYCALL_NOSYS,
7097 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7098 1.107 christos }, /* 119 = filler */
7099 1.107 christos {
7100 1.107 christos ns(struct sys_readv_args),
7101 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7102 1.107 christos }, /* 120 = readv */
7103 1.107 christos {
7104 1.107 christos ns(struct sys_writev_args),
7105 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7106 1.107 christos }, /* 121 = writev */
7107 1.107 christos {
7108 1.107 christos .sy_flags = SYCALL_NOSYS,
7109 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7110 1.107 christos }, /* 122 = settimeofday */
7111 1.107 christos {
7112 1.107 christos ns(struct sys_fchown_args),
7113 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7114 1.107 christos }, /* 123 = fchown */
7115 1.107 christos {
7116 1.107 christos ns(struct sys_fchmod_args),
7117 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7118 1.107 christos }, /* 124 = fchmod */
7119 1.107 christos {
7120 1.107 christos .sy_flags = SYCALL_NOSYS,
7121 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7122 1.107 christos }, /* 125 = orecvfrom */
7123 1.107 christos {
7124 1.107 christos ns(struct sys_setreuid_args),
7125 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7126 1.107 christos }, /* 126 = setreuid */
7127 1.107 christos {
7128 1.107 christos ns(struct sys_setregid_args),
7129 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7130 1.107 christos }, /* 127 = setregid */
7131 1.107 christos {
7132 1.107 christos ns(struct sys_rename_args),
7133 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7134 1.107 christos }, /* 128 = rename */
7135 1.107 christos {
7136 1.107 christos .sy_flags = SYCALL_NOSYS,
7137 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7138 1.107 christos }, /* 129 = otruncate */
7139 1.107 christos {
7140 1.107 christos .sy_flags = SYCALL_NOSYS,
7141 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7142 1.107 christos }, /* 130 = oftruncate */
7143 1.107 christos {
7144 1.107 christos ns(struct sys_flock_args),
7145 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7146 1.107 christos }, /* 131 = flock */
7147 1.107 christos {
7148 1.107 christos ns(struct sys_mkfifo_args),
7149 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7150 1.107 christos }, /* 132 = mkfifo */
7151 1.107 christos {
7152 1.107 christos ns(struct sys_sendto_args),
7153 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7154 1.107 christos }, /* 133 = sendto */
7155 1.107 christos {
7156 1.107 christos ns(struct sys_shutdown_args),
7157 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7158 1.107 christos }, /* 134 = shutdown */
7159 1.107 christos {
7160 1.107 christos ns(struct sys_socketpair_args),
7161 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7162 1.107 christos }, /* 135 = socketpair */
7163 1.107 christos {
7164 1.107 christos ns(struct sys_mkdir_args),
7165 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7166 1.107 christos }, /* 136 = mkdir */
7167 1.107 christos {
7168 1.107 christos ns(struct sys_rmdir_args),
7169 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7170 1.107 christos }, /* 137 = rmdir */
7171 1.107 christos {
7172 1.107 christos ns(struct compat_50_sys_utimes_args),
7173 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7174 1.107 christos }, /* 138 = compat_50_utimes */
7175 1.107 christos {
7176 1.107 christos .sy_flags = SYCALL_NOSYS,
7177 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7178 1.107 christos }, /* 139 = filler */
7179 1.107 christos {
7180 1.107 christos .sy_flags = SYCALL_NOSYS,
7181 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7182 1.107 christos }, /* 140 = adjtime */
7183 1.107 christos {
7184 1.107 christos .sy_flags = SYCALL_NOSYS,
7185 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7186 1.107 christos }, /* 141 = ogetpeername */
7187 1.107 christos {
7188 1.107 christos .sy_flags = SYCALL_NOSYS,
7189 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7190 1.107 christos }, /* 142 = ogethostid */
7191 1.107 christos {
7192 1.107 christos .sy_flags = SYCALL_NOSYS,
7193 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7194 1.107 christos }, /* 143 = osethostid */
7195 1.107 christos {
7196 1.107 christos .sy_flags = SYCALL_NOSYS,
7197 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7198 1.107 christos }, /* 144 = ogetrlimit */
7199 1.107 christos {
7200 1.107 christos .sy_flags = SYCALL_NOSYS,
7201 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7202 1.107 christos }, /* 145 = osetrlimit */
7203 1.107 christos {
7204 1.107 christos .sy_flags = SYCALL_NOSYS,
7205 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7206 1.107 christos }, /* 146 = okillpg */
7207 1.107 christos {
7208 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7209 1.107 christos }, /* 147 = setsid */
7210 1.107 christos {
7211 1.107 christos .sy_flags = SYCALL_NOSYS,
7212 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7213 1.107 christos }, /* 148 = quotactl */
7214 1.107 christos {
7215 1.107 christos .sy_flags = SYCALL_NOSYS,
7216 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7217 1.107 christos }, /* 149 = oquota */
7218 1.107 christos {
7219 1.107 christos .sy_flags = SYCALL_NOSYS,
7220 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7221 1.107 christos }, /* 150 = ogetsockname */
7222 1.107 christos {
7223 1.107 christos .sy_flags = SYCALL_NOSYS,
7224 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7225 1.107 christos }, /* 151 = filler */
7226 1.107 christos {
7227 1.107 christos .sy_flags = SYCALL_NOSYS,
7228 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7229 1.107 christos }, /* 152 = filler */
7230 1.107 christos {
7231 1.107 christos .sy_flags = SYCALL_NOSYS,
7232 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7233 1.107 christos }, /* 153 = filler */
7234 1.107 christos {
7235 1.107 christos .sy_flags = SYCALL_NOSYS,
7236 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7237 1.107 christos }, /* 154 = filler */
7238 1.107 christos {
7239 1.107 christos ns(struct sys_nfssvc_args),
7240 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7241 1.107 christos }, /* 155 = nfssvc */
7242 1.107 christos {
7243 1.107 christos .sy_flags = SYCALL_NOSYS,
7244 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7245 1.107 christos }, /* 156 = ogetdirentries */
7246 1.107 christos {
7247 1.107 christos .sy_flags = SYCALL_NOSYS,
7248 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7249 1.107 christos }, /* 157 = statfs */
7250 1.107 christos {
7251 1.107 christos .sy_flags = SYCALL_NOSYS,
7252 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7253 1.107 christos }, /* 158 = fstatfs */
7254 1.107 christos {
7255 1.107 christos .sy_flags = SYCALL_NOSYS,
7256 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7257 1.107 christos }, /* 159 = filler */
7258 1.107 christos {
7259 1.107 christos .sy_flags = SYCALL_NOSYS,
7260 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7261 1.107 christos }, /* 160 = filler */
7262 1.107 christos {
7263 1.107 christos .sy_flags = SYCALL_NOSYS,
7264 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7265 1.107 christos }, /* 161 = getfh */
7266 1.107 christos {
7267 1.107 christos .sy_flags = SYCALL_NOSYS,
7268 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7269 1.107 christos }, /* 162 = ogetdomainname */
7270 1.107 christos {
7271 1.107 christos .sy_flags = SYCALL_NOSYS,
7272 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7273 1.107 christos }, /* 163 = osetdomainname */
7274 1.107 christos {
7275 1.107 christos .sy_flags = SYCALL_NOSYS,
7276 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7277 1.107 christos }, /* 164 = ouname */
7278 1.107 christos {
7279 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7280 1.107 christos }, /* 165 = sysarch */
7281 1.107 christos {
7282 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7283 1.149 thorpej }, /* 166 = __futex */
7284 1.107 christos {
7285 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7286 1.149 thorpej }, /* 167 = __futex_set_robust_list */
7287 1.107 christos {
7288 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7289 1.149 thorpej }, /* 168 = __futex_get_robust_list */
7290 1.112 pgoyette #if !defined(_LP64)
7291 1.107 christos {
7292 1.107 christos .sy_flags = SYCALL_NOSYS,
7293 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7294 1.107 christos }, /* 169 = osemsys */
7295 1.29 pooka #else
7296 1.107 christos {
7297 1.107 christos .sy_flags = SYCALL_NOSYS,
7298 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7299 1.107 christos }, /* 169 = filler */
7300 1.29 pooka #endif
7301 1.112 pgoyette #if !defined(_LP64)
7302 1.107 christos {
7303 1.107 christos .sy_flags = SYCALL_NOSYS,
7304 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7305 1.107 christos }, /* 170 = omsgsys */
7306 1.29 pooka #else
7307 1.107 christos {
7308 1.107 christos .sy_flags = SYCALL_NOSYS,
7309 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7310 1.107 christos }, /* 170 = filler */
7311 1.29 pooka #endif
7312 1.112 pgoyette #if !defined(_LP64)
7313 1.107 christos {
7314 1.107 christos .sy_flags = SYCALL_NOSYS,
7315 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7316 1.107 christos }, /* 171 = oshmsys */
7317 1.29 pooka #else
7318 1.107 christos {
7319 1.107 christos .sy_flags = SYCALL_NOSYS,
7320 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7321 1.107 christos }, /* 171 = filler */
7322 1.29 pooka #endif
7323 1.107 christos {
7324 1.107 christos .sy_flags = SYCALL_NOSYS,
7325 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7326 1.107 christos }, /* 172 = filler */
7327 1.107 christos {
7328 1.107 christos ns(struct sys_pread_args),
7329 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7330 1.107 christos }, /* 173 = pread */
7331 1.107 christos {
7332 1.107 christos ns(struct sys_pwrite_args),
7333 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7334 1.107 christos }, /* 174 = pwrite */
7335 1.107 christos {
7336 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7337 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7338 1.107 christos }, /* 175 = ntp_gettime */
7339 1.29 pooka #if defined(NTP) || !defined(_KERNEL_OPT)
7340 1.107 christos {
7341 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7342 1.107 christos }, /* 176 = ntp_adjtime */
7343 1.29 pooka #else
7344 1.107 christos {
7345 1.107 christos .sy_flags = SYCALL_NOSYS,
7346 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7347 1.107 christos }, /* 176 = filler */
7348 1.29 pooka #endif
7349 1.107 christos {
7350 1.107 christos .sy_flags = SYCALL_NOSYS,
7351 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7352 1.107 christos }, /* 177 = filler */
7353 1.107 christos {
7354 1.107 christos .sy_flags = SYCALL_NOSYS,
7355 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7356 1.107 christos }, /* 178 = filler */
7357 1.107 christos {
7358 1.107 christos .sy_flags = SYCALL_NOSYS,
7359 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7360 1.107 christos }, /* 179 = filler */
7361 1.107 christos {
7362 1.107 christos .sy_flags = SYCALL_NOSYS,
7363 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7364 1.107 christos }, /* 180 = filler */
7365 1.107 christos {
7366 1.107 christos ns(struct sys_setgid_args),
7367 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7368 1.107 christos }, /* 181 = setgid */
7369 1.107 christos {
7370 1.107 christos ns(struct sys_setegid_args),
7371 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7372 1.107 christos }, /* 182 = setegid */
7373 1.107 christos {
7374 1.107 christos ns(struct sys_seteuid_args),
7375 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7376 1.107 christos }, /* 183 = seteuid */
7377 1.107 christos {
7378 1.107 christos .sy_flags = SYCALL_NOSYS,
7379 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7380 1.107 christos }, /* 184 = lfs_bmapv */
7381 1.107 christos {
7382 1.107 christos .sy_flags = SYCALL_NOSYS,
7383 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7384 1.107 christos }, /* 185 = lfs_markv */
7385 1.107 christos {
7386 1.107 christos .sy_flags = SYCALL_NOSYS,
7387 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7388 1.107 christos }, /* 186 = lfs_segclean */
7389 1.107 christos {
7390 1.107 christos .sy_flags = SYCALL_NOSYS,
7391 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7392 1.107 christos }, /* 187 = lfs_segwait */
7393 1.107 christos {
7394 1.107 christos .sy_flags = SYCALL_NOSYS,
7395 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7396 1.107 christos }, /* 188 = stat12 */
7397 1.107 christos {
7398 1.107 christos .sy_flags = SYCALL_NOSYS,
7399 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7400 1.107 christos }, /* 189 = fstat12 */
7401 1.107 christos {
7402 1.107 christos .sy_flags = SYCALL_NOSYS,
7403 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7404 1.107 christos }, /* 190 = lstat12 */
7405 1.107 christos {
7406 1.107 christos ns(struct sys_pathconf_args),
7407 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7408 1.107 christos }, /* 191 = pathconf */
7409 1.107 christos {
7410 1.107 christos ns(struct sys_fpathconf_args),
7411 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7412 1.107 christos }, /* 192 = fpathconf */
7413 1.107 christos {
7414 1.139 rjs ns(struct sys_getsockopt2_args),
7415 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7416 1.139 rjs }, /* 193 = getsockopt2 */
7417 1.107 christos {
7418 1.107 christos ns(struct sys_getrlimit_args),
7419 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7420 1.107 christos }, /* 194 = getrlimit */
7421 1.107 christos {
7422 1.107 christos ns(struct sys_setrlimit_args),
7423 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7424 1.107 christos }, /* 195 = setrlimit */
7425 1.107 christos {
7426 1.107 christos .sy_flags = SYCALL_NOSYS,
7427 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7428 1.107 christos }, /* 196 = getdirentries */
7429 1.107 christos {
7430 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7431 1.107 christos }, /* 197 = mmap */
7432 1.107 christos {
7433 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7434 1.107 christos }, /* 198 = __syscall */
7435 1.107 christos {
7436 1.107 christos ns(struct sys_lseek_args),
7437 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7438 1.107 christos }, /* 199 = lseek */
7439 1.107 christos {
7440 1.107 christos ns(struct sys_truncate_args),
7441 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7442 1.107 christos }, /* 200 = truncate */
7443 1.107 christos {
7444 1.107 christos ns(struct sys_ftruncate_args),
7445 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7446 1.107 christos }, /* 201 = ftruncate */
7447 1.107 christos {
7448 1.107 christos ns(struct sys___sysctl_args),
7449 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7450 1.107 christos }, /* 202 = __sysctl */
7451 1.107 christos {
7452 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7453 1.107 christos }, /* 203 = mlock */
7454 1.107 christos {
7455 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7456 1.107 christos }, /* 204 = munlock */
7457 1.107 christos {
7458 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7459 1.107 christos }, /* 205 = undelete */
7460 1.107 christos {
7461 1.107 christos ns(struct compat_50_sys_futimes_args),
7462 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7463 1.107 christos }, /* 206 = compat_50_futimes */
7464 1.107 christos {
7465 1.107 christos ns(struct sys_getpgid_args),
7466 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7467 1.107 christos }, /* 207 = getpgid */
7468 1.107 christos {
7469 1.107 christos ns(struct sys_reboot_args),
7470 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7471 1.107 christos }, /* 208 = reboot */
7472 1.107 christos {
7473 1.107 christos ns(struct sys_poll_args),
7474 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7475 1.107 christos }, /* 209 = poll */
7476 1.107 christos {
7477 1.107 christos .sy_flags = SYCALL_NOSYS,
7478 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7479 1.107 christos }, /* 210 = afssys */
7480 1.107 christos {
7481 1.107 christos .sy_flags = SYCALL_NOSYS,
7482 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7483 1.107 christos }, /* 211 = filler */
7484 1.107 christos {
7485 1.107 christos .sy_flags = SYCALL_NOSYS,
7486 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7487 1.107 christos }, /* 212 = filler */
7488 1.107 christos {
7489 1.107 christos .sy_flags = SYCALL_NOSYS,
7490 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7491 1.107 christos }, /* 213 = filler */
7492 1.107 christos {
7493 1.107 christos .sy_flags = SYCALL_NOSYS,
7494 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7495 1.107 christos }, /* 214 = filler */
7496 1.107 christos {
7497 1.107 christos .sy_flags = SYCALL_NOSYS,
7498 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7499 1.107 christos }, /* 215 = filler */
7500 1.107 christos {
7501 1.107 christos .sy_flags = SYCALL_NOSYS,
7502 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7503 1.107 christos }, /* 216 = filler */
7504 1.107 christos {
7505 1.107 christos .sy_flags = SYCALL_NOSYS,
7506 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7507 1.107 christos }, /* 217 = filler */
7508 1.107 christos {
7509 1.107 christos .sy_flags = SYCALL_NOSYS,
7510 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7511 1.107 christos }, /* 218 = filler */
7512 1.107 christos {
7513 1.107 christos .sy_flags = SYCALL_NOSYS,
7514 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7515 1.107 christos }, /* 219 = filler */
7516 1.107 christos {
7517 1.107 christos .sy_flags = SYCALL_NOSYS,
7518 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7519 1.107 christos }, /* 220 = __semctl */
7520 1.107 christos {
7521 1.112 pgoyette .sy_flags = SYCALL_NOSYS,
7522 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7523 1.107 christos }, /* 221 = semget */
7524 1.107 christos {
7525 1.112 pgoyette .sy_flags = SYCALL_NOSYS,
7526 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7527 1.107 christos }, /* 222 = semop */
7528 1.107 christos {
7529 1.112 pgoyette .sy_flags = SYCALL_NOSYS,
7530 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7531 1.107 christos }, /* 223 = semconfig */
7532 1.107 christos {
7533 1.107 christos .sy_flags = SYCALL_NOSYS,
7534 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7535 1.112 pgoyette }, /* 224 = msgctl */
7536 1.107 christos {
7537 1.107 christos .sy_flags = SYCALL_NOSYS,
7538 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7539 1.112 pgoyette }, /* 225 = msgget */
7540 1.107 christos {
7541 1.107 christos .sy_flags = SYCALL_NOSYS,
7542 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7543 1.112 pgoyette }, /* 226 = msgsnd */
7544 1.107 christos {
7545 1.107 christos .sy_flags = SYCALL_NOSYS,
7546 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7547 1.107 christos }, /* 227 = msgrcv */
7548 1.107 christos {
7549 1.107 christos .sy_flags = SYCALL_NOSYS,
7550 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7551 1.107 christos }, /* 228 = shmat */
7552 1.107 christos {
7553 1.107 christos .sy_flags = SYCALL_NOSYS,
7554 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7555 1.107 christos }, /* 229 = shmctl */
7556 1.107 christos {
7557 1.112 pgoyette .sy_flags = SYCALL_NOSYS,
7558 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7559 1.107 christos }, /* 230 = shmdt */
7560 1.107 christos {
7561 1.112 pgoyette .sy_flags = SYCALL_NOSYS,
7562 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7563 1.107 christos }, /* 231 = shmget */
7564 1.107 christos {
7565 1.107 christos .sy_flags = SYCALL_NOSYS,
7566 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7567 1.107 christos }, /* 232 = clock_gettime */
7568 1.107 christos {
7569 1.107 christos .sy_flags = SYCALL_NOSYS,
7570 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7571 1.107 christos }, /* 233 = clock_settime */
7572 1.107 christos {
7573 1.107 christos .sy_flags = SYCALL_NOSYS,
7574 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7575 1.107 christos }, /* 234 = clock_getres */
7576 1.107 christos {
7577 1.107 christos ns(struct sys_timer_create_args),
7578 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7579 1.107 christos }, /* 235 = timer_create */
7580 1.107 christos {
7581 1.107 christos ns(struct sys_timer_delete_args),
7582 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7583 1.107 christos }, /* 236 = timer_delete */
7584 1.107 christos {
7585 1.107 christos .sy_flags = SYCALL_NOSYS,
7586 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7587 1.107 christos }, /* 237 = timer_settime */
7588 1.107 christos {
7589 1.107 christos .sy_flags = SYCALL_NOSYS,
7590 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7591 1.107 christos }, /* 238 = timer_gettime */
7592 1.107 christos {
7593 1.107 christos ns(struct sys_timer_getoverrun_args),
7594 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7595 1.107 christos }, /* 239 = timer_getoverrun */
7596 1.107 christos {
7597 1.107 christos .sy_flags = SYCALL_NOSYS,
7598 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7599 1.107 christos }, /* 240 = nanosleep */
7600 1.107 christos {
7601 1.107 christos ns(struct sys_fdatasync_args),
7602 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7603 1.107 christos }, /* 241 = fdatasync */
7604 1.107 christos {
7605 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7606 1.107 christos }, /* 242 = mlockall */
7607 1.107 christos {
7608 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7609 1.107 christos }, /* 243 = munlockall */
7610 1.107 christos {
7611 1.107 christos .sy_flags = SYCALL_NOSYS,
7612 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7613 1.107 christos }, /* 244 = __sigtimedwait */
7614 1.107 christos {
7615 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7616 1.107 christos }, /* 245 = sigqueueinfo */
7617 1.107 christos {
7618 1.107 christos ns(struct sys_modctl_args),
7619 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7620 1.107 christos }, /* 246 = modctl */
7621 1.107 christos {
7622 1.107 christos ns(struct sys__ksem_init_args),
7623 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7624 1.107 christos }, /* 247 = _ksem_init */
7625 1.107 christos {
7626 1.107 christos ns(struct sys__ksem_open_args),
7627 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7628 1.107 christos }, /* 248 = _ksem_open */
7629 1.107 christos {
7630 1.107 christos ns(struct sys__ksem_unlink_args),
7631 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7632 1.107 christos }, /* 249 = _ksem_unlink */
7633 1.107 christos {
7634 1.107 christos ns(struct sys__ksem_close_args),
7635 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7636 1.107 christos }, /* 250 = _ksem_close */
7637 1.107 christos {
7638 1.107 christos ns(struct sys__ksem_post_args),
7639 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7640 1.107 christos }, /* 251 = _ksem_post */
7641 1.107 christos {
7642 1.107 christos ns(struct sys__ksem_wait_args),
7643 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7644 1.107 christos }, /* 252 = _ksem_wait */
7645 1.107 christos {
7646 1.107 christos ns(struct sys__ksem_trywait_args),
7647 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7648 1.107 christos }, /* 253 = _ksem_trywait */
7649 1.107 christos {
7650 1.107 christos ns(struct sys__ksem_getvalue_args),
7651 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7652 1.107 christos }, /* 254 = _ksem_getvalue */
7653 1.107 christos {
7654 1.107 christos ns(struct sys__ksem_destroy_args),
7655 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7656 1.107 christos }, /* 255 = _ksem_destroy */
7657 1.107 christos {
7658 1.107 christos ns(struct sys__ksem_timedwait_args),
7659 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7660 1.107 christos }, /* 256 = _ksem_timedwait */
7661 1.107 christos {
7662 1.107 christos .sy_flags = SYCALL_NOSYS,
7663 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7664 1.107 christos }, /* 257 = mq_open */
7665 1.107 christos {
7666 1.107 christos .sy_flags = SYCALL_NOSYS,
7667 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7668 1.107 christos }, /* 258 = mq_close */
7669 1.107 christos {
7670 1.107 christos .sy_flags = SYCALL_NOSYS,
7671 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7672 1.107 christos }, /* 259 = mq_unlink */
7673 1.107 christos {
7674 1.107 christos .sy_flags = SYCALL_NOSYS,
7675 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7676 1.107 christos }, /* 260 = mq_getattr */
7677 1.107 christos {
7678 1.107 christos .sy_flags = SYCALL_NOSYS,
7679 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7680 1.107 christos }, /* 261 = mq_setattr */
7681 1.107 christos {
7682 1.107 christos .sy_flags = SYCALL_NOSYS,
7683 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7684 1.107 christos }, /* 262 = mq_notify */
7685 1.107 christos {
7686 1.107 christos .sy_flags = SYCALL_NOSYS,
7687 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7688 1.107 christos }, /* 263 = mq_send */
7689 1.107 christos {
7690 1.107 christos .sy_flags = SYCALL_NOSYS,
7691 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7692 1.107 christos }, /* 264 = mq_receive */
7693 1.107 christos {
7694 1.107 christos .sy_flags = SYCALL_NOSYS,
7695 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7696 1.107 christos }, /* 265 = mq_timedsend */
7697 1.107 christos {
7698 1.107 christos .sy_flags = SYCALL_NOSYS,
7699 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7700 1.107 christos }, /* 266 = mq_timedreceive */
7701 1.107 christos {
7702 1.107 christos .sy_flags = SYCALL_NOSYS,
7703 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7704 1.107 christos }, /* 267 = filler */
7705 1.107 christos {
7706 1.107 christos .sy_flags = SYCALL_NOSYS,
7707 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7708 1.107 christos }, /* 268 = filler */
7709 1.107 christos {
7710 1.107 christos .sy_flags = SYCALL_NOSYS,
7711 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7712 1.107 christos }, /* 269 = filler */
7713 1.107 christos {
7714 1.108 justin ns(struct sys___posix_rename_args),
7715 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7716 1.108 justin }, /* 270 = __posix_rename */
7717 1.107 christos {
7718 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7719 1.107 christos }, /* 271 = swapctl */
7720 1.107 christos {
7721 1.107 christos .sy_flags = SYCALL_NOSYS,
7722 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7723 1.107 christos }, /* 272 = getdents */
7724 1.107 christos {
7725 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7726 1.107 christos }, /* 273 = minherit */
7727 1.107 christos {
7728 1.107 christos ns(struct sys_lchmod_args),
7729 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7730 1.107 christos }, /* 274 = lchmod */
7731 1.107 christos {
7732 1.107 christos ns(struct sys_lchown_args),
7733 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7734 1.107 christos }, /* 275 = lchown */
7735 1.107 christos {
7736 1.107 christos ns(struct compat_50_sys_lutimes_args),
7737 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7738 1.107 christos }, /* 276 = compat_50_lutimes */
7739 1.107 christos {
7740 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7741 1.107 christos }, /* 277 = __msync13 */
7742 1.107 christos {
7743 1.107 christos .sy_flags = SYCALL_NOSYS,
7744 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7745 1.107 christos }, /* 278 = __stat13 */
7746 1.107 christos {
7747 1.107 christos .sy_flags = SYCALL_NOSYS,
7748 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7749 1.107 christos }, /* 279 = __fstat13 */
7750 1.107 christos {
7751 1.107 christos .sy_flags = SYCALL_NOSYS,
7752 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7753 1.107 christos }, /* 280 = __lstat13 */
7754 1.107 christos {
7755 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7756 1.107 christos }, /* 281 = __sigaltstack14 */
7757 1.107 christos {
7758 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7759 1.107 christos }, /* 282 = __vfork14 */
7760 1.107 christos {
7761 1.113 pooka ns(struct sys___posix_chown_args),
7762 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7763 1.113 pooka }, /* 283 = __posix_chown */
7764 1.107 christos {
7765 1.113 pooka ns(struct sys___posix_fchown_args),
7766 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7767 1.113 pooka }, /* 284 = __posix_fchown */
7768 1.107 christos {
7769 1.113 pooka ns(struct sys___posix_lchown_args),
7770 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7771 1.113 pooka }, /* 285 = __posix_lchown */
7772 1.107 christos {
7773 1.107 christos ns(struct sys_getsid_args),
7774 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7775 1.107 christos }, /* 286 = getsid */
7776 1.107 christos {
7777 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7778 1.107 christos }, /* 287 = __clone */
7779 1.107 christos {
7780 1.107 christos ns(struct sys_fktrace_args),
7781 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7782 1.107 christos }, /* 288 = fktrace */
7783 1.107 christos {
7784 1.107 christos ns(struct sys_preadv_args),
7785 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7786 1.107 christos }, /* 289 = preadv */
7787 1.107 christos {
7788 1.107 christos ns(struct sys_pwritev_args),
7789 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7790 1.107 christos }, /* 290 = pwritev */
7791 1.107 christos {
7792 1.107 christos .sy_flags = SYCALL_NOSYS,
7793 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7794 1.107 christos }, /* 291 = __sigaction14 */
7795 1.107 christos {
7796 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7797 1.107 christos }, /* 292 = __sigpending14 */
7798 1.107 christos {
7799 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7800 1.107 christos }, /* 293 = __sigprocmask14 */
7801 1.107 christos {
7802 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7803 1.107 christos }, /* 294 = __sigsuspend14 */
7804 1.107 christos {
7805 1.107 christos .sy_flags = SYCALL_NOSYS,
7806 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7807 1.107 christos }, /* 295 = __sigreturn14 */
7808 1.107 christos {
7809 1.107 christos ns(struct sys___getcwd_args),
7810 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7811 1.107 christos }, /* 296 = __getcwd */
7812 1.107 christos {
7813 1.107 christos ns(struct sys_fchroot_args),
7814 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7815 1.107 christos }, /* 297 = fchroot */
7816 1.107 christos {
7817 1.107 christos .sy_flags = SYCALL_NOSYS,
7818 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7819 1.107 christos }, /* 298 = fhopen */
7820 1.107 christos {
7821 1.107 christos .sy_flags = SYCALL_NOSYS,
7822 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7823 1.107 christos }, /* 299 = fhstat */
7824 1.107 christos {
7825 1.107 christos .sy_flags = SYCALL_NOSYS,
7826 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7827 1.107 christos }, /* 300 = fhstatfs */
7828 1.107 christos {
7829 1.107 christos .sy_flags = SYCALL_NOSYS,
7830 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7831 1.107 christos }, /* 301 = ____semctl13 */
7832 1.107 christos {
7833 1.107 christos .sy_flags = SYCALL_NOSYS,
7834 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7835 1.107 christos }, /* 302 = __msgctl13 */
7836 1.107 christos {
7837 1.107 christos .sy_flags = SYCALL_NOSYS,
7838 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7839 1.107 christos }, /* 303 = __shmctl13 */
7840 1.107 christos {
7841 1.107 christos ns(struct sys_lchflags_args),
7842 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7843 1.107 christos }, /* 304 = lchflags */
7844 1.107 christos {
7845 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7846 1.107 christos }, /* 305 = issetugid */
7847 1.107 christos {
7848 1.107 christos ns(struct sys_utrace_args),
7849 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7850 1.107 christos }, /* 306 = utrace */
7851 1.107 christos {
7852 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7853 1.107 christos }, /* 307 = getcontext */
7854 1.107 christos {
7855 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7856 1.107 christos }, /* 308 = setcontext */
7857 1.107 christos {
7858 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7859 1.107 christos }, /* 309 = _lwp_create */
7860 1.107 christos {
7861 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7862 1.107 christos }, /* 310 = _lwp_exit */
7863 1.107 christos {
7864 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7865 1.107 christos }, /* 311 = _lwp_self */
7866 1.107 christos {
7867 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7868 1.107 christos }, /* 312 = _lwp_wait */
7869 1.107 christos {
7870 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7871 1.107 christos }, /* 313 = _lwp_suspend */
7872 1.107 christos {
7873 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7874 1.107 christos }, /* 314 = _lwp_continue */
7875 1.107 christos {
7876 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7877 1.107 christos }, /* 315 = _lwp_wakeup */
7878 1.107 christos {
7879 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7880 1.107 christos }, /* 316 = _lwp_getprivate */
7881 1.107 christos {
7882 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7883 1.107 christos }, /* 317 = _lwp_setprivate */
7884 1.107 christos {
7885 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7886 1.107 christos }, /* 318 = _lwp_kill */
7887 1.107 christos {
7888 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7889 1.107 christos }, /* 319 = _lwp_detach */
7890 1.107 christos {
7891 1.107 christos .sy_flags = SYCALL_NOSYS,
7892 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7893 1.107 christos }, /* 320 = _lwp_park */
7894 1.107 christos {
7895 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7896 1.107 christos }, /* 321 = _lwp_unpark */
7897 1.107 christos {
7898 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7899 1.107 christos }, /* 322 = _lwp_unpark_all */
7900 1.107 christos {
7901 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7902 1.107 christos }, /* 323 = _lwp_setname */
7903 1.107 christos {
7904 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7905 1.107 christos }, /* 324 = _lwp_getname */
7906 1.107 christos {
7907 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7908 1.107 christos }, /* 325 = _lwp_ctl */
7909 1.107 christos {
7910 1.146 thorpej .sy_flags = SYCALL_NOSYS,
7911 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7912 1.146 thorpej }, /* 326 = filler */
7913 1.107 christos {
7914 1.107 christos .sy_flags = SYCALL_NOSYS,
7915 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7916 1.107 christos }, /* 327 = filler */
7917 1.107 christos {
7918 1.107 christos .sy_flags = SYCALL_NOSYS,
7919 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7920 1.107 christos }, /* 328 = filler */
7921 1.107 christos {
7922 1.107 christos .sy_flags = SYCALL_NOSYS,
7923 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7924 1.107 christos }, /* 329 = filler */
7925 1.107 christos {
7926 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7927 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7928 1.107 christos }, /* 330 = sa_register */
7929 1.107 christos {
7930 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7931 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7932 1.107 christos }, /* 331 = sa_stacks */
7933 1.107 christos {
7934 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7935 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7936 1.107 christos }, /* 332 = sa_enable */
7937 1.107 christos {
7938 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7939 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7940 1.107 christos }, /* 333 = sa_setconcurrency */
7941 1.107 christos {
7942 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7943 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7944 1.107 christos }, /* 334 = sa_yield */
7945 1.107 christos {
7946 1.141 pgoyette .sy_flags = SYCALL_NOSYS,
7947 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7948 1.107 christos }, /* 335 = sa_preempt */
7949 1.107 christos {
7950 1.107 christos .sy_flags = SYCALL_NOSYS,
7951 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7952 1.107 christos }, /* 336 = filler */
7953 1.107 christos {
7954 1.107 christos .sy_flags = SYCALL_NOSYS,
7955 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7956 1.107 christos }, /* 337 = filler */
7957 1.107 christos {
7958 1.107 christos .sy_flags = SYCALL_NOSYS,
7959 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7960 1.107 christos }, /* 338 = filler */
7961 1.107 christos {
7962 1.107 christos .sy_flags = SYCALL_NOSYS,
7963 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7964 1.107 christos }, /* 339 = filler */
7965 1.107 christos {
7966 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7967 1.107 christos }, /* 340 = __sigaction_sigtramp */
7968 1.107 christos {
7969 1.138 maxv .sy_flags = SYCALL_NOSYS,
7970 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7971 1.138 maxv }, /* 341 = filler */
7972 1.107 christos {
7973 1.138 maxv .sy_flags = SYCALL_NOSYS,
7974 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7975 1.138 maxv }, /* 342 = filler */
7976 1.107 christos {
7977 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7978 1.107 christos }, /* 343 = rasctl */
7979 1.107 christos {
7980 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7981 1.107 christos }, /* 344 = kqueue */
7982 1.107 christos {
7983 1.107 christos ns(struct compat_50_sys_kevent_args),
7984 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
7985 1.107 christos }, /* 345 = compat_50_kevent */
7986 1.107 christos {
7987 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7988 1.107 christos }, /* 346 = _sched_setparam */
7989 1.107 christos {
7990 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7991 1.107 christos }, /* 347 = _sched_getparam */
7992 1.107 christos {
7993 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7994 1.107 christos }, /* 348 = _sched_setaffinity */
7995 1.107 christos {
7996 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
7997 1.107 christos }, /* 349 = _sched_getaffinity */
7998 1.107 christos {
7999 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8000 1.107 christos }, /* 350 = sched_yield */
8001 1.107 christos {
8002 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8003 1.129 christos }, /* 351 = _sched_protect */
8004 1.107 christos {
8005 1.107 christos .sy_flags = SYCALL_NOSYS,
8006 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8007 1.107 christos }, /* 352 = filler */
8008 1.107 christos {
8009 1.107 christos .sy_flags = SYCALL_NOSYS,
8010 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8011 1.107 christos }, /* 353 = filler */
8012 1.107 christos {
8013 1.107 christos ns(struct sys_fsync_range_args),
8014 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8015 1.107 christos }, /* 354 = fsync_range */
8016 1.107 christos {
8017 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8018 1.107 christos }, /* 355 = uuidgen */
8019 1.107 christos {
8020 1.142 christos .sy_flags = SYCALL_NOSYS,
8021 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8022 1.142 christos }, /* 356 = getvfsstat */
8023 1.107 christos {
8024 1.142 christos .sy_flags = SYCALL_NOSYS,
8025 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8026 1.142 christos }, /* 357 = statvfs1 */
8027 1.107 christos {
8028 1.142 christos .sy_flags = SYCALL_NOSYS,
8029 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8030 1.142 christos }, /* 358 = fstatvfs1 */
8031 1.107 christos {
8032 1.107 christos .sy_flags = SYCALL_NOSYS,
8033 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8034 1.107 christos }, /* 359 = fhstatvfs1 */
8035 1.107 christos {
8036 1.107 christos ns(struct sys_extattrctl_args),
8037 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8038 1.107 christos }, /* 360 = extattrctl */
8039 1.107 christos {
8040 1.107 christos ns(struct sys_extattr_set_file_args),
8041 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8042 1.107 christos }, /* 361 = extattr_set_file */
8043 1.107 christos {
8044 1.107 christos ns(struct sys_extattr_get_file_args),
8045 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8046 1.107 christos }, /* 362 = extattr_get_file */
8047 1.107 christos {
8048 1.107 christos ns(struct sys_extattr_delete_file_args),
8049 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8050 1.107 christos }, /* 363 = extattr_delete_file */
8051 1.107 christos {
8052 1.107 christos ns(struct sys_extattr_set_fd_args),
8053 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8054 1.107 christos }, /* 364 = extattr_set_fd */
8055 1.107 christos {
8056 1.107 christos ns(struct sys_extattr_get_fd_args),
8057 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8058 1.107 christos }, /* 365 = extattr_get_fd */
8059 1.107 christos {
8060 1.107 christos ns(struct sys_extattr_delete_fd_args),
8061 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8062 1.107 christos }, /* 366 = extattr_delete_fd */
8063 1.107 christos {
8064 1.107 christos ns(struct sys_extattr_set_link_args),
8065 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8066 1.107 christos }, /* 367 = extattr_set_link */
8067 1.107 christos {
8068 1.107 christos ns(struct sys_extattr_get_link_args),
8069 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8070 1.107 christos }, /* 368 = extattr_get_link */
8071 1.107 christos {
8072 1.107 christos ns(struct sys_extattr_delete_link_args),
8073 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8074 1.107 christos }, /* 369 = extattr_delete_link */
8075 1.107 christos {
8076 1.107 christos ns(struct sys_extattr_list_fd_args),
8077 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8078 1.107 christos }, /* 370 = extattr_list_fd */
8079 1.107 christos {
8080 1.107 christos ns(struct sys_extattr_list_file_args),
8081 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8082 1.107 christos }, /* 371 = extattr_list_file */
8083 1.107 christos {
8084 1.107 christos ns(struct sys_extattr_list_link_args),
8085 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8086 1.107 christos }, /* 372 = extattr_list_link */
8087 1.107 christos {
8088 1.107 christos ns(struct compat_50_sys_pselect_args),
8089 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8090 1.107 christos }, /* 373 = compat_50_pselect */
8091 1.107 christos {
8092 1.107 christos ns(struct compat_50_sys_pollts_args),
8093 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8094 1.107 christos }, /* 374 = compat_50_pollts */
8095 1.107 christos {
8096 1.107 christos ns(struct sys_setxattr_args),
8097 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8098 1.107 christos }, /* 375 = setxattr */
8099 1.107 christos {
8100 1.107 christos ns(struct sys_lsetxattr_args),
8101 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8102 1.107 christos }, /* 376 = lsetxattr */
8103 1.107 christos {
8104 1.107 christos ns(struct sys_fsetxattr_args),
8105 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8106 1.107 christos }, /* 377 = fsetxattr */
8107 1.107 christos {
8108 1.107 christos ns(struct sys_getxattr_args),
8109 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8110 1.107 christos }, /* 378 = getxattr */
8111 1.107 christos {
8112 1.107 christos ns(struct sys_lgetxattr_args),
8113 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8114 1.107 christos }, /* 379 = lgetxattr */
8115 1.107 christos {
8116 1.107 christos ns(struct sys_fgetxattr_args),
8117 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8118 1.107 christos }, /* 380 = fgetxattr */
8119 1.107 christos {
8120 1.107 christos ns(struct sys_listxattr_args),
8121 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8122 1.107 christos }, /* 381 = listxattr */
8123 1.107 christos {
8124 1.107 christos ns(struct sys_llistxattr_args),
8125 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8126 1.107 christos }, /* 382 = llistxattr */
8127 1.107 christos {
8128 1.107 christos ns(struct sys_flistxattr_args),
8129 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8130 1.107 christos }, /* 383 = flistxattr */
8131 1.107 christos {
8132 1.107 christos ns(struct sys_removexattr_args),
8133 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8134 1.107 christos }, /* 384 = removexattr */
8135 1.107 christos {
8136 1.107 christos ns(struct sys_lremovexattr_args),
8137 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8138 1.107 christos }, /* 385 = lremovexattr */
8139 1.107 christos {
8140 1.107 christos ns(struct sys_fremovexattr_args),
8141 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8142 1.107 christos }, /* 386 = fremovexattr */
8143 1.107 christos {
8144 1.107 christos ns(struct compat_50_sys___stat30_args),
8145 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8146 1.107 christos }, /* 387 = compat_50___stat30 */
8147 1.107 christos {
8148 1.107 christos ns(struct compat_50_sys___fstat30_args),
8149 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8150 1.107 christos }, /* 388 = compat_50___fstat30 */
8151 1.107 christos {
8152 1.107 christos ns(struct compat_50_sys___lstat30_args),
8153 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8154 1.107 christos }, /* 389 = compat_50___lstat30 */
8155 1.107 christos {
8156 1.107 christos ns(struct sys___getdents30_args),
8157 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8158 1.107 christos }, /* 390 = __getdents30 */
8159 1.107 christos {
8160 1.107 christos .sy_flags = SYCALL_NOSYS,
8161 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8162 1.107 christos }, /* 391 = filler */
8163 1.107 christos {
8164 1.107 christos .sy_flags = SYCALL_NOSYS,
8165 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8166 1.107 christos }, /* 392 = __fhstat30 */
8167 1.107 christos {
8168 1.107 christos .sy_flags = SYCALL_NOSYS,
8169 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8170 1.107 christos }, /* 393 = __ntp_gettime30 */
8171 1.107 christos {
8172 1.107 christos ns(struct sys___socket30_args),
8173 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8174 1.107 christos }, /* 394 = __socket30 */
8175 1.107 christos {
8176 1.107 christos ns(struct sys___getfh30_args),
8177 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8178 1.107 christos }, /* 395 = __getfh30 */
8179 1.107 christos {
8180 1.107 christos ns(struct sys___fhopen40_args),
8181 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8182 1.107 christos }, /* 396 = __fhopen40 */
8183 1.107 christos {
8184 1.142 christos .sy_flags = SYCALL_NOSYS,
8185 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8186 1.142 christos }, /* 397 = fhstatvfs1 */
8187 1.107 christos {
8188 1.107 christos ns(struct compat_50_sys___fhstat40_args),
8189 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8190 1.107 christos }, /* 398 = compat_50___fhstat40 */
8191 1.107 christos {
8192 1.107 christos ns(struct sys_aio_cancel_args),
8193 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8194 1.107 christos }, /* 399 = aio_cancel */
8195 1.107 christos {
8196 1.107 christos ns(struct sys_aio_error_args),
8197 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8198 1.107 christos }, /* 400 = aio_error */
8199 1.107 christos {
8200 1.107 christos ns(struct sys_aio_fsync_args),
8201 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8202 1.107 christos }, /* 401 = aio_fsync */
8203 1.107 christos {
8204 1.107 christos ns(struct sys_aio_read_args),
8205 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8206 1.107 christos }, /* 402 = aio_read */
8207 1.107 christos {
8208 1.107 christos ns(struct sys_aio_return_args),
8209 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8210 1.107 christos }, /* 403 = aio_return */
8211 1.107 christos {
8212 1.107 christos .sy_flags = SYCALL_NOSYS,
8213 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8214 1.107 christos }, /* 404 = aio_suspend */
8215 1.107 christos {
8216 1.107 christos ns(struct sys_aio_write_args),
8217 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8218 1.107 christos }, /* 405 = aio_write */
8219 1.107 christos {
8220 1.107 christos ns(struct sys_lio_listio_args),
8221 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8222 1.107 christos }, /* 406 = lio_listio */
8223 1.107 christos {
8224 1.107 christos .sy_flags = SYCALL_NOSYS,
8225 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8226 1.107 christos }, /* 407 = filler */
8227 1.107 christos {
8228 1.107 christos .sy_flags = SYCALL_NOSYS,
8229 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8230 1.107 christos }, /* 408 = filler */
8231 1.107 christos {
8232 1.107 christos .sy_flags = SYCALL_NOSYS,
8233 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8234 1.107 christos }, /* 409 = filler */
8235 1.107 christos {
8236 1.107 christos ns(struct sys___mount50_args),
8237 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8238 1.107 christos }, /* 410 = __mount50 */
8239 1.107 christos {
8240 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8241 1.107 christos }, /* 411 = mremap */
8242 1.107 christos {
8243 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8244 1.107 christos }, /* 412 = pset_create */
8245 1.107 christos {
8246 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8247 1.107 christos }, /* 413 = pset_destroy */
8248 1.107 christos {
8249 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8250 1.107 christos }, /* 414 = pset_assign */
8251 1.107 christos {
8252 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8253 1.107 christos }, /* 415 = _pset_bind */
8254 1.107 christos {
8255 1.107 christos ns(struct sys___posix_fadvise50_args),
8256 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8257 1.107 christos }, /* 416 = __posix_fadvise50 */
8258 1.107 christos {
8259 1.107 christos ns(struct sys___select50_args),
8260 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8261 1.107 christos }, /* 417 = __select50 */
8262 1.107 christos {
8263 1.107 christos ns(struct sys___gettimeofday50_args),
8264 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8265 1.107 christos }, /* 418 = __gettimeofday50 */
8266 1.107 christos {
8267 1.107 christos ns(struct sys___settimeofday50_args),
8268 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8269 1.107 christos }, /* 419 = __settimeofday50 */
8270 1.107 christos {
8271 1.107 christos ns(struct sys___utimes50_args),
8272 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8273 1.107 christos }, /* 420 = __utimes50 */
8274 1.107 christos {
8275 1.107 christos ns(struct sys___adjtime50_args),
8276 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8277 1.107 christos }, /* 421 = __adjtime50 */
8278 1.107 christos {
8279 1.107 christos .sy_flags = SYCALL_NOSYS,
8280 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8281 1.107 christos }, /* 422 = __lfs_segwait50 */
8282 1.107 christos {
8283 1.107 christos ns(struct sys___futimes50_args),
8284 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8285 1.107 christos }, /* 423 = __futimes50 */
8286 1.107 christos {
8287 1.107 christos ns(struct sys___lutimes50_args),
8288 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8289 1.107 christos }, /* 424 = __lutimes50 */
8290 1.107 christos {
8291 1.107 christos ns(struct sys___setitimer50_args),
8292 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8293 1.107 christos }, /* 425 = __setitimer50 */
8294 1.107 christos {
8295 1.107 christos ns(struct sys___getitimer50_args),
8296 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8297 1.107 christos }, /* 426 = __getitimer50 */
8298 1.107 christos {
8299 1.107 christos ns(struct sys___clock_gettime50_args),
8300 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8301 1.107 christos }, /* 427 = __clock_gettime50 */
8302 1.107 christos {
8303 1.107 christos ns(struct sys___clock_settime50_args),
8304 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8305 1.107 christos }, /* 428 = __clock_settime50 */
8306 1.107 christos {
8307 1.107 christos ns(struct sys___clock_getres50_args),
8308 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8309 1.107 christos }, /* 429 = __clock_getres50 */
8310 1.107 christos {
8311 1.107 christos ns(struct sys___nanosleep50_args),
8312 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8313 1.107 christos }, /* 430 = __nanosleep50 */
8314 1.107 christos {
8315 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8316 1.107 christos }, /* 431 = ____sigtimedwait50 */
8317 1.107 christos {
8318 1.107 christos .sy_flags = SYCALL_NOSYS,
8319 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8320 1.107 christos }, /* 432 = __mq_timedsend50 */
8321 1.107 christos {
8322 1.107 christos .sy_flags = SYCALL_NOSYS,
8323 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8324 1.107 christos }, /* 433 = __mq_timedreceive50 */
8325 1.107 christos {
8326 1.107 christos .sy_flags = SYCALL_NOSYS,
8327 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8328 1.107 christos }, /* 434 = _lwp_park */
8329 1.107 christos {
8330 1.107 christos ns(struct sys___kevent50_args),
8331 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8332 1.107 christos }, /* 435 = __kevent50 */
8333 1.107 christos {
8334 1.107 christos ns(struct sys___pselect50_args),
8335 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8336 1.107 christos }, /* 436 = __pselect50 */
8337 1.107 christos {
8338 1.107 christos ns(struct sys___pollts50_args),
8339 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8340 1.107 christos }, /* 437 = __pollts50 */
8341 1.107 christos {
8342 1.107 christos ns(struct sys___aio_suspend50_args),
8343 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8344 1.107 christos }, /* 438 = __aio_suspend50 */
8345 1.107 christos {
8346 1.107 christos ns(struct sys___stat50_args),
8347 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8348 1.107 christos }, /* 439 = __stat50 */
8349 1.107 christos {
8350 1.107 christos ns(struct sys___fstat50_args),
8351 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8352 1.107 christos }, /* 440 = __fstat50 */
8353 1.107 christos {
8354 1.107 christos ns(struct sys___lstat50_args),
8355 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8356 1.107 christos }, /* 441 = __lstat50 */
8357 1.107 christos {
8358 1.112 pgoyette .sy_flags = SYCALL_NOSYS,
8359 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8360 1.107 christos }, /* 442 = ____semctl50 */
8361 1.107 christos {
8362 1.107 christos .sy_flags = SYCALL_NOSYS,
8363 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8364 1.107 christos }, /* 443 = __shmctl50 */
8365 1.107 christos {
8366 1.107 christos .sy_flags = SYCALL_NOSYS,
8367 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_sys_nomodule,
8368 1.107 christos }, /* 444 = __msgctl50 */
8369 1.107 christos {
8370 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8371 1.107 christos }, /* 445 = __getrusage50 */
8372 1.107 christos {
8373 1.107 christos ns(struct sys___timer_settime50_args),
8374 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8375 1.107 christos }, /* 446 = __timer_settime50 */
8376 1.107 christos {
8377 1.107 christos ns(struct sys___timer_gettime50_args),
8378 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8379 1.107 christos }, /* 447 = __timer_gettime50 */
8380 1.29 pooka #if defined(NTP) || !defined(_KERNEL_OPT)
8381 1.107 christos {
8382 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8383 1.107 christos }, /* 448 = __ntp_gettime50 */
8384 1.29 pooka #else
8385 1.107 christos {
8386 1.107 christos .sy_flags = SYCALL_NOSYS,
8387 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8388 1.107 christos }, /* 448 = filler */
8389 1.29 pooka #endif
8390 1.107 christos {
8391 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8392 1.107 christos }, /* 449 = __wait450 */
8393 1.107 christos {
8394 1.107 christos ns(struct sys___mknod50_args),
8395 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8396 1.107 christos }, /* 450 = __mknod50 */
8397 1.107 christos {
8398 1.107 christos ns(struct sys___fhstat50_args),
8399 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8400 1.107 christos }, /* 451 = __fhstat50 */
8401 1.107 christos {
8402 1.107 christos .sy_flags = SYCALL_NOSYS,
8403 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8404 1.107 christos }, /* 452 = filler */
8405 1.107 christos {
8406 1.107 christos ns(struct sys_pipe2_args),
8407 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8408 1.107 christos }, /* 453 = pipe2 */
8409 1.107 christos {
8410 1.107 christos ns(struct sys_dup3_args),
8411 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8412 1.107 christos }, /* 454 = dup3 */
8413 1.107 christos {
8414 1.107 christos ns(struct sys_kqueue1_args),
8415 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8416 1.107 christos }, /* 455 = kqueue1 */
8417 1.107 christos {
8418 1.107 christos ns(struct sys_paccept_args),
8419 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8420 1.107 christos }, /* 456 = paccept */
8421 1.107 christos {
8422 1.107 christos ns(struct sys_linkat_args),
8423 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8424 1.107 christos }, /* 457 = linkat */
8425 1.107 christos {
8426 1.107 christos ns(struct sys_renameat_args),
8427 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8428 1.107 christos }, /* 458 = renameat */
8429 1.107 christos {
8430 1.107 christos ns(struct sys_mkfifoat_args),
8431 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8432 1.107 christos }, /* 459 = mkfifoat */
8433 1.107 christos {
8434 1.107 christos ns(struct sys_mknodat_args),
8435 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8436 1.107 christos }, /* 460 = mknodat */
8437 1.107 christos {
8438 1.107 christos ns(struct sys_mkdirat_args),
8439 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8440 1.107 christos }, /* 461 = mkdirat */
8441 1.107 christos {
8442 1.107 christos ns(struct sys_faccessat_args),
8443 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8444 1.107 christos }, /* 462 = faccessat */
8445 1.107 christos {
8446 1.107 christos ns(struct sys_fchmodat_args),
8447 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8448 1.107 christos }, /* 463 = fchmodat */
8449 1.107 christos {
8450 1.107 christos ns(struct sys_fchownat_args),
8451 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8452 1.107 christos }, /* 464 = fchownat */
8453 1.107 christos {
8454 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8455 1.107 christos }, /* 465 = fexecve */
8456 1.107 christos {
8457 1.107 christos ns(struct sys_fstatat_args),
8458 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8459 1.107 christos }, /* 466 = fstatat */
8460 1.107 christos {
8461 1.107 christos ns(struct sys_utimensat_args),
8462 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8463 1.107 christos }, /* 467 = utimensat */
8464 1.107 christos {
8465 1.107 christos ns(struct sys_openat_args),
8466 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8467 1.107 christos }, /* 468 = openat */
8468 1.107 christos {
8469 1.107 christos ns(struct sys_readlinkat_args),
8470 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8471 1.107 christos }, /* 469 = readlinkat */
8472 1.107 christos {
8473 1.107 christos ns(struct sys_symlinkat_args),
8474 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8475 1.107 christos }, /* 470 = symlinkat */
8476 1.107 christos {
8477 1.107 christos ns(struct sys_unlinkat_args),
8478 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8479 1.107 christos }, /* 471 = unlinkat */
8480 1.107 christos {
8481 1.107 christos ns(struct sys_futimens_args),
8482 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8483 1.107 christos }, /* 472 = futimens */
8484 1.107 christos {
8485 1.107 christos ns(struct sys___quotactl_args),
8486 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8487 1.107 christos }, /* 473 = __quotactl */
8488 1.107 christos {
8489 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8490 1.107 christos }, /* 474 = posix_spawn */
8491 1.107 christos {
8492 1.107 christos ns(struct sys_recvmmsg_args),
8493 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8494 1.107 christos }, /* 475 = recvmmsg */
8495 1.107 christos {
8496 1.107 christos ns(struct sys_sendmmsg_args),
8497 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8498 1.107 christos }, /* 476 = sendmmsg */
8499 1.107 christos {
8500 1.107 christos ns(struct sys_clock_nanosleep_args),
8501 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8502 1.107 christos }, /* 477 = clock_nanosleep */
8503 1.107 christos {
8504 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8505 1.107 christos }, /* 478 = ___lwp_park60 */
8506 1.107 christos {
8507 1.107 christos ns(struct sys_posix_fallocate_args),
8508 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8509 1.107 christos }, /* 479 = posix_fallocate */
8510 1.107 christos {
8511 1.107 christos ns(struct sys_fdiscard_args),
8512 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8513 1.107 christos }, /* 480 = fdiscard */
8514 1.107 christos {
8515 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8516 1.124 christos }, /* 481 = wait6 */
8517 1.107 christos {
8518 1.155 christos ns(struct sys_clock_getcpuclockid2_args),
8519 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8520 1.155 christos }, /* 482 = clock_getcpuclockid2 */
8521 1.107 christos {
8522 1.142 christos ns(struct sys___getvfsstat90_args),
8523 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8524 1.142 christos }, /* 483 = __getvfsstat90 */
8525 1.107 christos {
8526 1.142 christos ns(struct sys___statvfs190_args),
8527 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8528 1.142 christos }, /* 484 = __statvfs190 */
8529 1.107 christos {
8530 1.142 christos ns(struct sys___fstatvfs190_args),
8531 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8532 1.142 christos }, /* 485 = __fstatvfs190 */
8533 1.107 christos {
8534 1.142 christos ns(struct sys___fhstatvfs190_args),
8535 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8536 1.142 christos }, /* 486 = __fhstatvfs190 */
8537 1.107 christos {
8538 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8539 1.150 christos }, /* 487 = __acl_get_link */
8540 1.107 christos {
8541 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8542 1.150 christos }, /* 488 = __acl_set_link */
8543 1.107 christos {
8544 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8545 1.150 christos }, /* 489 = __acl_delete_link */
8546 1.107 christos {
8547 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8548 1.150 christos }, /* 490 = __acl_aclcheck_link */
8549 1.107 christos {
8550 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8551 1.150 christos }, /* 491 = __acl_get_file */
8552 1.107 christos {
8553 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8554 1.150 christos }, /* 492 = __acl_set_file */
8555 1.107 christos {
8556 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8557 1.150 christos }, /* 493 = __acl_get_fd */
8558 1.107 christos {
8559 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8560 1.150 christos }, /* 494 = __acl_set_fd */
8561 1.107 christos {
8562 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8563 1.150 christos }, /* 495 = __acl_delete_file */
8564 1.107 christos {
8565 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8566 1.150 christos }, /* 496 = __acl_delete_fd */
8567 1.107 christos {
8568 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8569 1.150 christos }, /* 497 = __acl_aclcheck_file */
8570 1.107 christos {
8571 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8572 1.150 christos }, /* 498 = __acl_aclcheck_fd */
8573 1.107 christos {
8574 1.150 christos ns(struct sys_lpathconf_args),
8575 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8576 1.150 christos }, /* 499 = lpathconf */
8577 1.107 christos {
8578 1.107 christos .sy_flags = SYCALL_NOSYS,
8579 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8580 1.107 christos }, /* 500 = filler */
8581 1.107 christos {
8582 1.107 christos .sy_flags = SYCALL_NOSYS,
8583 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8584 1.107 christos }, /* 501 = filler */
8585 1.107 christos {
8586 1.107 christos .sy_flags = SYCALL_NOSYS,
8587 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8588 1.107 christos }, /* 502 = filler */
8589 1.107 christos {
8590 1.107 christos .sy_flags = SYCALL_NOSYS,
8591 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8592 1.107 christos }, /* 503 = filler */
8593 1.107 christos {
8594 1.107 christos .sy_flags = SYCALL_NOSYS,
8595 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8596 1.107 christos }, /* 504 = filler */
8597 1.107 christos {
8598 1.107 christos .sy_flags = SYCALL_NOSYS,
8599 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8600 1.107 christos }, /* 505 = filler */
8601 1.107 christos {
8602 1.107 christos .sy_flags = SYCALL_NOSYS,
8603 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8604 1.107 christos }, /* 506 = filler */
8605 1.107 christos {
8606 1.107 christos .sy_flags = SYCALL_NOSYS,
8607 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8608 1.107 christos }, /* 507 = filler */
8609 1.107 christos {
8610 1.107 christos .sy_flags = SYCALL_NOSYS,
8611 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8612 1.107 christos }, /* 508 = filler */
8613 1.107 christos {
8614 1.107 christos .sy_flags = SYCALL_NOSYS,
8615 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8616 1.107 christos }, /* 509 = filler */
8617 1.107 christos {
8618 1.107 christos .sy_flags = SYCALL_NOSYS,
8619 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8620 1.107 christos }, /* 510 = filler */
8621 1.107 christos {
8622 1.107 christos .sy_flags = SYCALL_NOSYS,
8623 1.143 christos .sy_call = (sy_call_t *)(void *)rumpns_enosys,
8624 1.107 christos }, /* 511 = filler */
8625 1.29 pooka };
8626 1.140 pgoyette
8627 1.140 pgoyette const uint32_t rump_sysent_nomodbits[] = {
8628 1.140 pgoyette 0x042c4180, /* syscalls 0- 31 */
8629 1.140 pgoyette 0xc0b14140, /* syscalls 32- 63 */
8630 1.140 pgoyette 0x23f80083, /* syscalls 64- 95 */
8631 1.140 pgoyette 0x2437f0ea, /* syscalls 96-127 */
8632 1.140 pgoyette 0x7877f406, /* syscalls 128-159 */
8633 1.142 christos 0x7f008e1e, /* syscalls 160-191 */
8634 1.140 pgoyette 0xf0044010, /* syscalls 192-223 */
8635 1.140 pgoyette 0xff9167ff, /* syscalls 224-255 */
8636 1.140 pgoyette 0x01d107ff, /* syscalls 256-287 */
8637 1.140 pgoyette 0x0000fc88, /* syscalls 288-319 */
8638 1.142 christos 0x0200fc01, /* syscalls 320-351 */
8639 1.142 christos 0x006000f0, /* syscalls 352-383 */
8640 1.142 christos 0x007fe338, /* syscalls 384-415 */
8641 1.140 pgoyette 0x1c470040, /* syscalls 416-447 */
8642 1.140 pgoyette 0x00000000, /* syscalls 448-479 */
8643 1.140 pgoyette 0x00000000, /* syscalls 480-511 */
8644 1.140 pgoyette };
8645 1.29 pooka CTASSERT(__arraycount(rump_sysent) == SYS_NSYSENT);
8646 1.90 pooka __strong_alias(rumpns_sysent,rump_sysent);
8647 1.53 pooka #endif /* RUMP_CLIENT */
8648