1 $NetBSD: syscalls.master,v 1.10 2003/09/23 18:31:03 cl Exp $ 2 3; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 4 5; NetBSD system call name/number "master" file. 6; (See syscalls.conf to see what it is processed into.) 7; 8; Fields: number type [type-dependent ...] 9; number system call number, must be in order 10; type one of STD, OBSOL, UNIMPL, NODEF, NOARGS, or one of 11; the compatibility options defined in syscalls.conf. 12; 13; types: 14; STD always included 15; OBSOL obsolete, not included in system 16; UNIMPL unimplemented, not included in system 17; EXCL implemented, but not included in system 18; NODEF included, but don't define the syscall number 19; NOARGS included, but don't define the syscall args structure 20; INDIR included, but don't define the syscall args structure, 21; and allow it to be "really" varargs. 22; 23; The compat options are defined in the syscalls.conf file, and the 24; compat option name is prefixed to the syscall name. Other than 25; that, they're like NODEF (for 'compat' options), or STD (for 26; 'libcompat' options). 27; 28; The type-dependent arguments are as follows: 29; For STD, NODEF, NOARGS, and compat syscalls: 30; { pseudo-proto } [alias] 31; For other syscalls: 32; [comment] 33; 34; #ifdef's, etc. may be included, and are copied to the output files. 35; #include's are copied to the syscall names and switch definition files only. 36 37#if defined(_KERNEL_OPT) 38#include "opt_ktrace.h" 39#include "opt_nfsserver.h" 40#include "opt_ntp.h" 41#include "opt_compat_netbsd.h" 42#include "opt_sysv.h" 43#include "opt_compat_43.h" 44 45#include "fs_lfs.h" 46#include "fs_nfs.h" 47#endif 48 49#include <sys/param.h> 50#include <sys/systm.h> 51#include <sys/signal.h> 52#include <sys/mount.h> 53#include <sys/sa.h> 54#include <sys/syscallargs.h> 55#include <compat/aoutm68k/aoutm68k_syscallargs.h> 56 57%% 58 59; Reserved/unimplemented system calls in the range 0-150 inclusive 60; are reserved for use in future Berkeley releases. 61; Additional system calls implemented in vendor and other 62; redistributions should be placed in the reserved range at the end 63; of the current calls. 64 650 INDIR { int sys_syscall(int number, ...); } 661 NOARGS { void sys_exit(int rval); } 672 NOARGS { int sys_fork(void); } 683 NOARGS { ssize_t sys_read(int fd, void *buf, size_t nbyte); } 694 NOARGS { ssize_t sys_write(int fd, const void *buf, \ 70 size_t nbyte); } 71#ifdef COMPAT_AOUT_ALTPATH 725 STD { int aoutm68k_sys_open(const char *path, \ 73 int flags, ... mode_t mode); } 74#else 755 NOARGS { int sys_open(const char *path, int flags, \ 76 ... mode_t mode); } 77#endif 786 NOARGS { int sys_close(int fd); } 797 NOARGS { int sys_wait4(int pid, int *status, int options, \ 80 struct rusage *rusage); } 81#ifdef COMPAT_43 828 NOARGS { int compat_43_sys_creat(const char *path, \ 83 mode_t mode); } ocreat 84#else 858 EXCL compat_43_sys_creat 86#endif 87#ifdef COMPAT_AOUT_ALTPATH 889 STD { int aoutm68k_sys_link(const char *path, \ 89 const char *link); } 9010 STD { int aoutm68k_sys_unlink(const char *path); } 91#else 929 NOARGS { int sys_link(const char *path, const char *link); } 9310 NOARGS { int sys_unlink(const char *path); } 94#endif 9511 OBSOL execv 96#ifdef COMPAT_AOUT_ALTPATH 9712 STD { int aoutm68k_sys_chdir(const char *path); } 98#else 9912 NOARGS { int sys_chdir(const char *path); } 100#endif 10113 NOARGS { int sys_fchdir(int fd); } 10214 NOARGS { int sys_mknod(const char *path, mode_t mode, \ 103 dev_t dev); } 104#ifdef COMPAT_AOUT_ALTPATH 10515 STD { int aoutm68k_sys_chmod(const char *path, \ 106 mode_t mode); } 10716 STD { int aoutm68k_sys_chown(const char *path, uid_t uid, \ 108 gid_t gid); } 109#else 11015 NOARGS { int sys_chmod(const char *path, mode_t mode); } 11116 NOARGS { int sys_chown(const char *path, uid_t uid, \ 112 gid_t gid); } 113#endif 11417 NOARGS { int sys_obreak(char *nsize); } break 11518 NOARGS { int sys_getfsstat(struct statfs *buf, long bufsize, \ 116 int flags); } 117#ifdef COMPAT_43 11819 NOARGS { long compat_43_sys_lseek(int fd, long offset, \ 119 int whence); } olseek 120#else 12119 EXCL compat_43_sys_lseek 122#endif 12320 NOARGS MPSAFE { pid_t sys_getpid(void); } 12421 NOARGS { int sys_mount(const char *type, \ 125 const char *path, int flags, void *data); } 12622 NOARGS { int sys_unmount(const char *path, int flags); } 12723 NOARGS { int sys_setuid(uid_t uid); } 12824 NOARGS { uid_t sys_getuid(void); } 12925 NOARGS { uid_t sys_geteuid(void); } 13026 NOARGS { int sys_ptrace(int req, pid_t pid, caddr_t addr, \ 131 int data); } 13227 NOARGS { ssize_t sys_recvmsg(int s, struct msghdr *msg, \ 133 int flags); } 13428 NOARGS { ssize_t sys_sendmsg(int s, \ 135 const struct msghdr *msg, int flags); } 13629 NOARGS { ssize_t sys_recvfrom(int s, void *buf, size_t len, \ 137 int flags, struct sockaddr *from, \ 138 unsigned int *fromlenaddr); } 13930 NOARGS { int sys_accept(int s, struct sockaddr *name, \ 140 unsigned int *anamelen); } 14131 NOARGS { int sys_getpeername(int fdes, struct sockaddr *asa, \ 142 unsigned int *alen); } 14332 NOARGS { int sys_getsockname(int fdes, struct sockaddr *asa, \ 144 unsigned int *alen); } 145#ifdef COMPAT_AOUT_ALTPATH 14633 STD { int aoutm68k_sys_access(const char *path, int flags); } 14734 STD { int aoutm68k_sys_chflags(const char *path, \ 148 u_long flags); } 149#else 15033 NOARGS { int sys_access(const char *path, int flags); } 15134 NOARGS { int sys_chflags(const char *path, u_long flags); } 152#endif 15335 NOARGS { int sys_fchflags(int fd, u_long flags); } 15436 NOARGS { void sys_sync(void); } 15537 NOARGS { int sys_kill(int pid, int signum); } 156#ifdef COMPAT_43 15738 STD { int aoutm68k_compat_43_sys_stat(const char *path, \ 158 struct aoutm68k_stat43 *ub); } stat43 159#else 16038 EXCL aoutm68k_compat_43_sys_stat 161#endif 16239 NOARGS { pid_t sys_getppid(void); } 163#ifdef COMPAT_43 16440 STD { int aoutm68k_compat_43_sys_lstat(const char *path, \ 165 struct aoutm68k_stat43 *ub); } lstat43 166#else 16740 EXCL aoutm68k_compat_43_sys_lstat 168#endif 16941 NOARGS { int sys_dup(int fd); } 17042 NOARGS { int sys_pipe(void); } 17143 NOARGS { gid_t sys_getegid(void); } 17244 NOARGS { int sys_profil(caddr_t samples, size_t size, \ 173 u_long offset, u_int scale); } 174#if defined(KTRACE) || !defined(_KERNEL) 17545 NOARGS { int sys_ktrace(const char *fname, int ops, \ 176 int facs, int pid); } 177#else 17845 EXCL ktrace 179#endif 180#ifdef COMPAT_13 18146 NOARGS { int compat_13_sys_sigaction(int signum, \ 182 const struct sigaction13 *nsa, \ 183 struct sigaction13 *osa); } sigaction13 184#else 18546 EXCL compat_13_sys_sigaction 186#endif 18747 NOARGS { gid_t sys_getgid(void); } 188#ifdef COMPAT_13 18948 NOARGS { int compat_13_sys_sigprocmask(int how, \ 190 int mask); } sigprocmask13 191#else 19248 EXCL compat_13_sys_sigprocmask 193#endif 19449 NOARGS { int sys___getlogin(char *namebuf, size_t namelen); } 19550 NOARGS { int sys___setlogin(const char *namebuf); } 19651 NOARGS { int sys_acct(const char *path); } 197#ifdef COMPAT_13 19852 NOARGS { int compat_13_sys_sigpending(void); } sigpending13 19953 NOARGS { int compat_13_sys_sigaltstack( \ 200 const struct sigaltstack13 *nss, \ 201 struct sigaltstack13 *oss); } sigaltstack13 202#else 20352 EXCL compat_13_sys_sigpending 20453 EXCL compat_13_sys_sigaltstack 205#endif 20654 STD { int aoutm68k_sys_ioctl(int fd, \ 207 u_long com, ... void *data); } 208#ifdef COMPAT_12 20955 NOARGS { int compat_12_sys_reboot(int opt); } oreboot 210#else 21155 EXCL compat_12_sys_reboot 212#endif 213#ifdef COMPAT_AOUT_ALTPATH 21456 STD { int aoutm68k_sys_revoke(const char *path); } 21557 STD { int aoutm68k_sys_symlink(const char *path, \ 216 const char *link); } 21758 STD { int aoutm68k_sys_readlink(const char *path, \ 218 char *buf, size_t count); } 21959 STD { int aoutm68k_sys_execve(const char *path, \ 220 char * const *argp, char * const *envp); } 221#else 22256 NOARGS { int sys_revoke(const char *path); } 22357 NOARGS { int sys_symlink(const char *path, \ 224 const char *link); } 22558 NOARGS { int sys_readlink(const char *path, \ 226 char *buf, size_t count); } 22759 NOARGS { int sys_execve(const char *path, \ 228 char * const *argp, char * const *envp); } 229#endif 23060 NOARGS { mode_t sys_umask(mode_t newmask); } 231#ifdef COMPAT_AOUT_ALTPATH 23261 STD { int aoutm68k_sys_chroot(const char *path); } 233#else 23461 NOARGS { int sys_chroot(const char *path); } 235#endif 236#ifdef COMPAT_43 23762 STD { int aoutm68k_compat_43_sys_fstat(int fd, \ 238 struct aoutm68k_stat43 *sb); } fstat43 23963 NOARGS { int compat_43_sys_getkerninfo(int op, char *where, \ 240 int *size, int arg); } ogetkerninfo 24164 NOARGS { int compat_43_sys_getpagesize(void); } ogetpagesize 242#else 24362 EXCL aoutm68k_compat_43_sys_fstat 24463 EXCL compat_43_sys_getkerninfo 24564 EXCL compat_43_sys_getpagesize 246#endif 247#ifdef COMPAT_12 24865 NOARGS { int compat_12_sys_msync(caddr_t addr, size_t len); } 249#else 25065 EXCL compat_12_sys_msync 251#endif 252; XXX COMPAT_??? for 4.4BSD-compatible vfork(2)? 25366 NOARGS { int sys_vfork(void); } 25467 OBSOL vread 25568 OBSOL vwrite 25669 NOARGS { int sys_sbrk(intptr_t incr); } 25770 NOARGS { int sys_sstk(int incr); } 258#ifdef COMPAT_43 25971 NOARGS { int compat_43_sys_mmap(caddr_t addr, size_t len, \ 260 int prot, int flags, int fd, long pos); } ommap 261#else 26271 EXCL compat_43_sys_mmap 263#endif 26472 NOARGS { int sys_ovadvise(int anom); } vadvise 26573 NOARGS { int sys_munmap(void *addr, size_t len); } 26674 NOARGS { int sys_mprotect(void *addr, size_t len, \ 267 int prot); } 26875 NOARGS { int sys_madvise(void *addr, size_t len, \ 269 int behav); } 27076 OBSOL vhangup 27177 OBSOL vlimit 27278 NOARGS { int sys_mincore(caddr_t addr, size_t len, \ 273 char *vec); } 27479 NOARGS { int sys_getgroups(int gidsetsize, \ 275 gid_t *gidset); } 27680 NOARGS { int sys_setgroups(int gidsetsize, \ 277 const gid_t *gidset); } 27881 NOARGS { int sys_getpgrp(void); } 27982 NOARGS { int sys_setpgid(int pid, int pgid); } 28083 NOARGS { int sys_setitimer(int which, \ 281 const struct itimerval *itv, \ 282 struct itimerval *oitv); } 283#ifdef COMPAT_43 28484 NOARGS { int compat_43_sys_wait(void); } owait 285#else 28684 EXCL compat_43_sys_wait 287#endif 288#ifdef COMPAT_12 28985 NOARGS { int compat_12_sys_swapon(const char *name); } oswapon 290#else 29185 EXCL compat_12_sys_swapon 292#endif 29386 NOARGS { int sys_getitimer(int which, \ 294 struct itimerval *itv); } 295#ifdef COMPAT_43 29687 NOARGS { int compat_43_sys_gethostname(char *hostname, \ 297 u_int len); } ogethostname 29888 NOARGS { int compat_43_sys_sethostname(char *hostname, \ 299 u_int len); } osethostname 30089 NOARGS { int compat_43_sys_getdtablesize(void); } \ 301 ogetdtablesize 302#else 30387 EXCL compat_43_sys_gethostname 30488 EXCL compat_43_sys_sethostname 30589 EXCL compat_43_sys_getdtablesize 306#endif 30790 NOARGS { int sys_dup2(int from, int to); } 30891 UNIMPL getdopt 30992 NOARGS { int sys_fcntl(int fd, int cmd, ... void *arg); } 31093 NOARGS { int sys_select(int nd, fd_set *in, fd_set *ou, \ 311 fd_set *ex, struct timeval *tv); } 31294 UNIMPL setdopt 31395 NOARGS { int sys_fsync(int fd); } 31496 NOARGS { int sys_setpriority(int which, int who, int prio); } 31597 NOARGS { int sys_socket(int domain, int type, int protocol); } 31698 NOARGS { int sys_connect(int s, const struct sockaddr *name, \ 317 int namelen); } 318#ifdef COMPAT_43 31999 NOARGS { int compat_43_sys_accept(int s, caddr_t name, \ 320 int *anamelen); } oaccept 321#else 32299 EXCL compat_43_sys_accept 323#endif 324100 NOARGS { int sys_getpriority(int which, int who); } 325#ifdef COMPAT_43 326101 NOARGS { int compat_43_sys_send(int s, caddr_t buf, int len, \ 327 int flags); } osend 328102 NOARGS { int compat_43_sys_recv(int s, caddr_t buf, int len, \ 329 int flags); } orecv 330#else 331101 EXCL compat_43_sys_send 332102 EXCL compat_43_sys_recv 333#endif 334#ifdef COMPAT_13 335103 NOARGS { int compat_13_sys_sigreturn( \ 336 struct sigcontext13 *sigcntxp); } sigreturn13 337#else 338103 EXCL compat_13_sys_sigreturn 339#endif 340104 NOARGS { int sys_bind(int s, const struct sockaddr *name, \ 341 int namelen); } 342105 NOARGS { int sys_setsockopt(int s, int level, int name, \ 343 const void *val, int valsize); } 344106 NOARGS { int sys_listen(int s, int backlog); } 345107 OBSOL vtimes 346#ifdef COMPAT_43 347108 NOARGS { int compat_43_sys_sigvec(int signum, \ 348 struct sigvec *nsv, struct sigvec *osv); } osigvec 349109 NOARGS { int compat_43_sys_sigblock(int mask); } osigblock 350110 NOARGS { int compat_43_sys_sigsetmask(int mask); } osigsetmask 351#else 352108 EXCL compat_43_sys_sigvec 353109 EXCL compat_43_sys_sigblock 354110 EXCL compat_43_sys_sigsetmask 355#endif 356#ifdef COMPAT_13 357111 NOARGS { int compat_13_sys_sigsuspend(int mask); } sigsuspend13 358#else 359111 EXCL compat_13_sys_sigsuspend 360#endif 361#ifdef COMPAT_43 362112 NOARGS { int compat_43_sys_sigstack(struct sigstack *nss, \ 363 struct sigstack *oss); } osigstack 364113 NOARGS { int compat_43_sys_recvmsg(int s, \ 365 struct omsghdr *msg, int flags); } orecvmsg 366114 NOARGS { int compat_43_sys_sendmsg(int s, caddr_t msg, \ 367 int flags); } osendmsg 368#else 369112 EXCL compat_43_sys_sigstack 370113 EXCL compat_43_sys_recvmesg 371114 EXCL compat_43_sys_sendmesg 372#endif 373115 OBSOL vtrace 374116 NOARGS { int sys_gettimeofday(struct timeval *tp, \ 375 struct timezone *tzp); } 376117 NOARGS { int sys_getrusage(int who, struct rusage *rusage); } 377118 NOARGS { int sys_getsockopt(int s, int level, int name, \ 378 void *val, int *avalsize); } 379119 OBSOL resuba 380120 NOARGS { ssize_t sys_readv(int fd, \ 381 const struct iovec *iovp, int iovcnt); } 382121 NOARGS { ssize_t sys_writev(int fd, \ 383 const struct iovec *iovp, int iovcnt); } 384122 NOARGS { int sys_settimeofday(const struct timeval *tv, \ 385 const struct timezone *tzp); } 386123 NOARGS { int sys_fchown(int fd, uid_t uid, gid_t gid); } 387124 NOARGS { int sys_fchmod(int fd, mode_t mode); } 388#ifdef COMPAT_43 389125 NOARGS { int compat_43_sys_recvfrom(int s, caddr_t buf, \ 390 size_t len, int flags, caddr_t from, \ 391 int *fromlenaddr); } orecvfrom 392#else 393125 EXCL compat_43_sys_recvfrom 394#endif 395126 NOARGS { int sys_setreuid(uid_t ruid, uid_t euid); } 396127 NOARGS { int sys_setregid(gid_t rgid, gid_t egid); } 397#ifdef COMPAT_AOUT_ALTPATH 398128 STD { int aoutm68k_sys_rename(const char *from, \ 399 const char *to); } 400#else 401128 NOARGS { int sys_rename(const char *from, const char *to); } 402#endif 403#ifdef COMPAT_43 404#ifdef COMPAT_AOUT_ALTPATH 405129 STD { int aoutm68k_compat_43_sys_truncate(const char *path, \ 406 long length); } otruncate 407#else 408129 NOARGS { int compat_43_sys_truncate(const char *path, \ 409 long length); } otruncate 410#endif 411130 NOARGS { int compat_43_sys_ftruncate(int fd, long length); } \ 412 oftruncate 413#else 414#ifdef COMPAT_AOUT_ALTPATH 415129 EXCL aoutm68k_compat_43_sys_truncate 416#else 417129 EXCL compat_43_sys_truncate 418#endif 419130 EXCL compat_43_sys_ftruncate 420#endif 421131 NOARGS { int sys_flock(int fd, int how); } 422132 NOARGS { int sys_mkfifo(const char *path, mode_t mode); } 423133 NOARGS { ssize_t sys_sendto(int s, const void *buf, \ 424 size_t len, int flags, const struct sockaddr *to, \ 425 int tolen); } 426134 NOARGS { int sys_shutdown(int s, int how); } 427135 NOARGS { int sys_socketpair(int domain, int type, \ 428 int protocol, int *rsv); } 429136 NOARGS { int sys_mkdir(const char *path, mode_t mode); } 430#ifdef COMPAT_AOUT_ALTPATH 431137 STD { int aoutm68k_sys_rmdir(const char *path); } 432138 STD { int aoutm68k_sys_utimes(const char *path, \ 433 const struct timeval *tptr); } 434#else 435137 NOARGS { int sys_rmdir(const char *path); } 436138 NOARGS { int sys_utimes(const char *path, \ 437 const struct timeval *tptr); } 438#endif 439139 OBSOL 4.2 sigreturn 440140 NOARGS { int sys_adjtime(const struct timeval *delta, \ 441 struct timeval *olddelta); } 442#ifdef COMPAT_43 443141 NOARGS { int compat_43_sys_getpeername(int fdes, caddr_t asa, \ 444 int *alen); } ogetpeername 445142 NOARGS { int32_t compat_43_sys_gethostid(void); } ogethostid 446143 NOARGS { int compat_43_sys_sethostid(int32_t hostid); } \ 447 osethostid 448144 NOARGS { int compat_43_sys_getrlimit(int which, \ 449 struct orlimit *rlp); } ogetrlimit 450145 NOARGS { int compat_43_sys_setrlimit(int which, \ 451 const struct orlimit *rlp); } osetrlimit 452146 NOARGS { int compat_43_sys_killpg(int pgid, int signum); } \ 453 okillpg 454#else 455141 EXCL compat_43_sys_getpeername 456142 EXCL compat_43_sys_gethostid 457143 EXCL compat_43_sys_sethostid 458144 EXCL compat_43_sys_getrlimit 459145 EXCL compat_43_sys_setrlimit 460146 EXCL compat_43_sys_killpg 461#endif 462147 NOARGS { int sys_setsid(void); } 463148 NOARGS { int sys_quotactl(const char *path, \ 464 int cmd, int uid, caddr_t arg); } 465#ifdef COMPAT_43 466149 NOARGS { int compat_43_sys_quota(void); } oquota 467150 NOARGS { int compat_43_sys_getsockname(int fdec, caddr_t asa, \ 468 int *alen); } ogetsockname 469#else 470149 EXCL compat_43_sys_quota 471150 EXCL compat_43_sys_getsockname 472#endif 473 474; Syscalls 151-180 inclusive are reserved for vendor-specific 475; system calls. (This includes various calls added for compatibity 476; with other Unix variants.) 477; Some of these calls are now supported by BSD... 478151 UNIMPL 479152 UNIMPL 480153 UNIMPL 481154 UNIMPL 482#if defined(NFS) || defined(NFSSERVER) || !defined(_KERNEL) 483155 NOARGS { int sys_nfssvc(int flag, void *argp); } 484#else 485155 EXCL nfssvc 486#endif 487#ifdef COMPAT_43 488156 NOARGS { int compat_43_sys_getdirentries(int fd, char *buf, \ 489 u_int count, long *basep); } ogetdirentries 490#else 491156 EXCL compat_43_sys_getdirentries 492#endif 493#ifdef COMPAT_AOUT_ALTPATH 494157 STD { int aoutm68k_sys_statfs(const char *path, \ 495 struct statfs *buf); } 496#else 497157 NOARGS { int sys_statfs(const char *path, \ 498 struct statfs *buf); } 499#endif 500158 NOARGS { int sys_fstatfs(int fd, struct statfs *buf); } 501159 UNIMPL 502160 UNIMPL 503#if defined(NFS) || defined(NFSSERVER) || !defined(_KERNEL) 504#ifdef COMPAT_AOUT_ALTPATH 505161 STD { int aoutm68k_sys_getfh(const char *fname, \ 506 fhandle_t *fhp); } 507#else 508161 NOARGS { int sys_getfh(const char *fname, fhandle_t *fhp); } 509#endif 510#else 511161 EXCL getfh 512#endif 513#ifdef COMPAT_09 514162 NOARGS { int compat_09_sys_getdomainname(char *domainname, \ 515 int len); } ogetdomainname 516163 NOARGS { int compat_09_sys_setdomainname(char *domainname, \ 517 int len); } osetdomainname 518164 NOARGS { int compat_09_sys_uname(struct outsname *name); } \ 519 ouname 520#else 521162 EXCL compat_09_sys_getdomainname 522163 EXCL compat_09_sys_setdomainname 523164 EXCL compat_09_sys_uname 524#endif 525165 NOARGS { int sys_sysarch(int op, void *parms); } 526166 UNIMPL 527167 UNIMPL 528168 UNIMPL 529; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 530#if (defined(SYSVSEM) || !defined(_KERNEL)) && !defined(_LP64) && defined(COMPAT_10) 531169 NOARGS { int compat_10_sys_semsys(int which, int a2, int a3, \ 532 int a4, int a5); } osemsys 533#else 534169 EXCL 1.0 semsys 535#endif 536; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 537#if (defined(SYSVMSG) || !defined(_KERNEL)) && !defined(_LP64) && defined(COMPAT_10) 538170 NOARGS { int compat_10_sys_msgsys(int which, int a2, int a3, \ 539 int a4, int a5, int a6); } omsgsys 540#else 541170 EXCL 1.0 msgsys 542#endif 543; XXX more generally, never on machines where sizeof(void *) != sizeof(int) 544#if (defined(SYSVSHM) || !defined(_KERNEL)) && !defined(_LP64) && defined(COMPAT_10) 545171 NOARGS { int compat_10_sys_shmsys(int which, int a2, int a3, \ 546 int a4); } oshmsys 547#else 548171 EXCL 1.0 shmsys 549#endif 550172 UNIMPL 551173 NOARGS { ssize_t sys_pread(int fd, void *buf, \ 552 size_t nbyte, int pad, off_t offset); } 553174 NOARGS { ssize_t sys_pwrite(int fd, const void *buf, \ 554 size_t nbyte, int pad, off_t offset); } 555; For some reason, ntp_gettime doesn't want to raise SIGSYS when it's excluded. 556175 NOARGS { int sys_ntp_gettime(struct ntptimeval *ntvp); } 557#if defined(NTP) || !defined(_KERNEL) 558176 NOARGS { int sys_ntp_adjtime(struct timex *tp); } 559#else 560176 EXCL ntp_adjtime 561#endif 562177 UNIMPL 563178 UNIMPL 564179 UNIMPL 565180 UNIMPL 566 567; Syscalls 180-199 are used by/reserved for BSD 568181 NOARGS { int sys_setgid(gid_t gid); } 569182 NOARGS { int sys_setegid(gid_t egid); } 570183 NOARGS { int sys_seteuid(uid_t euid); } 571#if defined(LFS) || !defined(_KERNEL) 572184 NOARGS { int sys_lfs_bmapv(fsid_t *fsidp, \ 573 struct block_info *blkiov, int blkcnt); } 574185 NOARGS { int sys_lfs_markv(fsid_t *fsidp, \ 575 struct block_info *blkiov, int blkcnt); } 576186 NOARGS { int sys_lfs_segclean(fsid_t *fsidp, u_long segment); } 577187 NOARGS { int sys_lfs_segwait(fsid_t *fsidp, \ 578 struct timeval *tv); } 579#else 580184 EXCL lfs_bmapv 581185 EXCL lfs_markv 582186 EXCL lfs_segclean 583187 EXCL lfs_segwait 584#endif 585#ifdef COMPAT_12 586188 STD { int aoutm68k_compat_12_sys_stat(const char *path, \ 587 struct aoutm68k_stat12 *ub); } stat12 588189 STD { int aoutm68k_compat_12_sys_fstat(int fd, \ 589 struct aoutm68k_stat12 *sb); } fstat12 590190 STD { int aoutm68k_compat_12_sys_lstat(const char *path, \ 591 struct aoutm68k_stat12 *ub); } lstat12 592#else 593188 EXCL aoutm68k_compat_12_sys_stat 594189 EXCL aoutm68k_compat_12_sys_fstat 595190 EXCL aoutm68k_compat_12_sys_lstat 596#endif 597#ifdef COMPAT_AOUT_ALTPATH 598191 STD { long aoutm68k_sys_pathconf(const char *path, \ 599 int name); } 600#else 601191 NOARGS { long sys_pathconf(const char *path, int name); } 602#endif 603192 NOARGS { long sys_fpathconf(int fd, int name); } 604193 UNIMPL 605194 NOARGS { int sys_getrlimit(int which, \ 606 struct rlimit *rlp); } 607195 NOARGS { int sys_setrlimit(int which, \ 608 const struct rlimit *rlp); } 609#ifdef COMPAT_12 610196 NOARGS { int compat_12_sys_getdirentries(int fd, char *buf, \ 611 u_int count, long *basep); } 612#else 613196 EXCL compat_12_sys_getdirentries 614#endif 615197 NOARGS { void *sys_mmap(void *addr, size_t len, int prot, \ 616 int flags, int fd, long pad, off_t pos); } 617198 INDIR { quad_t sys___syscall(quad_t num, ...); } 618199 NOARGS { off_t sys_lseek(int fd, int pad, off_t offset, \ 619 int whence); } 620#ifdef COMPAT_AOUT_ALTPATH 621200 STD { int aoutm68k_sys_truncate(const char *path, int pad, \ 622 off_t length); } 623#else 624200 NOARGS { int sys_truncate(const char *path, int pad, \ 625 off_t length); } 626#endif 627201 NOARGS { int sys_ftruncate(int fd, int pad, off_t length); } 628202 NOARGS { int sys___sysctl(int *name, u_int namelen, \ 629 void *old, size_t *oldlenp, void *new, \ 630 size_t newlen); } 631203 NOARGS { int sys_mlock(const void *addr, size_t len); } 632204 NOARGS { int sys_munlock(const void *addr, size_t len); } 633#ifdef COMPAT_AOUT_ALTPATH 634205 STD { int aoutm68k_sys_undelete(const char *path); } 635#else 636205 NOARGS { int sys_undelete(const char *path); } 637#endif 638206 NOARGS { int sys_futimes(int fd, \ 639 const struct timeval *tptr); } 640207 NOARGS { pid_t sys_getpgid(pid_t pid); } 641208 NOARGS { int sys_reboot(int opt, char *bootstr); } 642209 NOARGS { int sys_poll(struct pollfd *fds, u_int nfds, \ 643 int timeout); } 644; 645; Syscalls 210-219 are reserved for dynamically loaded syscalls 646; 647#if defined(LKM) || !defined(_KERNEL) 648210 NODEF { int sys_lkmnosys(void); } 649211 NODEF { int sys_lkmnosys(void); } 650212 NODEF { int sys_lkmnosys(void); } 651213 NODEF { int sys_lkmnosys(void); } 652214 NODEF { int sys_lkmnosys(void); } 653215 NODEF { int sys_lkmnosys(void); } 654216 NODEF { int sys_lkmnosys(void); } 655217 NODEF { int sys_lkmnosys(void); } 656218 NODEF { int sys_lkmnosys(void); } 657219 NODEF { int sys_lkmnosys(void); } 658#else /* !LKM */ 659210 EXCL lkmnosys 660211 EXCL lkmnosys 661212 EXCL lkmnosys 662213 EXCL lkmnosys 663214 EXCL lkmnosys 664215 EXCL lkmnosys 665216 EXCL lkmnosys 666217 EXCL lkmnosys 667218 EXCL lkmnosys 668219 EXCL lkmnosys 669#endif /* !LKM */ 670; System calls 220-300 are reserved for use by NetBSD 671#if defined(SYSVSEM) || !defined(_KERNEL) 672#ifdef COMPAT_14 673220 NOARGS { int compat_14_sys___semctl(int semid, \ 674 int semnum, int cmd, union __semun *arg); } 675#else 676220 EXCL compat_14_semctl 677#endif 678221 NOARGS { int sys_semget(key_t key, int nsems, int semflg); } 679222 NOARGS { int sys_semop(int semid, struct sembuf *sops, \ 680 size_t nsops); } 681223 NOARGS { int sys_semconfig(int flag); } 682#else 683220 EXCL compat_14_semctl 684221 EXCL semget 685222 EXCL semop 686223 EXCL semconfig 687#endif 688#if defined(SYSVMSG) || !defined(_KERNEL) 689#ifdef COMPAT_14 690224 NOARGS { int compat_14_sys_msgctl(int msqid, int cmd, \ 691 struct msqid_ds14 *buf); } 692#else 693224 EXCL compat_14_sys_msgctl 694#endif 695225 NOARGS { int sys_msgget(key_t key, int msgflg); } 696226 NOARGS { int sys_msgsnd(int msqid, const void *msgp, \ 697 size_t msgsz, int msgflg); } 698227 NOARGS { ssize_t sys_msgrcv(int msqid, void *msgp, \ 699 size_t msgsz, long msgtyp, int msgflg); } 700#else 701224 EXCL compat_14_msgctl 702225 EXCL msgget 703226 EXCL msgsnd 704227 EXCL msgrcv 705#endif 706#if defined(SYSVSHM) || !defined(_KERNEL) 707228 NOARGS { void *sys_shmat(int shmid, const void *shmaddr, \ 708 int shmflg); } 709#ifdef COMPAT_14 710229 NOARGS { int compat_14_sys_shmctl(int shmid, int cmd, \ 711 struct shmid_ds14 *buf); } 712#else 713229 EXCL compat_14_sys_shmctl 714#endif 715230 NOARGS { int sys_shmdt(const void *shmaddr); } 716231 NOARGS { int sys_shmget(key_t key, size_t size, int shmflg); } 717#else 718228 EXCL shmat 719229 EXCL compat_14_shmctl 720230 EXCL shmdt 721231 EXCL shmget 722#endif 723232 NOARGS { int sys_clock_gettime(clockid_t clock_id, \ 724 struct timespec *tp); } 725233 NOARGS { int sys_clock_settime(clockid_t clock_id, \ 726 const struct timespec *tp); } 727234 NOARGS { int sys_clock_getres(clockid_t clock_id, \ 728 struct timespec *tp); } 729235 UNIMPL timer_create 730236 UNIMPL timer_delete 731237 UNIMPL timer_settime 732238 UNIMPL timer_gettime 733239 UNIMPL timer_getoverrun 734; 735; Syscalls 240-269 are reserved for other IEEE Std1003.1b syscalls 736; 737240 NOARGS { int sys_nanosleep(const struct timespec *rqtp, \ 738 struct timespec *rmtp); } 739241 NOARGS { int sys_fdatasync(int fd); } 740242 NOARGS { int sys_mlockall(int flags); } 741243 NOARGS { int sys_munlockall(void); } 742244 UNIMPL 743245 UNIMPL 744246 UNIMPL 745247 UNIMPL 746248 UNIMPL 747249 UNIMPL 748250 UNIMPL 749251 UNIMPL 750252 UNIMPL 751253 UNIMPL 752254 UNIMPL 753255 UNIMPL 754256 UNIMPL 755257 UNIMPL 756258 UNIMPL 757259 UNIMPL 758260 UNIMPL 759261 UNIMPL 760262 UNIMPL 761263 UNIMPL 762264 UNIMPL 763265 UNIMPL 764266 UNIMPL 765267 UNIMPL 766268 UNIMPL 767269 UNIMPL 768#ifdef COMPAT_AOUT_ALTPATH 769270 STD { int aoutm68k_sys___posix_rename(const char *from, \ 770 const char *to); } 771#else 772270 NOARGS { int sys___posix_rename(const char *from, \ 773 const char *to); } 774#endif 775271 NOARGS { int sys_swapctl(int cmd, const void *arg, int misc); } 776272 NOARGS { int sys_getdents(int fd, char *buf, size_t count); } 777273 NOARGS { int sys_minherit(void *addr, size_t len, \ 778 int inherit); } 779#ifdef COMPAT_AOUT_ALTPATH 780274 STD { int aoutm68k_sys_lchmod(const char *path, \ 781 mode_t mode); } 782275 STD { int aoutm68k_sys_lchown(const char *path, uid_t uid, \ 783 gid_t gid); } 784276 STD { int aoutm68k_sys_lutimes(const char *path, \ 785 const struct timeval *tptr); } 786#else 787274 NOARGS { int sys_lchmod(const char *path, mode_t mode); } 788275 NOARGS { int sys_lchown(const char *path, uid_t uid, \ 789 gid_t gid); } 790276 NOARGS { int sys_lutimes(const char *path, \ 791 const struct timeval *tptr); } 792#endif 793277 NOARGS { int sys___msync13(void *addr, size_t len, int flags); } 794278 STD { int aoutm68k_sys___stat13(const char *path, \ 795 struct aoutm68k_stat *ub); } 796279 STD { int aoutm68k_sys___fstat13(int fd, \ 797 struct aoutm68k_stat *sb); } 798280 STD { int aoutm68k_sys___lstat13(const char *path, \ 799 struct aoutm68k_stat *ub); } 800281 NOARGS { int sys___sigaltstack14( \ 801 const struct sigaltstack *nss, \ 802 struct sigaltstack *oss); } 803282 NOARGS { int sys___vfork14(void); } 804#ifdef COMPAT_AOUT_ALTPATH 805283 STD { int aoutm68k_sys___posix_chown(const char *path, \ 806 uid_t uid, gid_t gid); } 807#else 808283 NOARGS { int sys___posix_chown(const char *path, uid_t uid, \ 809 gid_t gid); } 810#endif 811284 NOARGS { int sys___posix_fchown(int fd, uid_t uid, \ 812 gid_t gid); } 813285 NOARGS { int sys___posix_lchown(const char *path, uid_t uid, \ 814 gid_t gid); } 815286 NOARGS { pid_t sys_getsid(pid_t pid); } 816287 UNIMPL 817#if defined(KTRACE) || !defined(_KERNEL) 818288 NOARGS { int sys_fktrace(const int fd, int ops, \ 819 int facs, int pid); } 820#else 821288 EXCL ktrace 822#endif 823289 NOARGS { ssize_t sys_preadv(int fd, \ 824 const struct iovec *iovp, int iovcnt, \ 825 int pad, off_t offset); } 826290 NOARGS { ssize_t sys_pwritev(int fd, \ 827 const struct iovec *iovp, int iovcnt, \ 828 int pad, off_t offset); } 829#ifdef COMPAT_16 830291 NOARGS { int compat_16_sys___sigaction14(int signum, \ 831 const struct sigaction *nsa, \ 832 struct sigaction *osa); } 833#else 834291 EXCL compat_16_sys___sigaction14 835#endif 836292 NOARGS { int sys___sigpending14(sigset_t *set); } 837293 NOARGS { int sys___sigprocmask14(int how, \ 838 const sigset_t *set, \ 839 sigset_t *oset); } 840294 NOARGS { int sys___sigsuspend14(const sigset_t *set); } 841#ifdef COMPAT_16 842295 NOARGS { int compat_16_sys___sigreturn14(\ 843 struct sigcontext *sigcntxp); } 844#else 845295 EXCL compat_16_sys___sigreturn14 846#endif 847296 NOARGS { int sys___getcwd(char *bufp, size_t length); } 848297 NOARGS { int sys_fchroot(int fd); } 849298 NOARGS { int sys_fhopen(const fhandle_t *fhp, int flags); } 850299 STD { int aoutm68k_sys_fhstat(const fhandle_t *fhp, \ 851 struct aoutm68k_stat *sb); } 852300 NOARGS { int sys_fhstatfs(const fhandle_t *fhp, \ 853 struct statfs *buf); } 854#if defined(SYSVSEM) || !defined(_KERNEL) 855301 NOARGS { int sys_____semctl13(int semid, int semnum, int cmd, \ 856 ... union __semun *arg); } 857#else 858301 EXCL ____semctl13 859#endif 860#if defined(SYSVMSG) || !defined(_KERNEL) 861302 NOARGS { int sys___msgctl13(int msqid, int cmd, \ 862 struct msqid_ds *buf); } 863#else 864302 EXCL __msgctl13 865#endif 866#if defined(SYSVSHM) || !defined(_KERNEL) 867303 NOARGS { int sys___shmctl13(int shmid, int cmd, \ 868 struct shmid_ds *buf); } 869#else 870303 EXCL __shmctl13 871#endif 872304 NOARGS { int sys_lchflags(const char *path, u_long flags); } 873305 NOARGS { int sys_issetugid(void); } 874306 NOARGS { int sys_getcontext(struct __ucontext *ucp); } 875307 NOARGS { int sys_setcontext(const struct __ucontext *ucp); } 876