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