syscalls.master revision 1.178
11.178Sad $NetBSD: syscalls.master,v 1.178 2007/11/07 00:37:21 ad Exp $ 21.28Smycroft 31.22Scgd; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 41.1Sglass 51.23Scgd; NetBSD system call name/number "master" file. 61.23Scgd; (See syscalls.conf to see what it is processed into.) 71.23Scgd; 81.23Scgd; Fields: number type [type-dependent ...] 91.1Sglass; number system call number, must be in order 101.23Scgd; type one of STD, OBSOL, UNIMPL, NODEF, NOARGS, or one of 111.24Smycroft; the compatibility options defined in syscalls.conf. 121.23Scgd; 131.108Sthorpej; An optional field, MPSAFE, after the type field, indicates that 141.108Sthorpej; the system call is MP-safe. 151.108Sthorpej; 161.1Sglass; types: 171.1Sglass; STD always included 181.23Scgd; OBSOL obsolete, not included in system 191.24Smycroft; UNIMPL unimplemented, not included in system 201.92Schristos; EXCL implemented, but not included in system 211.23Scgd; NODEF included, but don't define the syscall number 221.23Scgd; NOARGS included, but don't define the syscall args structure 231.43Scgd; INDIR included, but don't define the syscall args structure, 241.43Scgd; and allow it to be "really" varargs. 251.23Scgd; 261.23Scgd; The compat options are defined in the syscalls.conf file, and the 271.23Scgd; compat option name is prefixed to the syscall name. Other than 281.23Scgd; that, they're like NODEF (for 'compat' options), or STD (for 291.23Scgd; 'libcompat' options). 301.23Scgd; 311.23Scgd; The type-dependent arguments are as follows: 321.23Scgd; For STD, NODEF, NOARGS, and compat syscalls: 331.23Scgd; { pseudo-proto } [alias] 341.23Scgd; For other syscalls: 351.23Scgd; [comment] 361.23Scgd; 371.23Scgd; #ifdef's, etc. may be included, and are copied to the output files. 381.70Sthorpej; #include's are copied to the syscall names and switch definition files only. 391.77Sthorpej 401.78Sthorpej#include "opt_nfsserver.h" 411.102Sbjh21#include "opt_ntp.h" 421.81Sjonathan#include "opt_compat_netbsd.h" 431.85Stron#include "opt_sysv.h" 441.87Schristos#include "opt_compat_43.h" 451.119Schristos#include "opt_posix.h" 461.70Sthorpej 471.70Sthorpej#include "fs_lfs.h" 481.70Sthorpej#include "fs_nfs.h" 491.1Sglass 501.23Scgd#include <sys/param.h> 511.23Scgd#include <sys/systm.h> 521.23Scgd#include <sys/signal.h> 531.23Scgd#include <sys/mount.h> 541.23Scgd#include <sys/syscallargs.h> 551.103Smycroft 561.103Smycroft%% 571.1Sglass 581.1Sglass; Reserved/unimplemented system calls in the range 0-150 inclusive 591.1Sglass; are reserved for use in future Berkeley releases. 601.1Sglass; Additional system calls implemented in vendor and other 611.1Sglass; redistributions should be placed in the reserved range at the end 621.1Sglass; of the current calls. 631.1Sglass 641.43Scgd0 INDIR { int sys_syscall(int number, ...); } 651.44Scgd1 STD { void sys_exit(int rval); } 661.28Smycroft2 STD { int sys_fork(void); } 671.46Scgd3 STD { ssize_t sys_read(int fd, void *buf, size_t nbyte); } 681.46Scgd4 STD { ssize_t sys_write(int fd, const void *buf, \ 691.46Scgd size_t nbyte); } 701.46Scgd5 STD { int sys_open(const char *path, \ 711.60Schristos int flags, ... mode_t mode); } 721.28Smycroft6 STD { int sys_close(int fd); } 731.174Sad7 STD { int sys_wait4(int pid, int *status, int options, \ 741.23Scgd struct rusage *rusage); } 751.60Schristos8 COMPAT_43 { int sys_creat(const char *path, mode_t mode); } ocreat 761.46Scgd9 STD { int sys_link(const char *path, const char *link); } 771.46Scgd10 STD { int sys_unlink(const char *path); } 781.23Scgd11 OBSOL execv 791.46Scgd12 STD { int sys_chdir(const char *path); } 801.28Smycroft13 STD { int sys_fchdir(int fd); } 811.60Schristos14 STD { int sys_mknod(const char *path, mode_t mode, \ 821.60Schristos dev_t dev); } 831.60Schristos15 STD { int sys_chmod(const char *path, mode_t mode); } 841.46Scgd16 STD { int sys_chown(const char *path, uid_t uid, \ 851.46Scgd gid_t gid); } 861.28Smycroft17 STD { int sys_obreak(char *nsize); } break 871.139Schristos18 COMPAT_20 { int sys_getfsstat(struct statfs12 *buf, \ 881.139Schristos long bufsize, int flags); } 891.29Smycroft19 COMPAT_43 { long sys_lseek(int fd, long offset, int whence); } \ 901.29Smycroft olseek 911.104Smycroft#ifdef COMPAT_43 921.163Sad20 STD MPSAFE { pid_t sys_getpid_with_ppid(void); } getpid 931.104Smycroft#else 941.108Sthorpej20 STD MPSAFE { pid_t sys_getpid(void); } 951.104Smycroft#endif 961.170Sdsl21 COMPAT_40 { int sys_mount(const char *type, const char *path, \ 971.46Scgd int flags, void *data); } 981.46Scgd22 STD { int sys_unmount(const char *path, int flags); } 991.163Sad23 STD { int sys_setuid(uid_t uid); } 1001.104Smycroft#ifdef COMPAT_43 1011.104Smycroft24 STD { uid_t sys_getuid_with_euid(void); } getuid 1021.104Smycroft#else 1031.163Sad24 STD MPSAFE { uid_t sys_getuid(void); } 1041.104Smycroft#endif 1051.163Sad25 STD MPSAFE { uid_t sys_geteuid(void); } 1061.167Schristos26 STD { int sys_ptrace(int req, pid_t pid, void *addr, \ 1071.23Scgd int data); } 1081.44Scgd27 STD { ssize_t sys_recvmsg(int s, struct msghdr *msg, \ 1091.28Smycroft int flags); } 1101.46Scgd28 STD { ssize_t sys_sendmsg(int s, \ 1111.46Scgd const struct msghdr *msg, int flags); } 1121.46Scgd29 STD { ssize_t sys_recvfrom(int s, void *buf, size_t len, \ 1131.46Scgd int flags, struct sockaddr *from, \ 1141.88Skleink unsigned int *fromlenaddr); } 1151.46Scgd30 STD { int sys_accept(int s, struct sockaddr *name, \ 1161.88Skleink unsigned int *anamelen); } 1171.46Scgd31 STD { int sys_getpeername(int fdes, struct sockaddr *asa, \ 1181.88Skleink unsigned int *alen); } 1191.46Scgd32 STD { int sys_getsockname(int fdes, struct sockaddr *asa, \ 1201.88Skleink unsigned int *alen); } 1211.46Scgd33 STD { int sys_access(const char *path, int flags); } 1221.46Scgd34 STD { int sys_chflags(const char *path, u_long flags); } 1231.46Scgd35 STD { int sys_fchflags(int fd, u_long flags); } 1241.44Scgd36 STD { void sys_sync(void); } 1251.163Sad37 STD { int sys_kill(int pid, int signum); } 1261.60Schristos38 COMPAT_43 { int sys_stat(const char *path, struct stat43 *ub); } \ 1271.60Schristos stat43 1281.163Sad39 STD MPSAFE { pid_t sys_getppid(void); } 1291.60Schristos40 COMPAT_43 { int sys_lstat(const char *path, \ 1301.60Schristos struct stat43 *ub); } lstat43 1311.59Smycroft41 STD { int sys_dup(int fd); } 1321.28Smycroft42 STD { int sys_pipe(void); } 1331.163Sad43 STD MPSAFE { gid_t sys_getegid(void); } 1341.168Sdrochner44 STD MPSAFE { int sys_profil(char *samples, size_t size, \ 1351.30Scgd u_long offset, u_int scale); } 1361.46Scgd45 STD { int sys_ktrace(const char *fname, int ops, \ 1371.46Scgd int facs, int pid); } 1381.163Sad46 COMPAT_13 MPSAFE { int sys_sigaction(int signum, \ 1391.82Smycroft const struct sigaction13 *nsa, \ 1401.82Smycroft struct sigaction13 *osa); } sigaction13 1411.104Smycroft#ifdef COMPAT_43 1421.163Sad47 STD MPSAFE { gid_t sys_getgid_with_egid(void); } getgid 1431.104Smycroft#else 1441.163Sad47 STD MPSAFE { gid_t sys_getgid(void); } 1451.104Smycroft#endif 1461.163Sad48 COMPAT_13 MPSAFE { int sys_sigprocmask(int how, \ 1471.82Smycroft int mask); } sigprocmask13 1481.163Sad49 STD MPSAFE { int sys___getlogin(char *namebuf, size_t namelen); } 1491.163Sad50 STD { int sys___setlogin(const char *namebuf); } 1501.46Scgd51 STD { int sys_acct(const char *path); } 1511.163Sad52 COMPAT_13 MPSAFE { int sys_sigpending(void); } sigpending13 1521.163Sad53 COMPAT_13 MPSAFE { int sys_sigaltstack( \ 1531.82Smycroft const struct sigaltstack13 *nss, \ 1541.82Smycroft struct sigaltstack13 *oss); } sigaltstack13 1551.46Scgd54 STD { int sys_ioctl(int fd, \ 1561.61Schristos u_long com, ... void *data); } 1571.34Smrg55 COMPAT_12 { int sys_reboot(int opt); } oreboot 1581.46Scgd56 STD { int sys_revoke(const char *path); } 1591.46Scgd57 STD { int sys_symlink(const char *path, \ 1601.46Scgd const char *link); } 1611.142Skleink58 STD { ssize_t sys_readlink(const char *path, char *buf, \ 1621.72Skleink size_t count); } 1631.46Scgd59 STD { int sys_execve(const char *path, \ 1641.46Scgd char * const *argp, char * const *envp); } 1651.62Smycroft60 STD { mode_t sys_umask(mode_t newmask); } 1661.46Scgd61 STD { int sys_chroot(const char *path); } 1671.60Schristos62 COMPAT_43 { int sys_fstat(int fd, struct stat43 *sb); } fstat43 1681.28Smycroft63 COMPAT_43 { int sys_getkerninfo(int op, char *where, int *size, \ 1691.29Smycroft int arg); } ogetkerninfo 1701.29Smycroft64 COMPAT_43 { int sys_getpagesize(void); } ogetpagesize 1711.167Schristos65 COMPAT_12 { int sys_msync(void *addr, size_t len); } 1721.67Sthorpej; XXX COMPAT_??? for 4.4BSD-compatible vfork(2)? 1731.28Smycroft66 STD { int sys_vfork(void); } 1741.23Scgd67 OBSOL vread 1751.23Scgd68 OBSOL vwrite 1761.95Skleink69 STD { int sys_sbrk(intptr_t incr); } 1771.28Smycroft70 STD { int sys_sstk(int incr); } 1781.167Schristos71 COMPAT_43 { int sys_mmap(void *addr, size_t len, int prot, \ 1791.29Smycroft int flags, int fd, long pos); } ommap 1801.28Smycroft72 STD { int sys_ovadvise(int anom); } vadvise 1811.61Schristos73 STD { int sys_munmap(void *addr, size_t len); } 1821.61Schristos74 STD { int sys_mprotect(void *addr, size_t len, \ 1831.28Smycroft int prot); } 1841.61Schristos75 STD { int sys_madvise(void *addr, size_t len, \ 1851.28Smycroft int behav); } 1861.23Scgd76 OBSOL vhangup 1871.23Scgd77 OBSOL vlimit 1881.91Sthorpej78 STD { int sys_mincore(void *addr, size_t len, \ 1891.28Smycroft char *vec); } 1901.163Sad79 STD MPSAFE { int sys_getgroups(int gidsetsize, \ 1911.59Smycroft gid_t *gidset); } 1921.64Sthorpej80 STD { int sys_setgroups(int gidsetsize, \ 1931.46Scgd const gid_t *gidset); } 1941.163Sad81 STD MPSAFE { int sys_getpgrp(void); } 1951.163Sad82 STD { int sys_setpgid(int pid, int pgid); } 1961.58Smycroft83 STD { int sys_setitimer(int which, \ 1971.46Scgd const struct itimerval *itv, \ 1981.46Scgd struct itimerval *oitv); } 1991.174Sad84 COMPAT_43 { int sys_wait(void); } owait 2001.52Smrg85 COMPAT_12 { int sys_swapon(const char *name); } oswapon 2011.58Smycroft86 STD { int sys_getitimer(int which, \ 2021.28Smycroft struct itimerval *itv); } 2031.29Smycroft87 COMPAT_43 { int sys_gethostname(char *hostname, u_int len); } \ 2041.29Smycroft ogethostname 2051.29Smycroft88 COMPAT_43 { int sys_sethostname(char *hostname, u_int len); } \ 2061.29Smycroft osethostname 2071.29Smycroft89 COMPAT_43 { int sys_getdtablesize(void); } ogetdtablesize 2081.59Smycroft90 STD { int sys_dup2(int from, int to); } 2091.23Scgd91 UNIMPL getdopt 2101.44Scgd92 STD { int sys_fcntl(int fd, int cmd, ... void *arg); } 2111.64Sthorpej93 STD { int sys_select(int nd, fd_set *in, fd_set *ou, \ 2121.23Scgd fd_set *ex, struct timeval *tv); } 2131.23Scgd94 UNIMPL setdopt 2141.28Smycroft95 STD { int sys_fsync(int fd); } 2151.176Sad96 STD MPSAFE { int sys_setpriority(int which, id_t who, int prio); } 2161.154Smrg97 COMPAT_30 { int sys_socket(int domain, int type, int protocol); } 2171.46Scgd98 STD { int sys_connect(int s, const struct sockaddr *name, \ 2181.88Skleink unsigned int namelen); } 2191.167Schristos99 COMPAT_43 { int sys_accept(int s, void *name, \ 2201.46Scgd int *anamelen); } oaccept 2211.163Sad100 STD MPSAFE { int sys_getpriority(int which, id_t who); } 2221.167Schristos101 COMPAT_43 { int sys_send(int s, void *buf, int len, \ 2231.29Smycroft int flags); } osend 2241.167Schristos102 COMPAT_43 { int sys_recv(int s, void *buf, int len, \ 2251.29Smycroft int flags); } orecv 2261.163Sad103 COMPAT_13 MPSAFE { int sys_sigreturn(struct sigcontext13 *sigcntxp); } \ 2271.83Smycroft sigreturn13 2281.46Scgd104 STD { int sys_bind(int s, const struct sockaddr *name, \ 2291.88Skleink unsigned int namelen); } 2301.28Smycroft105 STD { int sys_setsockopt(int s, int level, int name, \ 2311.88Skleink const void *val, unsigned int valsize); } 2321.28Smycroft106 STD { int sys_listen(int s, int backlog); } 2331.23Scgd107 OBSOL vtimes 2341.163Sad108 COMPAT_43 MPSAFE { int sys_sigvec(int signum, struct sigvec *nsv, \ 2351.29Smycroft struct sigvec *osv); } osigvec 2361.163Sad109 COMPAT_43 MPSAFE { int sys_sigblock(int mask); } osigblock 2371.163Sad110 COMPAT_43 MPSAFE { int sys_sigsetmask(int mask); } osigsetmask 2381.163Sad111 COMPAT_13 MPSAFE { int sys_sigsuspend(int mask); } sigsuspend13 2391.163Sad112 COMPAT_43 MPSAFE { int sys_sigstack(struct sigstack *nss, \ 2401.29Smycroft struct sigstack *oss); } osigstack 2411.28Smycroft113 COMPAT_43 { int sys_recvmsg(int s, struct omsghdr *msg, \ 2421.29Smycroft int flags); } orecvmsg 2431.167Schristos114 COMPAT_43 { int sys_sendmsg(int s, void *msg, int flags); } \ 2441.29Smycroft osendmsg 2451.23Scgd115 OBSOL vtrace 2461.173Sad116 STD MPSAFE { int sys_gettimeofday(struct timeval *tp, \ 2471.141Skleink void *tzp); } 2481.176Sad117 STD MPSAFE { int sys_getrusage(int who, struct rusage *rusage); } 2491.28Smycroft118 STD { int sys_getsockopt(int s, int level, int name, \ 2501.88Skleink void *val, unsigned int *avalsize); } 2511.26Scgd119 OBSOL resuba 2521.58Smycroft120 STD { ssize_t sys_readv(int fd, \ 2531.58Smycroft const struct iovec *iovp, int iovcnt); } 2541.46Scgd121 STD { ssize_t sys_writev(int fd, \ 2551.58Smycroft const struct iovec *iovp, int iovcnt); } 2561.46Scgd122 STD { int sys_settimeofday(const struct timeval *tv, \ 2571.141Skleink const void *tzp); } 2581.46Scgd123 STD { int sys_fchown(int fd, uid_t uid, gid_t gid); } 2591.60Schristos124 STD { int sys_fchmod(int fd, mode_t mode); } 2601.167Schristos125 COMPAT_43 { int sys_recvfrom(int s, void *buf, size_t len, \ 2611.167Schristos int flags, void *from, int *fromlenaddr); } \ 2621.29Smycroft orecvfrom 2631.46Scgd126 STD { int sys_setreuid(uid_t ruid, uid_t euid); } 2641.46Scgd127 STD { int sys_setregid(gid_t rgid, gid_t egid); } 2651.46Scgd128 STD { int sys_rename(const char *from, const char *to); } 2661.60Schristos129 COMPAT_43 { int sys_truncate(const char *path, long length); } \ 2671.29Smycroft otruncate 2681.29Smycroft130 COMPAT_43 { int sys_ftruncate(int fd, long length); } oftruncate 2691.28Smycroft131 STD { int sys_flock(int fd, int how); } 2701.60Schristos132 STD { int sys_mkfifo(const char *path, mode_t mode); } 2711.46Scgd133 STD { ssize_t sys_sendto(int s, const void *buf, \ 2721.46Scgd size_t len, int flags, const struct sockaddr *to, \ 2731.88Skleink unsigned int tolen); } 2741.28Smycroft134 STD { int sys_shutdown(int s, int how); } 2751.28Smycroft135 STD { int sys_socketpair(int domain, int type, \ 2761.28Smycroft int protocol, int *rsv); } 2771.60Schristos136 STD { int sys_mkdir(const char *path, mode_t mode); } 2781.46Scgd137 STD { int sys_rmdir(const char *path); } 2791.46Scgd138 STD { int sys_utimes(const char *path, \ 2801.46Scgd const struct timeval *tptr); } 2811.23Scgd139 OBSOL 4.2 sigreturn 2821.46Scgd140 STD { int sys_adjtime(const struct timeval *delta, \ 2831.23Scgd struct timeval *olddelta); } 2841.167Schristos141 COMPAT_43 { int sys_getpeername(int fdes, void *asa, \ 2851.29Smycroft int *alen); } ogetpeername 2861.29Smycroft142 COMPAT_43 { int32_t sys_gethostid(void); } ogethostid 2871.29Smycroft143 COMPAT_43 { int sys_sethostid(int32_t hostid); } osethostid 2881.176Sad144 COMPAT_43 MPSAFE { int sys_getrlimit(int which, \ 2891.58Smycroft struct orlimit *rlp); } ogetrlimit 2901.58Smycroft145 COMPAT_43 { int sys_setrlimit(int which, \ 2911.58Smycroft const struct orlimit *rlp); } osetrlimit 2921.29Smycroft146 COMPAT_43 { int sys_killpg(int pgid, int signum); } okillpg 2931.163Sad147 STD { int sys_setsid(void); } 2941.46Scgd148 STD { int sys_quotactl(const char *path, int cmd, \ 2951.167Schristos int uid, void *arg); } 2961.29Smycroft149 COMPAT_43 { int sys_quota(void); } oquota 2971.167Schristos150 COMPAT_43 { int sys_getsockname(int fdec, void *asa, \ 2981.29Smycroft int *alen); } ogetsockname 2991.1Sglass 3001.1Sglass; Syscalls 151-180 inclusive are reserved for vendor-specific 3011.1Sglass; system calls. (This includes various calls added for compatibity 3021.1Sglass; with other Unix variants.) 3031.1Sglass; Some of these calls are now supported by BSD... 3041.23Scgd151 UNIMPL 3051.23Scgd152 UNIMPL 3061.23Scgd153 UNIMPL 3071.23Scgd154 UNIMPL 3081.92Schristos#if defined(NFS) || defined(NFSSERVER) || !defined(_KERNEL) 3091.46Scgd155 STD { int sys_nfssvc(int flag, void *argp); } 3101.1Sglass#else 3111.92Schristos155 EXCL nfssvc 3121.1Sglass#endif 3131.28Smycroft156 COMPAT_43 { int sys_getdirentries(int fd, char *buf, \ 3141.29Smycroft u_int count, long *basep); } ogetdirentries 3151.139Schristos157 COMPAT_20 { int sys_statfs(const char *path, \ 3161.139Schristos struct statfs12 *buf); } 3171.139Schristos158 COMPAT_20 { int sys_fstatfs(int fd, struct statfs12 *buf); } 3181.23Scgd159 UNIMPL 3191.23Scgd160 UNIMPL 3201.155Smartin161 COMPAT_30 { int sys_getfh(const char *fname, \ 3211.155Smartin struct compat_30_fhandle *fhp); } 3221.29Smycroft162 COMPAT_09 { int sys_getdomainname(char *domainname, int len); } \ 3231.29Smycroft ogetdomainname 3241.29Smycroft163 COMPAT_09 { int sys_setdomainname(char *domainname, int len); } \ 3251.29Smycroft osetdomainname 3261.29Smycroft164 COMPAT_09 { int sys_uname(struct outsname *name); } ouname 3271.71Sperry165 STD { int sys_sysarch(int op, void *parms); } 3281.23Scgd166 UNIMPL 3291.23Scgd167 UNIMPL 3301.23Scgd168 UNIMPL 3311.23Scgd; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 3321.111Seeh#if (defined(SYSVSEM) || !defined(_KERNEL)) && !defined(_LP64) 3331.172Sad169 COMPAT_10 MPSAFE { int sys_semsys(int which, int a2, int a3, int a4, \ 3341.29Smycroft int a5); } osemsys 3351.9Scgd#else 3361.92Schristos169 EXCL 1.0 semsys 3371.9Scgd#endif 3381.23Scgd; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 3391.111Seeh#if (defined(SYSVMSG) || !defined(_KERNEL)) && !defined(_LP64) 3401.28Smycroft170 COMPAT_10 { int sys_msgsys(int which, int a2, int a3, int a4, \ 3411.29Smycroft int a5, int a6); } omsgsys 3421.9Scgd#else 3431.92Schristos170 EXCL 1.0 msgsys 3441.9Scgd#endif 3451.23Scgd; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 3461.111Seeh#if (defined(SYSVSHM) || !defined(_KERNEL)) && !defined(_LP64) 3471.29Smycroft171 COMPAT_10 { int sys_shmsys(int which, int a2, int a3, int a4); } \ 3481.29Smycroft oshmsys 3491.1Sglass#else 3501.92Schristos171 EXCL 1.0 shmsys 3511.1Sglass#endif 3521.23Scgd172 UNIMPL 3531.79Sthorpej173 STD { ssize_t sys_pread(int fd, void *buf, \ 3541.80Sthorpej size_t nbyte, int pad, off_t offset); } 3551.79Sthorpej174 STD { ssize_t sys_pwrite(int fd, const void *buf, \ 3561.80Sthorpej size_t nbyte, int pad, off_t offset); } 3571.102Sbjh21; For some reason, ntp_gettime doesn't want to raise SIGSYS when it's excluded. 3581.153Sdrochner175 COMPAT_30 { int sys_ntp_gettime(struct ntptimeval30 *ntvp); } 3591.102Sbjh21#if defined(NTP) || !defined(_KERNEL) 3601.38Sthorpej176 STD { int sys_ntp_adjtime(struct timex *tp); } 3611.102Sbjh21#else 3621.102Sbjh21176 EXCL ntp_adjtime 3631.102Sbjh21#endif 3641.23Scgd177 UNIMPL 3651.23Scgd178 UNIMPL 3661.23Scgd179 UNIMPL 3671.23Scgd180 UNIMPL 3681.1Sglass 3691.1Sglass; Syscalls 180-199 are used by/reserved for BSD 3701.28Smycroft181 STD { int sys_setgid(gid_t gid); } 3711.163Sad182 STD { int sys_setegid(gid_t egid); } 3721.28Smycroft183 STD { int sys_seteuid(uid_t euid); } 3731.92Schristos#if defined(LFS) || !defined(_KERNEL) 3741.92Schristos184 STD { int sys_lfs_bmapv(fsid_t *fsidp, \ 3751.23Scgd struct block_info *blkiov, int blkcnt); } 3761.92Schristos185 STD { int sys_lfs_markv(fsid_t *fsidp, \ 3771.23Scgd struct block_info *blkiov, int blkcnt); } 3781.92Schristos186 STD { int sys_lfs_segclean(fsid_t *fsidp, u_long segment); } 3791.92Schristos187 STD { int sys_lfs_segwait(fsid_t *fsidp, \ 3801.92Schristos struct timeval *tv); } 3811.92Schristos#else 3821.92Schristos184 EXCL lfs_bmapv 3831.92Schristos185 EXCL lfs_markv 3841.92Schristos186 EXCL lfs_segclean 3851.92Schristos187 EXCL lfs_segwait 3861.23Scgd#endif 3871.60Schristos188 COMPAT_12 { int sys_stat(const char *path, struct stat12 *ub); } \ 3881.60Schristos stat12 3891.60Schristos189 COMPAT_12 { int sys_fstat(int fd, struct stat12 *sb); } fstat12 3901.60Schristos190 COMPAT_12 { int sys_lstat(const char *path, \ 3911.60Schristos struct stat12 *ub); } lstat12 3921.46Scgd191 STD { long sys_pathconf(const char *path, int name); } 3931.44Scgd192 STD { long sys_fpathconf(int fd, int name); } 3941.23Scgd193 UNIMPL 3951.58Smycroft194 STD { int sys_getrlimit(int which, \ 3961.58Smycroft struct rlimit *rlp); } 3971.58Smycroft195 STD { int sys_setrlimit(int which, \ 3981.46Scgd const struct rlimit *rlp); } 3991.57Sfvdl196 COMPAT_12 { int sys_getdirentries(int fd, char *buf, \ 4001.28Smycroft u_int count, long *basep); } 4011.61Schristos197 STD { void *sys_mmap(void *addr, size_t len, int prot, \ 4021.23Scgd int flags, int fd, long pad, off_t pos); } 4031.43Scgd198 INDIR { quad_t sys___syscall(quad_t num, ...); } 4041.28Smycroft199 STD { off_t sys_lseek(int fd, int pad, off_t offset, \ 4051.23Scgd int whence); } 4061.46Scgd200 STD { int sys_truncate(const char *path, int pad, \ 4071.46Scgd off_t length); } 4081.28Smycroft201 STD { int sys_ftruncate(int fd, int pad, off_t length); } 4091.151Sdrochner202 STD { int sys___sysctl(const int *name, u_int namelen, \ 4101.151Sdrochner void *old, size_t *oldlenp, const void *new, \ 4111.28Smycroft size_t newlen); } 4121.75Skleink203 STD { int sys_mlock(const void *addr, size_t len); } 4131.75Skleink204 STD { int sys_munlock(const void *addr, size_t len); } 4141.46Scgd205 STD { int sys_undelete(const char *path); } 4151.46Scgd206 STD { int sys_futimes(int fd, \ 4161.46Scgd const struct timeval *tptr); } 4171.163Sad207 STD MPSAFE { pid_t sys_getpgid(pid_t pid); } 4181.34Smrg208 STD { int sys_reboot(int opt, char *bootstr); } 4191.36Smycroft209 STD { int sys_poll(struct pollfd *fds, u_int nfds, \ 4201.35Smycroft int timeout); } 4211.11Scgd; 4221.11Scgd; Syscalls 210-219 are reserved for dynamically loaded syscalls 4231.11Scgd; 4241.92Schristos#if defined(LKM) || !defined(_KERNEL) 4251.28Smycroft210 NODEF { int sys_lkmnosys(void); } 4261.28Smycroft211 NODEF { int sys_lkmnosys(void); } 4271.28Smycroft212 NODEF { int sys_lkmnosys(void); } 4281.28Smycroft213 NODEF { int sys_lkmnosys(void); } 4291.28Smycroft214 NODEF { int sys_lkmnosys(void); } 4301.28Smycroft215 NODEF { int sys_lkmnosys(void); } 4311.28Smycroft216 NODEF { int sys_lkmnosys(void); } 4321.28Smycroft217 NODEF { int sys_lkmnosys(void); } 4331.28Smycroft218 NODEF { int sys_lkmnosys(void); } 4341.28Smycroft219 NODEF { int sys_lkmnosys(void); } 4351.11Scgd#else /* !LKM */ 4361.92Schristos210 EXCL lkmnosys 4371.92Schristos211 EXCL lkmnosys 4381.92Schristos212 EXCL lkmnosys 4391.92Schristos213 EXCL lkmnosys 4401.92Schristos214 EXCL lkmnosys 4411.92Schristos215 EXCL lkmnosys 4421.92Schristos216 EXCL lkmnosys 4431.92Schristos217 EXCL lkmnosys 4441.92Schristos218 EXCL lkmnosys 4451.92Schristos219 EXCL lkmnosys 4461.6Scgd#endif /* !LKM */ 4471.49Skleink; System calls 220-300 are reserved for use by NetBSD 4481.92Schristos#if defined(SYSVSEM) || !defined(_KERNEL) 4491.172Sad220 COMPAT_14 MPSAFE { int sys___semctl(int semid, int semnum, int cmd, \ 4501.97Sthorpej union __semun *arg); } 4511.172Sad221 STD MPSAFE { int sys_semget(key_t key, int nsems, int semflg); } 4521.172Sad222 STD MPSAFE { int sys_semop(int semid, struct sembuf *sops, \ 4531.74Skleink size_t nsops); } 4541.172Sad223 STD MPSAFE { int sys_semconfig(int flag); } 4551.23Scgd#else 4561.97Sthorpej220 EXCL compat_14_semctl 4571.92Schristos221 EXCL semget 4581.92Schristos222 EXCL semop 4591.92Schristos223 EXCL semconfig 4601.23Scgd#endif 4611.92Schristos#if defined(SYSVMSG) || !defined(_KERNEL) 4621.163Sad224 COMPAT_14 MPSAFE { int sys_msgctl(int msqid, int cmd, \ 4631.97Sthorpej struct msqid_ds14 *buf); } 4641.163Sad225 STD MPSAFE { int sys_msgget(key_t key, int msgflg); } 4651.163Sad226 STD MPSAFE { int sys_msgsnd(int msqid, const void *msgp, \ 4661.74Skleink size_t msgsz, int msgflg); } 4671.163Sad227 STD MPSAFE { ssize_t sys_msgrcv(int msqid, void *msgp, \ 4681.74Skleink size_t msgsz, long msgtyp, int msgflg); } 4691.23Scgd#else 4701.163Sad224 EXCL compat_14_msgctl 4711.163Sad225 EXCL msgget 4721.163Sad226 EXCL msgsnd 4731.163Sad227 EXCL msgrcv 4741.23Scgd#endif 4751.92Schristos#if defined(SYSVSHM) || !defined(_KERNEL) 4761.74Skleink228 STD { void *sys_shmat(int shmid, const void *shmaddr, \ 4771.44Scgd int shmflg); } 4781.97Sthorpej229 COMPAT_14 { int sys_shmctl(int shmid, int cmd, \ 4791.97Sthorpej struct shmid_ds14 *buf); } 4801.74Skleink230 STD { int sys_shmdt(const void *shmaddr); } 4811.74Skleink231 STD { int sys_shmget(key_t key, size_t size, int shmflg); } 4821.23Scgd#else 4831.92Schristos228 EXCL shmat 4841.97Sthorpej229 EXCL compat_14_shmctl 4851.92Schristos230 EXCL shmdt 4861.92Schristos231 EXCL shmget 4871.23Scgd#endif 4881.175Sad232 STD MPSAFE { int sys_clock_gettime(clockid_t clock_id, \ 4891.49Skleink struct timespec *tp); } 4901.39Sjtc233 STD { int sys_clock_settime(clockid_t clock_id, \ 4911.49Skleink const struct timespec *tp); } 4921.175Sad234 STD MPSAFE { int sys_clock_getres(clockid_t clock_id, \ 4931.49Skleink struct timespec *tp); } 4941.118Sthorpej235 STD { int sys_timer_create(clockid_t clock_id, \ 4951.118Sthorpej struct sigevent *evp, timer_t *timerid); } 4961.118Sthorpej236 STD { int sys_timer_delete(timer_t timerid); } 4971.118Sthorpej237 STD { int sys_timer_settime(timer_t timerid, int flags, \ 4981.118Sthorpej const struct itimerspec *value, \ 4991.118Sthorpej struct itimerspec *ovalue); } 5001.118Sthorpej238 STD { int sys_timer_gettime(timer_t timerid, struct \ 5011.118Sthorpej itimerspec *value); } 5021.118Sthorpej239 STD { int sys_timer_getoverrun(timer_t timerid); } 5031.54Sveego; 5041.54Sveego; Syscalls 240-269 are reserved for other IEEE Std1003.1b syscalls 5051.54Sveego; 5061.163Sad240 STD MPSAFE { int sys_nanosleep(const struct timespec *rqtp, \ 5071.49Skleink struct timespec *rmtp); } 5081.76Skleink241 STD { int sys_fdatasync(int fd); } 5091.93Sthorpej242 STD { int sys_mlockall(int flags); } 5101.93Sthorpej243 STD { int sys_munlockall(void); } 5111.163Sad244 STD MPSAFE { int sys___sigtimedwait(const sigset_t *set, \ 5121.127Sjdolecek siginfo_t *info, \ 5131.127Sjdolecek struct timespec *timeout); } 5141.127Sjdolecek245 UNIMPL sys_sigqueue 5151.127Sjdolecek; 5161.127Sjdolecek; Syscall 246 is free for any use 5171.127Sjdolecek; 5181.127Sjdolecek246 UNIMPL 5191.133Schristos#if defined(P1003_1B_SEMAPHORE) || (!defined(_KERNEL) && defined(_LIBC)) 5201.122Schristos247 STD { int sys__ksem_init(unsigned int value, semid_t *idp); } 5211.122Schristos248 STD { int sys__ksem_open(const char *name, int oflag, \ 5221.119Schristos mode_t mode, unsigned int value, semid_t *idp); } 5231.122Schristos249 STD { int sys__ksem_unlink(const char *name); } 5241.122Schristos250 STD { int sys__ksem_close(semid_t id); } 5251.163Sad251 STD { int sys__ksem_post(semid_t id); } 5261.163Sad252 STD { int sys__ksem_wait(semid_t id); } 5271.163Sad253 STD { int sys__ksem_trywait(semid_t id); } 5281.163Sad254 STD { int sys__ksem_getvalue(semid_t id, \ 5291.119Schristos unsigned int *value); } 5301.122Schristos255 STD { int sys__ksem_destroy(semid_t id); } 5311.124Sthorpej256 UNIMPL sys__ksem_timedwait 5321.119Schristos#else 5331.122Schristos247 EXCL sys__ksem_init 5341.122Schristos248 EXCL sys__ksem_open 5351.122Schristos249 EXCL sys__ksem_unlink 5361.122Schristos250 EXCL sys__ksem_close 5371.122Schristos251 EXCL sys__ksem_post 5381.122Schristos252 EXCL sys__ksem_wait 5391.122Schristos253 EXCL sys__ksem_trywait 5401.122Schristos254 EXCL sys__ksem_getvalue 5411.122Schristos255 EXCL sys__ksem_destroy 5421.124Sthorpej256 UNIMPL sys__ksem_timedwait 5431.119Schristos#endif 5441.177Srmind257 STD { mqd_t sys_mq_open(const char * name, int oflag, \ 5451.177Srmind mode_t mode, struct mq_attr *attr); } 5461.177Srmind258 STD { int sys_mq_close(mqd_t mqdes); } 5471.177Srmind259 STD { int sys_mq_unlink(const char *name); } 5481.177Srmind260 STD { int sys_mq_getattr(mqd_t mqdes, \ 5491.177Srmind struct mq_attr *mqstat); } 5501.177Srmind261 STD { int sys_mq_setattr(mqd_t mqdes, \ 5511.177Srmind const struct mq_attr *mqstat, \ 5521.177Srmind struct mq_attr *omqstat); } 5531.177Srmind262 STD { int sys_mq_notify(mqd_t mqdes, \ 5541.177Srmind const struct sigevent *notification); } 5551.177Srmind263 STD { int sys_mq_send(mqd_t mqdes, const char *msg_ptr, \ 5561.177Srmind size_t msg_len, unsigned msg_prio); } 5571.177Srmind264 STD { ssize_t sys_mq_receive(mqd_t mqdes, char *msg_ptr, \ 5581.177Srmind size_t msg_len, unsigned *msg_prio); } 5591.177Srmind265 STD { int sys_mq_timedsend(mqd_t mqdes, \ 5601.177Srmind const char *msg_ptr, size_t msg_len, \ 5611.177Srmind unsigned msg_prio, \ 5621.177Srmind const struct timespec *abs_timeout); } 5631.177Srmind266 STD { ssize_t sys_mq_timedreceive(mqd_t mqdes, \ 5641.177Srmind char *msg_ptr, size_t msg_len, unsigned *msg_prio, \ 5651.177Srmind const struct timespec *abs_timeout); } 5661.49Skleink267 UNIMPL 5671.49Skleink268 UNIMPL 5681.49Skleink269 UNIMPL 5691.69Skleink270 STD { int sys___posix_rename(const char *from, \ 5701.49Skleink const char *to); } 5711.146Schristos271 STD { int sys_swapctl(int cmd, void *arg, int misc); } 5721.148Schristos272 COMPAT_30 { int sys_getdents(int fd, char *buf, size_t count); } 5731.61Schristos273 STD { int sys_minherit(void *addr, size_t len, \ 5741.54Sveego int inherit); } 5751.60Schristos274 STD { int sys_lchmod(const char *path, mode_t mode); } 5761.56Senami275 STD { int sys_lchown(const char *path, uid_t uid, \ 5771.56Senami gid_t gid); } 5781.56Senami276 STD { int sys_lutimes(const char *path, \ 5791.56Senami const struct timeval *tptr); } 5801.63Sthorpej277 STD { int sys___msync13(void *addr, size_t len, int flags); } 5811.152Schristos278 COMPAT_30 { int sys___stat13(const char *path, struct stat13 *ub); } 5821.152Schristos279 COMPAT_30 { int sys___fstat13(int fd, struct stat13 *sb); } 5831.152Schristos280 COMPAT_30 { int sys___lstat13(const char *path, struct stat13 *ub); } 5841.163Sad281 STD MPSAFE { int sys___sigaltstack14( \ 5851.82Smycroft const struct sigaltstack *nss, \ 5861.82Smycroft struct sigaltstack *oss); } 5871.67Sthorpej282 STD { int sys___vfork14(void); } 5881.69Skleink283 STD { int sys___posix_chown(const char *path, uid_t uid, \ 5891.69Skleink gid_t gid); } 5901.69Skleink284 STD { int sys___posix_fchown(int fd, uid_t uid, \ 5911.69Skleink gid_t gid); } 5921.69Skleink285 STD { int sys___posix_lchown(const char *path, uid_t uid, \ 5931.69Skleink gid_t gid); } 5941.163Sad286 STD MPSAFE { pid_t sys_getsid(pid_t pid); } 5951.110Sthorpej287 STD { pid_t sys___clone(int flags, void *stack); } 5961.73Schristos288 STD { int sys_fktrace(const int fd, int ops, \ 5971.73Schristos int facs, int pid); } 5981.79Sthorpej289 STD { ssize_t sys_preadv(int fd, \ 5991.79Sthorpej const struct iovec *iovp, int iovcnt, \ 6001.80Sthorpej int pad, off_t offset); } 6011.79Sthorpej290 STD { ssize_t sys_pwritev(int fd, \ 6021.79Sthorpej const struct iovec *iovp, int iovcnt, \ 6031.80Sthorpej int pad, off_t offset); } 6041.163Sad291 COMPAT_16 MPSAFE { int sys___sigaction14(int signum, \ 6051.82Smycroft const struct sigaction *nsa, \ 6061.82Smycroft struct sigaction *osa); } 6071.163Sad292 STD MPSAFE { int sys___sigpending14(sigset_t *set); } 6081.163Sad293 STD MPSAFE { int sys___sigprocmask14(int how, \ 6091.82Smycroft const sigset_t *set, \ 6101.82Smycroft sigset_t *oset); } 6111.163Sad294 STD MPSAFE { int sys___sigsuspend14(const sigset_t *set); } 6121.163Sad295 COMPAT_16 MPSAFE { int sys___sigreturn14(struct sigcontext *sigcntxp); } 6131.89Ssommerfe296 STD { int sys___getcwd(char *bufp, size_t length); } 6141.89Ssommerfe297 STD { int sys_fchroot(int fd); } 6151.156Smartin298 COMPAT_30 { int sys_fhopen(const struct compat_30_fhandle *fhp, int flags); } 6161.156Smartin299 COMPAT_30 { int sys_fhstat(const struct compat_30_fhandle *fhp, \ 6171.152Schristos struct stat13 *sb); } 6181.156Smartin300 COMPAT_20 { int sys_fhstatfs(const struct compat_30_fhandle *fhp, \ 6191.139Schristos struct statfs12 *buf); } 6201.97Sthorpej#if defined(SYSVSEM) || !defined(_KERNEL) 6211.172Sad301 STD MPSAFE { int sys_____semctl13(int semid, int semnum, int cmd, \ 6221.99Schristos ... union __semun *arg); } 6231.97Sthorpej#else 6241.99Schristos301 EXCL ____semctl13 6251.97Sthorpej#endif 6261.97Sthorpej#if defined(SYSVMSG) || !defined(_KERNEL) 6271.163Sad302 STD MPSAFE { int sys___msgctl13(int msqid, int cmd, \ 6281.97Sthorpej struct msqid_ds *buf); } 6291.97Sthorpej#else 6301.97Sthorpej302 EXCL __msgctl13 6311.97Sthorpej#endif 6321.97Sthorpej#if defined(SYSVSHM) || !defined(_KERNEL) 6331.163Sad303 STD { int sys___shmctl13(int shmid, int cmd, \ 6341.97Sthorpej struct shmid_ds *buf); } 6351.97Sthorpej#else 6361.97Sthorpej303 EXCL __shmctl13 6371.97Sthorpej#endif 6381.100Smrg304 STD { int sys_lchflags(const char *path, u_long flags); } 6391.163Sad305 STD MPSAFE { int sys_issetugid(void); } 6401.163Sad306 STD MPSAFE { int sys_utrace(const char *label, void *addr, \ 6411.118Sthorpej size_t len); } 6421.176Sad307 STD MPSAFE { int sys_getcontext(struct __ucontext *ucp); } 6431.176Sad308 STD MPSAFE { int sys_setcontext(const struct __ucontext *ucp); } 6441.118Sthorpej309 STD { int sys__lwp_create(const struct __ucontext *ucp, \ 6451.118Sthorpej u_long flags, lwpid_t *new_lwp); } 6461.118Sthorpej310 STD { int sys__lwp_exit(void); } 6471.163Sad311 STD MPSAFE { lwpid_t sys__lwp_self(void); } 6481.163Sad312 STD MPSAFE { int sys__lwp_wait(lwpid_t wait_for, \ 6491.118Sthorpej lwpid_t *departed); } 6501.163Sad313 STD MPSAFE { int sys__lwp_suspend(lwpid_t target); } 6511.163Sad314 STD MPSAFE { int sys__lwp_continue(lwpid_t target); } 6521.163Sad315 STD MPSAFE { int sys__lwp_wakeup(lwpid_t target); } 6531.163Sad316 STD MPSAFE { void *sys__lwp_getprivate(void); } 6541.163Sad317 STD MPSAFE { void sys__lwp_setprivate(void *ptr); } 6551.161Sad318 STD { int sys__lwp_kill(lwpid_t target, int signo); } 6561.163Sad319 STD MPSAFE { int sys__lwp_detach(lwpid_t target); } 6571.163Sad320 STD MPSAFE { int sys__lwp_park(const struct timespec *ts, \ 6581.175Sad lwpid_t unpark, const void *hint, \ 6591.175Sad const void *unparkhint); } 6601.164Sad321 STD MPSAFE { int sys__lwp_unpark(lwpid_t target, const void *hint); } 6611.166Sdrochner322 STD MPSAFE { ssize_t sys__lwp_unpark_all(const lwpid_t *targets, \ 6621.164Sad size_t ntargets, const void *hint); } 6631.178Sad323 STD { int sys__lwp_setname(lwpid_t target, \ 6641.178Sad const char *name); } 6651.178Sad324 STD { int sys__lwp_getname(lwpid_t target, \ 6661.178Sad char *name, size_t len); } 6671.178Sad; Syscalls 325-339 reserved for LWP syscalls. 6681.107Snathanw325 UNIMPL 6691.107Snathanw326 UNIMPL 6701.107Snathanw327 UNIMPL 6711.107Snathanw328 UNIMPL 6721.107Snathanw329 UNIMPL 6731.165Sad; Obsolete SA system calls. Must remain until libc's major version is bumped. 6741.165Sad330 STD MPSAFE { int sys_sa_register(void); } 6751.165Sad331 STD MPSAFE { int sys_sa_stacks(void); } 6761.165Sad332 STD MPSAFE { int sys_sa_enable(void); } 6771.165Sad333 STD MPSAFE { int sys_sa_setconcurrency(void); } 6781.165Sad334 STD MPSAFE { int sys_sa_yield(void); } 6791.165Sad335 STD MPSAFE { int sys_sa_preempt(void); } 6801.165Sad336 STD MPSAFE { int sys_sa_unblockyield(void); } 6811.107Snathanw337 UNIMPL 6821.107Snathanw338 UNIMPL 6831.107Snathanw339 UNIMPL 6841.163Sad340 STD MPSAFE { int sys___sigaction_sigtramp(int signum, \ 6851.112Sthorpej const struct sigaction *nsa, \ 6861.112Sthorpej struct sigaction *osa, \ 6871.132Smatt const void *tramp, int vers); } 6881.113Sbriggs341 STD { int sys_pmc_get_info(int ctr, int op, void *args); } 6891.113Sbriggs342 STD { int sys_pmc_control(int ctr, int op, void *args); } 6901.167Schristos343 STD { int sys_rasctl(void *addr, size_t len, int op); } 6911.116Sjdolecek344 STD { int sys_kqueue(void); } 6921.116Sjdolecek345 STD { int sys_kevent(int fd, \ 6931.116Sjdolecek const struct kevent *changelist, size_t nchanges, \ 6941.116Sjdolecek struct kevent *eventlist, size_t nevents, \ 6951.116Sjdolecek const struct timespec *timeout); } 6961.126Sthorpej; 6971.126Sthorpej; Syscalls 346-353 are reserved for the IEEE Std1003.1b scheduling syscalls 6981.126Sthorpej; 6991.126Sthorpej346 UNIMPL sys_sched_setparam 7001.126Sthorpej347 UNIMPL sys_sched_getparam 7011.126Sthorpej348 UNIMPL sys_sched_setscheduler 7021.126Sthorpej349 UNIMPL sys_sched_getscheduler 7031.163Sad350 STD MPSAFE { int sys_sched_yield(void); } 7041.126Sthorpej351 UNIMPL sys_sched_get_priority_max 7051.126Sthorpej352 UNIMPL sys_sched_get_priority_min 7061.126Sthorpej353 UNIMPL sys_sched_rr_get_interval 7071.134Sthorpej 7081.134Sthorpej354 STD { int sys_fsync_range(int fd, int flags, off_t start, \ 7091.134Sthorpej off_t length); } 7101.136Stsarna355 STD { int sys_uuidgen(struct uuid *store, int count); } 7111.139Schristos356 STD { int sys_getvfsstat(struct statvfs *buf, \ 7121.139Schristos size_t bufsize, int flags); } 7131.139Schristos357 STD { int sys_statvfs1(const char *path, \ 7141.139Schristos struct statvfs *buf, int flags); } 7151.139Schristos358 STD { int sys_fstatvfs1(int fd, struct statvfs *buf, \ 7161.139Schristos int flags); } 7171.156Smartin359 COMPAT_30 { int sys_fhstatvfs1(const struct compat_30_fhandle *fhp, \ 7181.139Schristos struct statvfs *buf, int flags); } 7191.143Sthorpej360 STD { int sys_extattrctl(const char *path, int cmd, \ 7201.143Sthorpej const char *filename, int attrnamespace, \ 7211.143Sthorpej const char *attrname); } 7221.143Sthorpej361 STD { int sys_extattr_set_file(const char *path, \ 7231.143Sthorpej int attrnamespace, const char *attrname, \ 7241.143Sthorpej const void *data, size_t nbytes); } 7251.149Schristos362 STD { ssize_t sys_extattr_get_file(const char *path, \ 7261.143Sthorpej int attrnamespace, const char *attrname, \ 7271.143Sthorpej void *data, size_t nbytes); } 7281.143Sthorpej363 STD { int sys_extattr_delete_file(const char *path, \ 7291.143Sthorpej int attrnamespace, const char *attrname); } 7301.143Sthorpej364 STD { int sys_extattr_set_fd(int fd, \ 7311.143Sthorpej int attrnamespace, const char *attrname, \ 7321.143Sthorpej const void *data, size_t nbytes); } 7331.149Schristos365 STD { ssize_t sys_extattr_get_fd(int fd, \ 7341.143Sthorpej int attrnamespace, const char *attrname, \ 7351.143Sthorpej void *data, size_t nbytes); } 7361.143Sthorpej366 STD { int sys_extattr_delete_fd(int fd, \ 7371.143Sthorpej int attrnamespace, const char *attrname); } 7381.143Sthorpej367 STD { int sys_extattr_set_link(const char *path, \ 7391.143Sthorpej int attrnamespace, const char *attrname, \ 7401.143Sthorpej const void *data, size_t nbytes); } 7411.149Schristos368 STD { ssize_t sys_extattr_get_link(const char *path, \ 7421.143Sthorpej int attrnamespace, const char *attrname, \ 7431.143Sthorpej void *data, size_t nbytes); } 7441.143Sthorpej369 STD { int sys_extattr_delete_link(const char *path, \ 7451.143Sthorpej int attrnamespace, const char *attrname); } 7461.149Schristos370 STD { ssize_t sys_extattr_list_fd(int fd, \ 7471.143Sthorpej int attrnamespace, void *data, size_t nbytes); } 7481.149Schristos371 STD { ssize_t sys_extattr_list_file(const char *path, \ 7491.143Sthorpej int attrnamespace, void *data, size_t nbytes); } 7501.149Schristos372 STD { ssize_t sys_extattr_list_link(const char *path, \ 7511.143Sthorpej int attrnamespace, void *data, size_t nbytes); } 7521.145Smatt373 STD { int sys_pselect(int nd, fd_set *in, fd_set *ou, \ 7531.145Smatt fd_set *ex, const struct timespec *ts, \ 7541.145Smatt const sigset_t *mask); } 7551.145Smatt374 STD { int sys_pollts(struct pollfd *fds, u_int nfds, \ 7561.145Smatt const struct timespec *ts, const sigset_t *mask); } 7571.147Sthorpej375 STD { int sys_setxattr(const char *path, \ 7581.147Sthorpej const char *name, void *value, size_t size, \ 7591.147Sthorpej int flags); } 7601.147Sthorpej376 STD { int sys_lsetxattr(const char *path, \ 7611.147Sthorpej const char *name, void *value, size_t size, \ 7621.147Sthorpej int flags); } 7631.147Sthorpej377 STD { int sys_fsetxattr(int fd, \ 7641.147Sthorpej const char *name, void *value, size_t size, \ 7651.147Sthorpej int flags); } 7661.147Sthorpej378 STD { int sys_getxattr(const char *path, \ 7671.147Sthorpej const char *name, void *value, size_t size); } 7681.147Sthorpej379 STD { int sys_lgetxattr(const char *path, \ 7691.147Sthorpej const char *name, void *value, size_t size); } 7701.147Sthorpej380 STD { int sys_fgetxattr(int fd, \ 7711.147Sthorpej const char *name, void *value, size_t size); } 7721.147Sthorpej381 STD { int sys_listxattr(const char *path, \ 7731.147Sthorpej char *list, size_t size); } 7741.147Sthorpej382 STD { int sys_llistxattr(const char *path, \ 7751.147Sthorpej char *list, size_t size); } 7761.147Sthorpej383 STD { int sys_flistxattr(int fd, \ 7771.147Sthorpej char *list, size_t size); } 7781.147Sthorpej384 STD { int sys_removexattr(const char *path, \ 7791.147Sthorpej const char *name); } 7801.147Sthorpej385 STD { int sys_lremovexattr(const char *path, \ 7811.147Sthorpej const char *name); } 7821.147Sthorpej386 STD { int sys_fremovexattr(int fd, \ 7831.147Sthorpej const char *name); } 7841.148Schristos387 STD { int sys___stat30(const char *path, struct stat *ub); } 7851.148Schristos388 STD { int sys___fstat30(int fd, struct stat *sb); } 7861.148Schristos389 STD { int sys___lstat30(const char *path, struct stat *ub); } 7871.148Schristos390 STD { int sys___getdents30(int fd, char *buf, size_t count); } 7881.150Syamt391 STD { int sys_posix_fadvise(int fd, off_t offset, \ 7891.150Syamt off_t len, int advice); } 7901.156Smartin392 COMPAT_30 { int sys___fhstat30(const struct compat_30_fhandle \ 7911.156Smartin *fhp, struct stat *sb); } 7921.153Sdrochner393 STD { int sys___ntp_gettime30(struct ntptimeval *ntvp); } 7931.154Smrg394 STD { int sys___socket30(int domain, int type, int protocol); } 7941.156Smartin395 STD { int sys___getfh30(const char *fname, void *fhp, \ 7951.156Smartin size_t *fh_size); } 7961.156Smartin396 STD { int sys___fhopen40(const void *fhp, size_t fh_size,\ 7971.156Smartin int flags); } 7981.156Smartin397 STD { int sys___fhstatvfs140(const void *fhp, \ 7991.156Smartin size_t fh_size, struct statvfs *buf, int flags); } 8001.156Smartin398 STD { int sys___fhstat40(const void *fhp, \ 8011.156Smartin size_t fh_size, struct stat *sb); } 8021.169Srmind 8031.169Srmind; Asynchronous I/O system calls 8041.169Srmind399 STD { int sys_aio_cancel(int fildes, struct aiocb *aiocbp); } 8051.176Sad400 STD MPSAFE { int sys_aio_error(const struct aiocb *aiocbp); } 8061.169Srmind401 STD { int sys_aio_fsync(int op, struct aiocb *aiocbp); } 8071.169Srmind402 STD { int sys_aio_read(struct aiocb *aiocbp); } 8081.176Sad403 STD MPSAFE { int sys_aio_return(struct aiocb *aiocbp); } 8091.169Srmind404 STD { int sys_aio_suspend(const struct aiocb *const *list, \ 8101.169Srmind int nent, const struct timespec *timeout); } 8111.169Srmind405 STD { int sys_aio_write(struct aiocb *aiocbp); } 8121.169Srmind406 STD { int sys_lio_listio(int mode, struct aiocb *const *list, \ 8131.169Srmind int nent, struct sigevent *sig); } 8141.171Sjoerg 8151.170Sdsl407 UNIMPL 8161.170Sdsl408 UNIMPL 8171.170Sdsl409 UNIMPL 8181.170Sdsl 8191.170Sdsl410 STD { int sys___mount50(const char *type, \ 8201.170Sdsl const char *path, int flags, void *data, \ 8211.170Sdsl size_t data_len); } 8221.171Sjoerg411 STD { void *sys_mremap(void *old_address, size_t old_size, \ 8231.171Sjoerg void *new_address, size_t new_size, int flags); } 824