syscalls.master revision 1.49
11.49Schristos $NetBSD: syscalls.master,v 1.49 2005/09/13 01:42:32 christos Exp $ 21.1Smycroft 31.1Smycroft; from: @(#)syscalls.master 8.2 (Berkeley) 1/13/94 41.1Smycroft 51.1Smycroft; NetBSD COMPAT_FREEBSD system call name/number "master" file. 61.1Smycroft; (See syscalls.conf to see what it is processed into.) 71.1Smycroft; 81.1Smycroft; Fields: number type [type-dependent ...] 91.1Smycroft; number system call number, must be in order 101.1Smycroft; type one of STD, OBSOL, UNIMPL, NODEF, NOARGS, or one of 111.1Smycroft; the compatibility options defined in syscalls.conf. 121.1Smycroft; 131.1Smycroft; types: 141.1Smycroft; STD always included 151.1Smycroft; OBSOL obsolete, not included in system 161.1Smycroft; UNIMPL unimplemented, not included in system 171.1Smycroft; NODEF included, but don't define the syscall number 181.1Smycroft; NOARGS included, but don't define the syscall args structure 191.1Smycroft; 201.1Smycroft; The compat options are defined in the syscalls.conf file, and the 211.1Smycroft; compat option name is prefixed to the syscall name. Other than 221.1Smycroft; that, they're like NODEF (for 'compat' options), or STD (for 231.1Smycroft; 'libcompat' options). 241.1Smycroft; 251.1Smycroft; The type-dependent arguments are as follows: 261.1Smycroft; For STD, NODEF, NOARGS, and compat syscalls: 271.1Smycroft; { pseudo-proto } [alias] 281.1Smycroft; For other syscalls: 291.1Smycroft; [comment] 301.1Smycroft; 311.1Smycroft; #ifdef's, etc. may be included, and are copied to the output files. 321.15Sthorpej; #include's are copied to the syscall names and switch definition files only. 331.17Sthorpej 341.35Smrg#if defined(_KERNEL_OPT) 351.17Sthorpej#include "opt_ktrace.h" 361.18Sthorpej#include "opt_nfsserver.h" 371.29Sbjh21#include "opt_ntp.h" 381.20Stron#include "opt_sysv.h" 391.21Schristos#include "opt_compat_43.h" 401.42Sjdolecek#include "opt_posix.h" 411.15Sthorpej 421.15Sthorpej#include "fs_lfs.h" 431.15Sthorpej#include "fs_nfs.h" 441.32Smycroft#endif 451.1Smycroft 461.1Smycroft#include <sys/param.h> 471.1Smycroft#include <sys/systm.h> 481.1Smycroft#include <sys/signal.h> 491.1Smycroft#include <sys/mount.h> 501.40Sthorpej#include <sys/sa.h> 511.1Smycroft#include <sys/syscallargs.h> 521.1Smycroft 531.49Schristos#include <compat/sys/signal.h> 541.49Schristos 551.1Smycroft#include <compat/freebsd/freebsd_syscallargs.h> 561.1Smycroft 571.1Smycroft#include <machine/freebsd_machdep.h> 581.32Smycroft 591.32Smycroft%% 601.1Smycroft 611.1Smycroft; Reserved/unimplemented system calls in the range 0-150 inclusive 621.1Smycroft; are reserved for use in future Berkeley releases. 631.1Smycroft; Additional system calls implemented in vendor and other 641.1Smycroft; redistributions should be placed in the reserved range at the end 651.1Smycroft; of the current calls. 661.1Smycroft 671.1Smycroft0 NOARGS { int sys_nosys(void); } syscall 681.1Smycroft1 NOARGS { int sys_exit(int rval); } 691.1Smycroft2 NOARGS { int sys_fork(void); } 701.1Smycroft3 NOARGS { int sys_read(int fd, char *buf, u_int nbyte); } 711.1Smycroft4 NOARGS { int sys_write(int fd, char *buf, u_int nbyte); } 721.22Schristos5 STD { int freebsd_sys_open(const char *path, int flags, \ 731.1Smycroft int mode); } 741.1Smycroft6 NOARGS { int sys_close(int fd); } 751.1Smycroft7 NOARGS { int sys_wait4(int pid, int *status, int options, \ 761.1Smycroft struct rusage *rusage); } 771.22Schristos8 STD { int compat_43_freebsd_sys_creat(const char *path, \ 781.1Smycroft int mode); } ocreat 791.22Schristos9 STD { int freebsd_sys_link(const char *path, \ 801.22Schristos const char *link); } 811.22Schristos10 STD { int freebsd_sys_unlink(const char *path); } 821.1Smycroft11 OBSOL execv 831.22Schristos12 STD { int freebsd_sys_chdir(const char *path); } 841.1Smycroft13 NOARGS { int sys_fchdir(int fd); } 851.22Schristos14 STD { int freebsd_sys_mknod(const char *path, int mode, \ 861.1Smycroft int dev); } 871.22Schristos15 STD { int freebsd_sys_chmod(const char *path, int mode); } 881.22Schristos16 STD { int freebsd_sys_chown(const char *path, int uid, \ 891.22Schristos int gid); } 901.1Smycroft17 NOARGS { int sys_obreak(char *nsize); } break 911.44Schristos18 NOARGS { int compat_20_sys_getfsstat(struct statfs12 *buf, \ 921.44Schristos long bufsize, int flags); } 931.1Smycroft19 NOARGS { long compat_43_sys_lseek(int fd, long offset, \ 941.1Smycroft int whence); } olseek 951.33Smycroft20 NOARGS { pid_t sys_getpid_with_ppid(void); } 961.22Schristos21 STD { int freebsd_sys_mount(int type, const char *path, \ 971.1Smycroft int flags, caddr_t data); } 981.22Schristos22 STD { int freebsd_sys_unmount(const char *path, \ 991.22Schristos int flags); } 1001.1Smycroft23 NOARGS { int sys_setuid(uid_t uid); } 1011.33Smycroft24 NOARGS { uid_t sys_getuid_with_euid(void); } 1021.1Smycroft25 NOARGS { uid_t sys_geteuid(void); } 1031.1Smycroft26 STD { int freebsd_sys_ptrace(int req, pid_t pid, \ 1041.1Smycroft caddr_t addr, int data); } 1051.1Smycroft27 NOARGS { int sys_recvmsg(int s, struct msghdr *msg, \ 1061.1Smycroft int flags); } 1071.1Smycroft28 NOARGS { int sys_sendmsg(int s, caddr_t msg, int flags); } 1081.1Smycroft29 NOARGS { int sys_recvfrom(int s, caddr_t buf, size_t len, \ 1091.1Smycroft int flags, caddr_t from, int *fromlenaddr); } 1101.1Smycroft30 NOARGS { int sys_accept(int s, caddr_t name, int *anamelen); } 1111.1Smycroft31 NOARGS { int sys_getpeername(int fdes, caddr_t asa, \ 1121.1Smycroft int *alen); } 1131.1Smycroft32 NOARGS { int sys_getsockname(int fdes, caddr_t asa, \ 1141.1Smycroft int *alen); } 1151.22Schristos33 STD { int freebsd_sys_access(const char *path, int flags); } 1161.22Schristos34 STD { int freebsd_sys_chflags(const char *path, \ 1171.22Schristos int flags); } 1181.1Smycroft35 NOARGS { int sys_fchflags(int fd, int flags); } 1191.1Smycroft36 NOARGS { int sys_sync(void); } 1201.1Smycroft37 NOARGS { int sys_kill(int pid, int signum); } 1211.22Schristos38 STD { int compat_43_freebsd_sys_stat(const char *path, \ 1221.11Schristos struct stat43 *ub); } stat43 1231.3Smycroft39 NOARGS { pid_t sys_getppid(void); } 1241.22Schristos40 STD { int compat_43_freebsd_sys_lstat(const char *path, \ 1251.11Schristos struct stat43 *ub); } lstat43 1261.1Smycroft41 NOARGS { int sys_dup(u_int fd); } 1271.1Smycroft42 NOARGS { int sys_pipe(void); } 1281.1Smycroft43 NOARGS { gid_t sys_getegid(void); } 1291.1Smycroft44 NOARGS { int sys_profil(caddr_t samples, u_int size, \ 1301.1Smycroft u_int offset, u_int scale); } 1311.1Smycroft#ifdef KTRACE 1321.1Smycroft45 NOARGS { int sys_ktrace(char *fname, int ops, int facs, \ 1331.1Smycroft int pid); } 1341.1Smycroft#else 1351.34Sjdolecek45 EXCL ktrace 1361.1Smycroft#endif 1371.19Smycroft46 NOARGS { int compat_13_sys_sigaction(int signum, \ 1381.19Smycroft const struct sigaction13 *nsa, \ 1391.19Smycroft struct sigaction13 *osa); } 1401.33Smycroft47 NOARGS { gid_t sys_getgid_with_egid(void); } 1411.19Smycroft48 NOARGS { int compat_13_sys_sigprocmask(int how, \ 1421.19Smycroft int mask); } 1431.5Schristos49 NOARGS { int sys___getlogin(char *namebuf, u_int namelen); } 1441.40Sthorpej50 NOARGS { int sys___setlogin(char *namebuf); } 1451.1Smycroft51 NOARGS { int sys_acct(char *path); } 1461.19Smycroft52 NOARGS { int compat_13_sys_sigpending(void); } 1471.13Sveego53 NOARGS { int compat_13_sys_sigaltstack( \ 1481.13Sveego const struct sigaltstack13 *nss, \ 1491.13Sveego struct sigaltstack13 *oss); } 1501.1Smycroft54 STD { int freebsd_sys_ioctl(int fd, u_long com, \ 1511.1Smycroft caddr_t data); } 1521.22Schristos55 NOARGS { int sys_reboot(int opt); } oreboot 1531.22Schristos56 STD { int freebsd_sys_revoke(const char *path); } 1541.22Schristos57 STD { int freebsd_sys_symlink(const char *path, \ 1551.22Schristos const char *link); } 1561.22Schristos58 STD { int freebsd_sys_readlink(const char *path, \ 1571.22Schristos char *buf, int count); } 1581.22Schristos59 STD { int freebsd_sys_execve(const char *path, \ 1591.22Schristos char **argp, char **envp); } 1601.1Smycroft60 NOARGS { int sys_umask(int newmask); } 1611.22Schristos61 STD { int freebsd_sys_chroot(const char *path); } 1621.11Schristos62 NOARGS { int compat_43_sys_fstat(int fd, struct stat43 *sb); } \ 1631.11Schristos fstat43 1641.1Smycroft63 NOARGS { int compat_43_sys_getkerninfo(int op, char *where, \ 1651.1Smycroft int *size, int arg); } ogetkerninfo 1661.1Smycroft64 NOARGS { int compat_43_sys_getpagesize(void); } ogetpagesize 1671.1Smycroft65 STD { int freebsd_sys_msync(caddr_t addr, size_t len, \ 1681.1Smycroft int flags); } 1691.1Smycroft66 NOARGS { int sys_vfork(void); } 1701.1Smycroft67 OBSOL vread 1711.1Smycroft68 OBSOL vwrite 1721.24Skleink69 NOARGS { int sys_sbrk(intptr_t incr); } 1731.1Smycroft70 NOARGS { int sys_sstk(int incr); } 1741.1Smycroft71 NOARGS { int compat_43_sys_mmap(caddr_t addr, size_t len, \ 1751.1Smycroft int prot, int flags, int fd, long pos); } ommap 1761.1Smycroft72 NOARGS { int sys_ovadvise(int anom); } vadvise 1771.1Smycroft73 NOARGS { int sys_munmap(caddr_t addr, size_t len); } 1781.1Smycroft74 NOARGS { int sys_mprotect(caddr_t addr, size_t len, \ 1791.1Smycroft int prot); } 1801.1Smycroft75 NOARGS { int sys_madvise(caddr_t addr, size_t len, \ 1811.1Smycroft int behav); } 1821.1Smycroft76 OBSOL vhangup 1831.1Smycroft77 OBSOL vlimit 1841.1Smycroft78 NOARGS { int sys_mincore(caddr_t addr, size_t len, char *vec); } 1851.1Smycroft79 NOARGS { int sys_getgroups(u_int gidsetsize, gid_t *gidset); } 1861.1Smycroft80 NOARGS { int sys_setgroups(u_int gidsetsize, gid_t *gidset); } 1871.1Smycroft81 NOARGS { int sys_getpgrp(void); } 1881.1Smycroft82 NOARGS { int sys_setpgid(int pid, int pgid); } 1891.1Smycroft83 NOARGS { int sys_setitimer(u_int which, \ 1901.1Smycroft struct itimerval *itv, struct itimerval *oitv); } 1911.1Smycroft84 NOARGS { int compat_43_sys_wait(void); } owait 1921.7Sthorpej85 NOARGS { int compat_12_sys_swapon(char *name); } 1931.1Smycroft86 NOARGS { int sys_getitimer(u_int which, \ 1941.1Smycroft struct itimerval *itv); } 1951.1Smycroft87 NOARGS { int compat_43_sys_gethostname(char *hostname, \ 1961.1Smycroft u_int len); } ogethostname 1971.1Smycroft88 NOARGS { int compat_43_sys_sethostname(char *hostname, \ 1981.1Smycroft u_int len); } osethostname 1991.1Smycroft89 NOARGS { int compat_43_sys_getdtablesize(void); } \ 2001.1Smycroft ogetdtablesize 2011.1Smycroft90 NOARGS { int sys_dup2(u_int from, u_int to); } 2021.1Smycroft91 UNIMPL getdopt 2031.1Smycroft92 NOARGS { int sys_fcntl(int fd, int cmd, void *arg); } 2041.1Smycroft93 NOARGS { int sys_select(u_int nd, fd_set *in, fd_set *ou, \ 2051.1Smycroft fd_set *ex, struct timeval *tv); } 2061.1Smycroft94 UNIMPL setdopt 2071.1Smycroft95 NOARGS { int sys_fsync(int fd); } 2081.1Smycroft96 NOARGS { int sys_setpriority(int which, int who, int prio); } 2091.1Smycroft97 NOARGS { int sys_socket(int domain, int type, int protocol); } 2101.1Smycroft98 NOARGS { int sys_connect(int s, caddr_t name, int namelen); } 2111.1Smycroft99 NOARGS { int compat_43_sys_accept(int s, caddr_t name, \ 2121.1Smycroft int *anamelen); } oaccept 2131.1Smycroft100 NOARGS { int sys_getpriority(int which, int who); } 2141.1Smycroft101 NOARGS { int compat_43_sys_send(int s, caddr_t buf, int len, \ 2151.1Smycroft int flags); } osend 2161.1Smycroft102 NOARGS { int compat_43_sys_recv(int s, caddr_t buf, int len, \ 2171.1Smycroft int flags); } orecv 2181.1Smycroft103 STD { int freebsd_sys_sigreturn( \ 2191.1Smycroft struct freebsd_sigcontext *scp); } 2201.1Smycroft104 NOARGS { int sys_bind(int s, caddr_t name, int namelen); } 2211.1Smycroft105 NOARGS { int sys_setsockopt(int s, int level, int name, \ 2221.1Smycroft caddr_t val, int valsize); } 2231.1Smycroft106 NOARGS { int sys_listen(int s, int backlog); } 2241.1Smycroft107 OBSOL vtimes 2251.1Smycroft108 NOARGS { int compat_43_sys_sigvec(int signum, \ 2261.1Smycroft struct sigvec *nsv, struct sigvec *osv); } osigvec 2271.1Smycroft109 NOARGS { int compat_43_sys_sigblock(int mask); } osigblock 2281.1Smycroft110 NOARGS { int compat_43_sys_sigsetmask(int mask); } osigsetmask 2291.19Smycroft111 NOARGS { int compat_13_sys_sigsuspend(int mask); } 2301.1Smycroft112 NOARGS { int compat_43_sys_sigstack(struct sigstack *nss, \ 2311.1Smycroft struct sigstack *oss); } osigstack 2321.1Smycroft113 NOARGS { int compat_43_sys_recvmsg(int s, \ 2331.1Smycroft struct omsghdr *msg, int flags); } orecvmsg 2341.1Smycroft114 NOARGS { int compat_43_sys_sendmsg(int s, caddr_t msg, \ 2351.1Smycroft int flags); } osendmsg 2361.1Smycroft#ifdef TRACE 2371.1Smycroft115 NOARGS { int sys_vtrace(int request, int value); } 2381.1Smycroft#else 2391.1Smycroft115 OBSOL vtrace 2401.1Smycroft#endif 2411.1Smycroft116 NOARGS { int sys_gettimeofday(struct timeval *tp, \ 2421.1Smycroft struct timezone *tzp); } 2431.1Smycroft117 NOARGS { int sys_getrusage(int who, struct rusage *rusage); } 2441.1Smycroft118 NOARGS { int sys_getsockopt(int s, int level, int name, \ 2451.1Smycroft caddr_t val, int *avalsize); } 2461.1Smycroft119 OBSOL resuba 2471.1Smycroft120 NOARGS { int sys_readv(int fd, struct iovec *iovp, \ 2481.1Smycroft u_int iovcnt); } 2491.1Smycroft121 NOARGS { int sys_writev(int fd, struct iovec *iovp, \ 2501.1Smycroft u_int iovcnt); } 2511.1Smycroft122 NOARGS { int sys_settimeofday(struct timeval *tv, \ 2521.1Smycroft struct timezone *tzp); } 2531.1Smycroft123 NOARGS { int sys_fchown(int fd, int uid, int gid); } 2541.1Smycroft124 NOARGS { int sys_fchmod(int fd, int mode); } 2551.1Smycroft125 NOARGS { int compat_43_sys_recvfrom(int s, caddr_t buf, \ 2561.1Smycroft size_t len, int flags, caddr_t from, \ 2571.1Smycroft int *fromlenaddr); } orecvfrom 2581.4Smycroft126 NOARGS { int sys_setreuid(int ruid, int euid); } 2591.4Smycroft127 NOARGS { int sys_setregid(int rgid, int egid); } 2601.22Schristos128 STD { int freebsd_sys_rename(const char *from, \ 2611.22Schristos const char *to); } 2621.22Schristos129 STD { int compat_43_freebsd_sys_truncate(const char *path, \ 2631.1Smycroft long length); } otruncate 2641.2Smycroft130 NOARGS { int compat_43_sys_ftruncate(int fd, long length); } \ 2651.2Smycroft oftruncate 2661.2Smycroft131 NOARGS { int sys_flock(int fd, int how); } 2671.22Schristos132 STD { int freebsd_sys_mkfifo(const char *path, int mode); } 2681.1Smycroft133 NOARGS { int sys_sendto(int s, caddr_t buf, size_t len, \ 2691.1Smycroft int flags, caddr_t to, int tolen); } 2701.1Smycroft134 NOARGS { int sys_shutdown(int s, int how); } 2711.1Smycroft135 NOARGS { int sys_socketpair(int domain, int type, \ 2721.1Smycroft int protocol, int *rsv); } 2731.22Schristos136 STD { int freebsd_sys_mkdir(const char *path, int mode); } 2741.22Schristos137 STD { int freebsd_sys_rmdir(const char *path); } 2751.1Smycroft138 NOARGS { int sys_utimes(char *path, struct timeval *tptr); } 2761.1Smycroft139 OBSOL 4.2 sigreturn 2771.1Smycroft140 NOARGS { int sys_adjtime(struct timeval *delta, \ 2781.1Smycroft struct timeval *olddelta); } 2791.1Smycroft141 NOARGS { int compat_43_sys_getpeername(int fdes, caddr_t asa, \ 2801.1Smycroft int *alen); } ogetpeername 2811.1Smycroft142 NOARGS { int32_t compat_43_sys_gethostid(void); } ogethostid 2821.1Smycroft143 NOARGS { int compat_43_sys_sethostid(int32_t hostid); } \ 2831.1Smycroft osethostid 2841.1Smycroft144 NOARGS { int compat_43_sys_getrlimit(u_int which, \ 2851.10Smycroft struct orlimit *rlp); } ogetrlimit 2861.1Smycroft145 NOARGS { int compat_43_sys_setrlimit(u_int which, \ 2871.10Smycroft struct orlimit *rlp); } osetrlimit 2881.1Smycroft146 NOARGS { int compat_43_sys_killpg(int pgid, int signum); } \ 2891.1Smycroft okillpg 2901.1Smycroft147 NOARGS { int sys_setsid(void); } 2911.1Smycroft148 NOARGS { int sys_quotactl(char *path, int cmd, int uid, \ 2921.1Smycroft caddr_t arg); } 2931.1Smycroft149 NOARGS { int compat_43_sys_quota(void); } oquota 2941.1Smycroft150 NOARGS { int compat_43_sys_getsockname(int fdec, caddr_t asa, \ 2951.1Smycroft int *alen); } ogetsockname 2961.1Smycroft 2971.1Smycroft; Syscalls 151-180 inclusive are reserved for vendor-specific 2981.1Smycroft; system calls. (This includes various calls added for compatibity 2991.1Smycroft; with other Unix variants.) 3001.1Smycroft; Some of these calls are now supported by BSD... 3011.27Stv151 UNIMPL sem_lock 3021.27Stv152 UNIMPL sem_wakeup 3031.27Stv153 UNIMPL asyncdaemon 3041.1Smycroft154 UNIMPL 3051.6Sthorpej#if defined(NFS) || defined(NFSSERVER) 3061.1Smycroft155 NOARGS { int sys_nfssvc(int flag, caddr_t argp); } 3071.1Smycroft#else 3081.27Stv155 UNIMPL nfssvc 3091.1Smycroft#endif 3101.1Smycroft156 NOARGS { int compat_43_sys_getdirentries(int fd, char *buf, \ 3111.1Smycroft u_int count, long *basep); } ogetdirentries 3121.22Schristos157 STD { int freebsd_sys_statfs(const char *path, \ 3131.44Schristos struct statfs12 *buf); } 3141.44Schristos158 NOARGS { int compat_20_sys_fstatfs(int fd, \ 3151.44Schristos struct statfs12 *buf); } 3161.1Smycroft159 UNIMPL 3171.1Smycroft160 UNIMPL 3181.6Sthorpej#ifdef NFS 3191.22Schristos161 STD { int freebsd_sys_getfh(const char *fname, \ 3201.22Schristos fhandle_t *fhp); } 3211.1Smycroft#else 3221.1Smycroft161 UNIMPL getfh 3231.1Smycroft#endif 3241.1Smycroft162 NOARGS { int compat_09_sys_getdomainname(char *domainname, \ 3251.1Smycroft int len); } 3261.1Smycroft163 NOARGS { int compat_09_sys_setdomainname(char *domainname, \ 3271.1Smycroft int len); } 3281.1Smycroft164 NOARGS { int compat_09_sys_uname(struct outsname *name); } 3291.1Smycroft165 NOARGS { int sys_sysarch(int op, char *parms); } 3301.1Smycroft166 STD { int freebsd_sys_rtprio(int function, pid_t pid, \ 3311.1Smycroft struct freebsd_rtprio *rtp); } 3321.1Smycroft167 UNIMPL 3331.1Smycroft168 UNIMPL 3341.1Smycroft; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 3351.37Seeh#if defined(SYSVSEM) && !defined(_LP64) 3361.14Smycroft169 STD { int freebsd_sys_semsys(int which, int a2, int a3, \ 3371.1Smycroft int a4, int a5); } 3381.1Smycroft#else 3391.1Smycroft169 UNIMPL 1.0 semsys 3401.1Smycroft#endif 3411.1Smycroft; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 3421.37Seeh#if defined(SYSVMSG) && !defined(_LP64) 3431.14Smycroft170 STD { int freebsd_sys_msgsys(int which, int a2, int a3, \ 3441.1Smycroft int a4, int a5, int a6); } 3451.1Smycroft#else 3461.1Smycroft170 UNIMPL 1.0 msgsys 3471.1Smycroft#endif 3481.1Smycroft; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 3491.37Seeh#if defined(SYSVSHM) && !defined(_LP64) 3501.14Smycroft171 STD { int freebsd_sys_shmsys(int which, int a2, int a3, \ 3511.1Smycroft int a4); } 3521.1Smycroft#else 3531.1Smycroft171 UNIMPL 1.0 shmsys 3541.1Smycroft#endif 3551.1Smycroft172 UNIMPL 3561.27Stv173 NOARGS { ssize_t sys_pread(int fd, void *buf, \ 3571.27Stv size_t nbyte, int pad, off_t offset); } 3581.27Stv174 NOARGS { ssize_t sys_pwrite(int fd, const void *buf, \ 3591.27Stv size_t nbyte, int pad, off_t offset); } 3601.1Smycroft175 UNIMPL 3611.30Sitojun#ifdef NTP 3621.1Smycroft176 STD { int freebsd_ntp_adjtime(struct freebsd_timex *tp); } 3631.29Sbjh21#else 3641.29Sbjh21176 EXCL ntp_adjtime 3651.29Sbjh21#endif 3661.27Stv177 UNIMPL sfork 3671.27Stv178 UNIMPL getdescriptor 3681.27Stv179 UNIMPL setdescriptor 3691.1Smycroft180 UNIMPL 3701.1Smycroft 3711.1Smycroft; Syscalls 180-199 are used by/reserved for BSD 3721.1Smycroft181 NOARGS { int sys_setgid(gid_t gid); } 3731.1Smycroft182 NOARGS { int sys_setegid(gid_t egid); } 3741.1Smycroft183 NOARGS { int sys_seteuid(uid_t euid); } 3751.1Smycroft#ifdef LFS 3761.23Sdrochner184 NOARGS { int sys_lfs_bmapv(fsid_t *fsidp, \ 3771.1Smycroft struct block_info *blkiov, int blkcnt); } 3781.23Sdrochner185 NOARGS { int sys_lfs_markv(fsid_t *fsidp, \ 3791.1Smycroft struct block_info *blkiov, int blkcnt); } 3801.23Sdrochner186 NOARGS { int sys_lfs_segclean(fsid_t *fsidp, u_long segment); } 3811.23Sdrochner187 NOARGS { int sys_lfs_segwait(fsid_t *fsidp, struct timeval *tv); } 3821.1Smycroft#else 3831.1Smycroft184 UNIMPL 3841.1Smycroft185 UNIMPL 3851.1Smycroft186 UNIMPL 3861.1Smycroft187 UNIMPL 3871.1Smycroft#endif 3881.22Schristos188 STD { int freebsd_sys_stat(const char *path, \ 3891.12Schristos struct stat12 *ub); } 3901.12Schristos189 NOARGS { int compat_12_sys_fstat(int fd, \ 3911.12Schristos struct stat12 *sb); } 3921.22Schristos190 STD { int freebsd_sys_lstat(const char *path, \ 3931.12Schristos struct stat12 *ub); } 3941.22Schristos191 STD { int freebsd_sys_pathconf(const char *path, \ 3951.22Schristos int name); } 3961.1Smycroft192 NOARGS { int sys_fpathconf(int fd, int name); } 3971.1Smycroft193 UNIMPL 3981.1Smycroft194 NOARGS { int sys_getrlimit(u_int which, struct rlimit *rlp); } 3991.1Smycroft195 NOARGS { int sys_setrlimit(u_int which, struct rlimit *rlp); } 4001.8Sfvdl196 NOARGS { int compat_12_sys_getdirentries(int fd, char *buf, \ 4011.1Smycroft u_int count, long *basep); } 4021.41Spooka197 STD { caddr_t freebsd_sys_mmap(caddr_t addr, size_t len, \ 4031.41Spooka int prot, int flags, int fd, long pad, off_t pos); } 4041.1Smycroft198 NOARGS { int sys_nosys(void); } __syscall 4051.1Smycroft199 NOARGS { off_t sys_lseek(int fd, int pad, off_t offset, \ 4061.1Smycroft int whence); } 4071.22Schristos200 STD { int freebsd_sys_truncate(const char *path, int pad, \ 4081.1Smycroft off_t length); } 4091.1Smycroft201 NOARGS { int sys_ftruncate(int fd, int pad, off_t length); } 4101.47Sheas202 STD { int freebsd_sys_sysctl(int *name, u_int namelen, \ 4111.1Smycroft void *old, size_t *oldlenp, void *new, \ 4121.1Smycroft size_t newlen); } 4131.1Smycroft203 NOARGS { int sys_mlock(caddr_t addr, size_t len); } 4141.1Smycroft204 NOARGS { int sys_munlock(caddr_t addr, size_t len); } 4151.1Smycroft#ifdef FREEBSD_BASED_ON_44LITE_R2 4161.1Smycroft205 STD { int freebsd_sys_undelete(char *path); } 4171.1Smycroft#else 4181.27Stv205 UNIMPL undelete 4191.1Smycroft#endif 4201.22Schristos206 NOARGS { int sys_futimes(int fd, const struct timeval *tptr); } 4211.22Schristos207 NOARGS { pid_t sys_getpgid(pid_t pid); } 4221.22Schristos#if 0 4231.22Schristos208 NOARGS { int sys_reboot(int opt, char *bootstr); } 4241.22Schristos#else 4251.22Schristos208 UNIMPL newreboot 4261.22Schristos#endif 4271.22Schristos209 NOARGS { int sys_poll(struct pollfd *fds, u_int nfds, \ 4281.22Schristos int timeout); } 4291.1Smycroft; 4301.1Smycroft; Syscalls 210-219 are reserved for dynamically loaded syscalls 4311.1Smycroft; 4321.1Smycroft210 UNIMPL 4331.1Smycroft211 UNIMPL 4341.1Smycroft212 UNIMPL 4351.1Smycroft213 UNIMPL 4361.1Smycroft214 UNIMPL 4371.1Smycroft215 UNIMPL 4381.1Smycroft216 UNIMPL 4391.1Smycroft217 UNIMPL 4401.1Smycroft218 UNIMPL 4411.1Smycroft219 UNIMPL 4421.9Senami; 4431.9Senami; Syscalls 220-239 are reserved for syscalls imported from NetBSD 4441.9Senami; 4451.22Schristos#ifdef SYSVSEM 4461.25Sthorpej220 NOARGS { int compat_14_sys___semctl(int semid, int semnum, \ 4471.25Sthorpej int cmd, union __semun *arg); } 4481.22Schristos221 NOARGS { int sys_semget(key_t key, int nsems, int semflg); } 4491.22Schristos222 NOARGS { int sys_semop(int semid, struct sembuf *sops, \ 4501.22Schristos u_int nsops); } 4511.22Schristos223 NOARGS { int sys_semconfig(int flag); } 4521.22Schristos#else 4531.22Schristos220 UNIMPL semctl 4541.22Schristos221 UNIMPL semget 4551.22Schristos222 UNIMPL semop 4561.22Schristos223 UNIMPL semconfig 4571.22Schristos#endif 4581.22Schristos#ifdef SYSVMSG 4591.25Sthorpej224 NOARGS { int compat_14_sys_msgctl(int msqid, int cmd, \ 4601.25Sthorpej struct msqid14_ds *buf); } 4611.22Schristos225 NOARGS { int sys_msgget(key_t key, int msgflg); } 4621.22Schristos226 NOARGS { int sys_msgsnd(int msqid, void *msgp, size_t msgsz, \ 4631.22Schristos int msgflg); } 4641.22Schristos227 NOARGS { int sys_msgrcv(int msqid, void *msgp, size_t msgsz, \ 4651.22Schristos long msgtyp, int msgflg); } 4661.22Schristos#else 4671.22Schristos224 UNIMPL msgctl 4681.22Schristos225 UNIMPL msgget 4691.22Schristos226 UNIMPL msgsnd 4701.22Schristos227 UNIMPL msgrcv 4711.22Schristos#endif 4721.22Schristos#ifdef SYSVSHM 4731.22Schristos228 NOARGS { int sys_shmat(int shmid, void *shmaddr, int shmflg); } 4741.25Sthorpej229 NOARGS { int compat_14_sys_shmctl(int shmid, int cmd, \ 4751.25Sthorpej struct shmid_ds14 *buf); } 4761.22Schristos230 NOARGS { int sys_shmdt(void *shmaddr); } 4771.22Schristos231 NOARGS { int sys_shmget(key_t key, int size, int shmflg); } 4781.22Schristos#else 4791.22Schristos228 UNIMPL shmat 4801.22Schristos229 UNIMPL shmctl 4811.22Schristos230 UNIMPL shmdt 4821.22Schristos231 UNIMPL shmget 4831.22Schristos#endif 4841.22Schristos; 4851.22Schristos; XXXX 4861.22Schristos232 NOARGS { int sys_clock_gettime(clockid_t clock_id, \ 4871.22Schristos struct timespec *tp); } 4881.22Schristos233 NOARGS { int sys_clock_settime(clockid_t clock_id, \ 4891.22Schristos const struct timespec *tp); } 4901.22Schristos234 NOARGS { int sys_clock_getres(clockid_t clock_id, \ 4911.22Schristos struct timespec *tp); } 4921.22Schristos235 UNIMPL timer_create 4931.22Schristos236 UNIMPL timer_delete 4941.22Schristos237 UNIMPL timer_settime 4951.22Schristos238 UNIMPL timer_gettime 4961.22Schristos239 UNIMPL timer_getoverrun 4971.22Schristos240 NOARGS { int sys_nanosleep(const struct timespec *rqtp, \ 4981.22Schristos struct timespec *rmtp); } 4991.9Senami241 UNIMPL 5001.9Senami242 UNIMPL 5011.9Senami243 UNIMPL 5021.9Senami244 UNIMPL 5031.9Senami245 UNIMPL 5041.9Senami246 UNIMPL 5051.9Senami247 UNIMPL 5061.9Senami248 UNIMPL 5071.9Senami249 UNIMPL 5081.22Schristos; syscall numbers initially used in OpenBSD 5091.36Sjdolecek250 NOARGS { int sys_minherit(void *addr, size_t len, \ 5101.36Sjdolecek int inherit); } 5111.38Spooka251 STD { int freebsd_sys_rfork(int flags); } 5121.22Schristos252 UNIMPL openbsd_poll 5131.26Sminoura253 NOARGS { int sys_issetugid(void); } 5141.22Schristos254 STD { int freebsd_sys_lchown(const char *path, int uid, \ 5151.9Senami int gid); } 5161.22Schristos255 UNIMPL 5171.22Schristos256 UNIMPL 5181.22Schristos257 UNIMPL 5191.22Schristos258 UNIMPL 5201.22Schristos259 UNIMPL 5211.22Schristos260 UNIMPL 5221.22Schristos261 UNIMPL 5231.22Schristos262 UNIMPL 5241.22Schristos263 UNIMPL 5251.22Schristos264 UNIMPL 5261.22Schristos265 UNIMPL 5271.22Schristos266 UNIMPL 5281.22Schristos267 UNIMPL 5291.22Schristos268 UNIMPL 5301.22Schristos269 UNIMPL 5311.22Schristos270 UNIMPL 5321.22Schristos271 UNIMPL 5331.48Schristos272 NOARGS { int compat_30_sys_getdents(int fd, char *buf, size_t count); } 5341.22Schristos273 UNIMPL 5351.22Schristos274 NOARGS { int sys_lchmod(const char *path, mode_t mode); } 5361.22Schristos275 NOARGS { int sys_lchown(const char *path, uid_t uid, \ 5371.22Schristos gid_t gid); } netbsd_lchown 5381.22Schristos276 NOARGS { int sys_lutimes(const char *path, \ 5391.22Schristos const struct timeval *tptr); } 5401.22Schristos277 NOARGS { int sys___msync13(void *addr, size_t len, int flags); } 5411.48Schristos278 NOARGS { int compat_30_sys___stat13(const char *path, struct stat30 *ub); } 5421.48Schristos279 NOARGS { int compat_30_sys___fstat13(int fd, struct stat30 *sb); } 5431.48Schristos280 NOARGS { int compat_30_sys___lstat13(const char *path, struct stat30 *ub);} 5441.22Schristos281 UNIMPL 5451.22Schristos282 UNIMPL 5461.22Schristos283 UNIMPL 5471.22Schristos284 UNIMPL 5481.22Schristos285 UNIMPL 5491.22Schristos286 UNIMPL 5501.22Schristos287 UNIMPL 5511.22Schristos288 UNIMPL 5521.22Schristos289 UNIMPL 5531.22Schristos290 UNIMPL 5541.22Schristos291 UNIMPL 5551.22Schristos292 UNIMPL 5561.22Schristos293 UNIMPL 5571.22Schristos294 UNIMPL 5581.22Schristos295 UNIMPL 5591.22Schristos296 UNIMPL 5601.44Schristos297 NOARGS { int compat_20_sys_fhstatfs(const fhandle_t *fhp, \ 5611.44Schristos struct statfs12 *buf); } 5621.36Sjdolecek298 NOARGS { int sys_fhopen(const fhandle_t *fhp, int flags); } 5631.36Sjdolecek299 NOARGS { int sys_fhstat(const fhandle_t *fhp, \ 5641.36Sjdolecek struct stat *sb); } 5651.22Schristos; syscall numbers for FreeBSD 5661.22Schristos300 UNIMPL modnext 5671.22Schristos301 UNIMPL modstat 5681.22Schristos302 UNIMPL modfnext 5691.22Schristos303 UNIMPL modfind 5701.22Schristos304 UNIMPL kldload 5711.22Schristos305 UNIMPL kldunload 5721.22Schristos306 UNIMPL kldfind 5731.22Schristos307 UNIMPL kldnext 5741.22Schristos308 UNIMPL kldstat 5751.22Schristos309 UNIMPL kldfirstmod 5761.27Stv310 NOARGS { pid_t sys_getsid(pid_t pid); } 5771.22Schristos311 UNIMPL setresuid 5781.22Schristos312 UNIMPL setresgid 5791.22Schristos313 UNIMPL signanosleep 5801.22Schristos314 UNIMPL aio_return 5811.22Schristos315 UNIMPL aio_suspend 5821.22Schristos316 UNIMPL aio_cancel 5831.22Schristos317 UNIMPL aio_error 5841.22Schristos318 UNIMPL aio_read 5851.22Schristos319 UNIMPL aio_write 5861.22Schristos320 UNIMPL lio_listio 5871.39Sgmcgarry321 NOARGS { void freebsd_sys_yield(void); } 5881.22Schristos322 UNIMPL thr_sleep 5891.22Schristos323 UNIMPL thr_wakeup 5901.27Stv324 NOARGS { int sys_mlockall(int flags); } 5911.27Stv325 NOARGS { int sys_munlockall(void); } 5921.27Stv326 NOARGS { int sys___getcwd(char *bufp, size_t length); } 5931.39Sgmcgarry327 STD { int freebsd_sys_sched_setparam(pid_t pid, \ 5941.39Sgmcgarry const struct freebsd_sched_param *sp); } 5951.39Sgmcgarry328 STD { int freebsd_sys_sched_getparam(pid_t pid, \ 5961.39Sgmcgarry struct freebsd_sched_param *sp); } 5971.39Sgmcgarry329 STD { int freebsd_sys_sched_setscheduler(pid_t pid, \ 5981.39Sgmcgarry int policy, const struct sched_param *sp); } 5991.39Sgmcgarry330 STD { int freebsd_sys_sched_getscheduler(pid_t pid); } 6001.39Sgmcgarry331 STD { int freebsd_sys_sched_yield(void); } 6011.39Sgmcgarry332 STD { int freebsd_sys_sched_get_priority_max(int policy); } 6021.39Sgmcgarry333 STD { int freebsd_sys_sched_get_priority_min(int policy); } 6031.22Schristos334 UNIMPL sched_rr_get_interval 6041.34Sjdolecek335 STD { int freebsd_sys_utrace(void *addr, size_t len); } 6051.22Schristos336 UNIMPL sendfile 6061.22Schristos337 UNIMPL kldsym 6071.27Stv338 UNIMPL jail 6081.27Stv339 UNIMPL pioctl 6091.28Sonoe340 NOARGS { int sys___sigprocmask14(int how, \ 6101.28Sonoe const sigset_t *set, \ 6111.28Sonoe sigset_t *oset); } 6121.28Sonoe341 NOARGS { int sys___sigsuspend14(const sigset_t *set); } 6131.28Sonoe342 STD { int freebsd_sys_sigaction4(int signum, \ 6141.28Sonoe const struct freebsd_sigaction4 *nsa, \ 6151.28Sonoe struct freebsd_sigaction4 *osa); } 6161.28Sonoe343 NOARGS { int sys___sigpending14(const sigset_t *set); } 6171.27Stv344 UNIMPL 4.0 sigreturn 6181.27Stv345 UNIMPL sigtimedwait 6191.27Stv346 UNIMPL sigwaitinfo 6201.27Stv347 UNIMPL __acl_get_file 6211.27Stv348 UNIMPL __acl_set_file 6221.27Stv349 UNIMPL __acl_get_fd 6231.27Stv350 UNIMPL __acl_set_fd 6241.27Stv351 UNIMPL __acl_delete_file 6251.27Stv352 UNIMPL __acl_delete_fd 6261.27Stv353 UNIMPL __acl_aclcheck_file 6271.27Stv354 UNIMPL __acl_aclcheck_fd 6281.27Stv355 UNIMPL extattrctl 6291.27Stv356 UNIMPL extattr_set_file 6301.27Stv357 UNIMPL extattr_get_file 6311.27Stv358 UNIMPL extattr_delete_file 6321.27Stv359 UNIMPL aio_waitcomplete 6331.27Stv360 UNIMPL getresuid 6341.27Stv361 UNIMPL getresgid 6351.27Stv362 UNIMPL kqueue 6361.27Stv363 UNIMPL kevent 6371.42Sjdolecek364 UNIMPL __cap_get_proc 6381.42Sjdolecek365 UNIMPL __cap_set_proc 6391.42Sjdolecek366 UNIMPL __cap_get_fd 6401.42Sjdolecek367 UNIMPL __cap_get_file 6411.42Sjdolecek368 UNIMPL __cap_set_fd 6421.42Sjdolecek369 UNIMPL __cap_set_file 6431.42Sjdolecek370 UNIMPL lkmressym 6441.42Sjdolecek371 UNIMPL extattr_set_fd 6451.42Sjdolecek372 UNIMPL extattr_get_fd 6461.42Sjdolecek373 UNIMPL extattr_delete_fd 6471.42Sjdolecek374 UNIMPL __setugid 6481.42Sjdolecek375 UNIMPL nfsclnt 6491.42Sjdolecek376 UNIMPL eaccess 6501.42Sjdolecek377 UNIMPL afs_syscall 6511.42Sjdolecek378 UNIMPL nmount 6521.42Sjdolecek379 UNIMPL kse_exit 6531.42Sjdolecek380 UNIMPL kse_wakeup 6541.42Sjdolecek381 UNIMPL kse_create 6551.42Sjdolecek382 UNIMPL kse_thr_interrupt 6561.42Sjdolecek383 UNIMPL kse_release 6571.42Sjdolecek384 UNIMPL __mac_get_proc 6581.42Sjdolecek385 UNIMPL __mac_set_proc 6591.42Sjdolecek386 UNIMPL __mac_get_fd 6601.42Sjdolecek387 UNIMPL __mac_get_file 6611.42Sjdolecek388 UNIMPL __mac_set_fd 6621.42Sjdolecek389 UNIMPL __mac_set_file 6631.42Sjdolecek390 UNIMPL kenv 6641.42Sjdolecek391 NOARGS { int sys_lchflags(const char *path, u_long flags); } 6651.43Stsarna392 NOARGS { int sys_uuidgen(struct uuid *store, int count); } 6661.42Sjdolecek393 UNIMPL sendfile 6671.42Sjdolecek394 UNIMPL mac_syscall 6681.42Sjdolecek395 UNIMPL getfsstat 6691.42Sjdolecek396 UNIMPL statfs 6701.42Sjdolecek397 UNIMPL fsstatfs 6711.42Sjdolecek398 UNIMPL fhstatfs 6721.42Sjdolecek399 UNIMPL nosys 6731.42Sjdolecek#if defined(P1003_1B_SEMAPHORE) || !defined(_KERNEL) 6741.42Sjdolecek400 NOARGS { int sys__ksem_close(semid_t id); } 6751.42Sjdolecek401 NOARGS { int sys__ksem_post(semid_t id); } 6761.42Sjdolecek402 NOARGS { int sys__ksem_wait(semid_t id); } 6771.42Sjdolecek403 NOARGS { int sys__ksem_trywait(semid_t id); } 6781.42Sjdolecek404 UNIMPL ksem_init 6791.42Sjdolecek405 UNIMPL ksem_open 6801.42Sjdolecek406 NOARGS { int sys__ksem_unlink(const char *name); } 6811.42Sjdolecek407 NOARGS { int sys__ksem_getvalue(semid_t id, \ 6821.42Sjdolecek unsigned int *value); } 6831.42Sjdolecek408 NOARGS { int sys__ksem_destroy(semid_t id); } 6841.42Sjdolecek#else 6851.42Sjdolecek400 EXCL ksem_close 6861.42Sjdolecek401 EXCL ksem_post 6871.42Sjdolecek402 EXCL ksem_wait 6881.42Sjdolecek403 EXCL ksem_trywait 6891.42Sjdolecek404 EXCL ksem_init 6901.42Sjdolecek405 EXCL ksem_open 6911.42Sjdolecek406 EXCL ksem_unlink 6921.42Sjdolecek407 EXCL ksem_getvalue 6931.42Sjdolecek408 EXCL ksem_destroy 6941.42Sjdolecek#endif 6951.42Sjdolecek409 UNIMPL __mac_get_pid 6961.42Sjdolecek410 UNIMPL __mac_get_link 6971.42Sjdolecek411 UNIMPL __mac_set_link 6981.42Sjdolecek412 UNIMPL extattr_set_link 6991.42Sjdolecek413 UNIMPL extattr_get_link 7001.42Sjdolecek414 UNIMPL extattr_delete_link 7011.42Sjdolecek415 UNIMPL __mac_execve 7021.42Sjdolecek416 UNIMPL sigaction 7031.42Sjdolecek417 UNIMPL sigreturn 7041.42Sjdolecek418 UNIMPL __xstat 7051.42Sjdolecek419 UNIMPL __xfstat 7061.42Sjdolecek420 UNIMPL __xlstat 7071.42Sjdolecek421 UNIMPL getcontext 7081.42Sjdolecek422 UNIMPL setcontext 7091.42Sjdolecek423 UNIMPL swapcontext 7101.42Sjdolecek424 UNIMPL swapoff 7111.42Sjdolecek425 UNIMPL __acl_get_link 7121.42Sjdolecek426 UNIMPL __acl_set_link 7131.42Sjdolecek427 UNIMPL __acl_delete_link 7141.42Sjdolecek428 UNIMPL __acl_aclcheck_link 7151.42Sjdolecek429 UNIMPL sigwait 7161.42Sjdolecek430 UNIMPL thr_create 7171.42Sjdolecek431 UNIMPL thr_exit 7181.42Sjdolecek432 UNIMPL thr_self 7191.42Sjdolecek433 UNIMPL thr_kill 7201.42Sjdolecek434 UNIMPL _umtx_lock 7211.42Sjdolecek435 UNIMPL _umtx_unlock 7221.42Sjdolecek436 UNIMPL jail_attach 7231.42Sjdolecek437 UNIMPL extattr_list_fd 7241.42Sjdolecek438 UNIMPL extattr_list_file 7251.42Sjdolecek439 UNIMPL extattr_list_link 726