Home | History | Annotate | Line # | Download | only in aoutm68k
      1 	$NetBSD: syscalls.master,v 1.44 2019/06/18 01:39:01 christos 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 #include "opt_quota.h"
     45 #endif
     46 
     47 #include <sys/param.h>
     48 #include <sys/systm.h>
     49 #include <sys/signal.h>
     50 #include <sys/mount.h>
     51 #include <sys/sched.h>
     52 #include <sys/syscallargs.h>
     53 #include <compat/aoutm68k/aoutm68k_syscallargs.h>
     54 
     55 %%
     56 
     57 ; Reserved/unimplemented system calls in the range 0-150 inclusive
     58 ; are reserved for use in future Berkeley releases.
     59 ; Additional system calls implemented in vendor and other
     60 ; redistributions should be placed in the reserved range at the end
     61 ; of the current calls.
     62 
     63 0	NOARGS INDIR	{ int|sys||syscall(int code, \
     64 			    ... register32_t args[AOUTM68K_SYS_MAXSYSARGS]); }
     65 1	NOARGS		{ void|sys||exit(int rval); }
     66 2	NOARGS		{ int|sys||fork(void); }
     67 3	NOARGS		{ ssize_t|sys||read(int fd, void *buf, size_t nbyte); }
     68 4	NOARGS		{ ssize_t|sys||write(int fd, const void *buf, \
     69 			    size_t nbyte); }
     70 5	NOARGS		{ int|sys||open(const char *path, int flags, \
     71 			    ... mode_t mode); }
     72 6	NOARGS		{ int|sys||close(int fd); }
     73 7	NOARGS		{ int|compat_50_sys||wait4(int pid, int *status, \
     74 			    int options, struct rusage50 *rusage); }
     75 #if defined(COMPAT_43) || !defined(_KERNEL)
     76 8	NOARGS		{ int|compat_43_sys||creat(const char *path, \
     77 			    mode_t mode); } ocreat
     78 #else
     79 8	EXCL		compat_43_sys_creat
     80 #endif
     81 9	NOARGS		{ int|sys||link(const char *path, const char *link); }
     82 10	NOARGS		{ int|sys||unlink(const char *path); }
     83 11	OBSOL		execv
     84 12	NOARGS		{ int|sys||chdir(const char *path); }
     85 13	NOARGS		{ int|sys||fchdir(int fd); }
     86 14	NOARGS		{ int|compat_50_sys||mknod(const char *path, \
     87 			    mode_t mode, dev_t dev); }
     88 15	NOARGS		{ int|sys||chmod(const char *path, mode_t mode); }
     89 16	NOARGS		{ int|sys||chown(const char *path, uid_t uid, \
     90 			    gid_t gid); }
     91 17	NOARGS		{ int|sys||obreak(char *nsize); } break
     92 #if defined(COMPAT_20) || !defined(_KERNEL)
     93 18	NOARGS		{ int|compat_20_sys||getfsstat(struct statfs12 *buf, \
     94 			    long bufsize, int flags); }
     95 #else
     96 18	EXCL		compat_20_sys_getfsstat
     97 #endif
     98 #if defined(COMPAT_43) || !defined(_KERNEL)
     99 19	NOARGS		{ long|compat_43_sys||lseek(int fd, long offset, \
    100 			    int whence); } olseek
    101 #else
    102 19	EXCL		compat_43_sys_lseek
    103 #endif
    104 20	NOARGS 		{ pid_t|sys||getpid(void); }
    105 21	NOARGS		{ int|compat_40_sys||mount(const char *type, \
    106 			    const char *path, int flags, void *data); }
    107 22	NOARGS		{ int|sys||unmount(const char *path, int flags); }
    108 23	NOARGS		{ int|sys||setuid(uid_t uid); }
    109 24	NOARGS		{ uid_t|sys||getuid(void); }
    110 25	NOARGS		{ uid_t|sys||geteuid(void); }
    111 26	NOARGS		{ int|sys||ptrace(int req, pid_t pid, void *addr, \
    112 			    int data); }
    113 27	NOARGS		{ ssize_t|sys||recvmsg(int s, struct msghdr *msg, \
    114 			    int flags); }
    115 28	NOARGS		{ ssize_t|sys||sendmsg(int s, \
    116 			    const struct msghdr *msg, int flags); }
    117 29	NOARGS		{ ssize_t|sys||recvfrom(int s, void *buf, size_t len, \
    118 			    int flags, struct sockaddr *from, \
    119 			    unsigned int *fromlenaddr); }
    120 30	NOARGS		{ int|sys||accept(int s, struct sockaddr *name, \
    121 			    unsigned int *anamelen); }
    122 31	NOARGS		{ int|sys||getpeername(int fdes, struct sockaddr *asa, \
    123 			    unsigned int *alen); }
    124 32	NOARGS		{ int|sys||getsockname(int fdes, struct sockaddr *asa, \
    125 			    unsigned int *alen); }
    126 33	NOARGS		{ int|sys||access(const char *path, int flags); }
    127 34	NOARGS		{ int|sys||chflags(const char *path, u_long flags); }
    128 35	NOARGS		{ int|sys||fchflags(int fd, u_long flags); }
    129 36	NOARGS		{ void|sys||sync(void); }
    130 37	NOARGS		{ int|sys||kill(int pid, int signum); }
    131 #if defined(COMPAT_43) || !defined(_KERNEL)
    132 38	STD		{ int|aoutm68k_compat_43_sys||stat(const char *path, \
    133 			    struct aoutm68k_stat43 *ub); } stat43
    134 #else
    135 38	EXCL		aoutm68k_compat_43_sys_stat
    136 #endif
    137 39	NOARGS		{ pid_t|sys||getppid(void); }
    138 #if defined(COMPAT_43) || !defined(_KERNEL)
    139 40	STD		{ int|aoutm68k_compat_43_sys||lstat(const char *path, \
    140 			    struct aoutm68k_stat43 *ub); } lstat43
    141 #else
    142 40	EXCL		aoutm68k_compat_43_sys_lstat
    143 #endif
    144 41	NOARGS		{ int|sys||dup(int fd); }
    145 42	NOARGS		{ int|sys||pipe(void); }
    146 43	NOARGS		{ gid_t|sys||getegid(void); }
    147 44	NOARGS		{ int|sys||profil(void *samples, size_t size, \
    148 			    u_long offset, u_int scale); }
    149 #if defined(KTRACE) || !defined(_KERNEL)
    150 45	NOARGS		{ int|sys||ktrace(const char *fname, int ops, \
    151 			    int facs, int pid); }
    152 #else
    153 45	EXCL		ktrace
    154 #endif
    155 #if defined(COMPAT_13) || !defined(_KERNEL)
    156 46	NOARGS		{ int|compat_13_sys||sigaction(int signum, \
    157 			    const struct sigaction13 *nsa, \
    158 			    struct sigaction13 *osa); } sigaction13
    159 #else
    160 46	EXCL		compat_13_sys_sigaction
    161 #endif
    162 47	NOARGS		{ gid_t|sys||getgid(void); }
    163 #if defined(COMPAT_13) || !defined(_KERNEL)
    164 48	NOARGS		{ int|compat_13_sys||sigprocmask(int how, \
    165 			    int mask); } sigprocmask13
    166 #else
    167 48	EXCL		compat_13_sys_sigprocmask
    168 #endif
    169 49	NOARGS		{ int|sys||__getlogin(char *namebuf, size_t namelen); }
    170 50	NOARGS		{ int|sys||__setlogin(const char *namebuf); }
    171 51	NOARGS		{ int|sys||acct(const char *path); }
    172 #if defined(COMPAT_13) || !defined(_KERNEL)
    173 52	NOARGS		{ int|compat_13_sys||sigpending(void); } sigpending13
    174 53	NOARGS		{ int|compat_13_sys||sigaltstack( \
    175 			    const struct sigaltstack13 *nss, \
    176 			    struct sigaltstack13 *oss); } sigaltstack13
    177 #else
    178 52	EXCL		compat_13_sys_sigpending
    179 53	EXCL		compat_13_sys_sigaltstack
    180 #endif
    181 54	NOARGS		{ int|sys||ioctl(int fd, u_long com, ... void *data); }
    182 #if defined(COMPAT_12) || !defined(_KERNEL)
    183 55	NOARGS		{ int|compat_12_sys||reboot(int opt); } oreboot
    184 #else
    185 55	EXCL		compat_12_sys_reboot
    186 #endif
    187 56	NOARGS		{ int|sys||revoke(const char *path); }
    188 57	NOARGS		{ int|sys||symlink(const char *path, \
    189 			    const char *link); }
    190 58	NOARGS		{ int|sys||readlink(const char *path, \
    191 			    char *buf, size_t count); }
    192 59	NOARGS		{ int|sys||execve(const char *path, \
    193 			    char * const *argp, char * const *envp); }
    194 60	NOARGS		{ mode_t|sys||umask(mode_t newmask); }
    195 61	NOARGS		{ int|sys||chroot(const char *path); }
    196 #if defined(COMPAT_43) || !defined(_KERNEL)
    197 62	STD		{ int|aoutm68k_compat_43_sys||fstat(int fd, \
    198 			    struct aoutm68k_stat43 *sb); } fstat43
    199 63	NOARGS		{ int|compat_43_sys||getkerninfo(int op, char *where, \
    200 			    int *size, int arg); } ogetkerninfo
    201 64	NOARGS		{ int|compat_43_sys||getpagesize(void); } ogetpagesize
    202 #else
    203 62	EXCL		aoutm68k_compat_43_sys_fstat
    204 63	EXCL		compat_43_sys_getkerninfo
    205 64	EXCL		compat_43_sys_getpagesize
    206 #endif
    207 #if defined(COMPAT_12) || !defined(_KERNEL)
    208 65	NOARGS		{ int|compat_12_sys||msync(void *addr, size_t len); }
    209 #else
    210 65	EXCL		compat_12_sys_msync
    211 #endif
    212 ; XXX COMPAT_??? for 4.4BSD-compatible vfork(2)?
    213 66	NOARGS		{ int|sys||vfork(void); }
    214 67	OBSOL		vread
    215 68	OBSOL		vwrite
    216 69	OBSOL		sbrk
    217 70	OBSOL		sstk
    218 #if defined(COMPAT_43) || !defined(_KERNEL)
    219 71	NOARGS		{ int|compat_43_sys||mmap(void *addr, size_t len, \
    220 			    int prot, int flags, int fd, long pos); } ommap
    221 #else
    222 71	EXCL		compat_43_sys_mmap
    223 #endif
    224 72	NOARGS		{ int|sys||ovadvise(int anom); } vadvise
    225 73	NOARGS		{ int|sys||munmap(void *addr, size_t len); }
    226 74	NOARGS		{ int|sys||mprotect(void *addr, size_t len, \
    227 			    int prot); }
    228 75	NOARGS		{ int|sys||madvise(void *addr, size_t len, \
    229 			    int behav); }
    230 76	OBSOL		vhangup
    231 77	OBSOL		vlimit
    232 78	NOARGS		{ int|sys||mincore(void *addr, size_t len, \
    233 			    char *vec); }
    234 79	NOARGS		{ int|sys||getgroups(int gidsetsize, \
    235 			    gid_t *gidset); }
    236 80	NOARGS		{ int|sys||setgroups(int gidsetsize, \
    237 			    const gid_t *gidset); }
    238 81	NOARGS		{ int|sys||getpgrp(void); }
    239 82	NOARGS		{ int|sys||setpgid(int pid, int pgid); }
    240 83	NOARGS		{ int|compat_50_sys||setitimer(int which, \
    241 			    const struct itimerval50 *itv, \
    242 			    struct itimerval50 *oitv); }
    243 #if defined(COMPAT_43) || !defined(_KERNEL)
    244 84	NOARGS		{ int|compat_43_sys||wait(void); } owait
    245 #else
    246 84	EXCL		compat_43_sys_wait
    247 #endif
    248 #if defined(COMPAT_12) || !defined(_KERNEL)
    249 85	NOARGS		{ int|compat_12_sys||swapon(const char *name); } oswapon
    250 #else
    251 85	EXCL		compat_12_sys_swapon
    252 #endif
    253 86	NOARGS		{ int|compat_50_sys||getitimer(int which, \
    254 			    struct itimerval50 *itv); }
    255 #if defined(COMPAT_43) || !defined(_KERNEL)
    256 87	NOARGS		{ int|compat_43_sys||gethostname(char *hostname, \
    257 			    u_int len); } ogethostname
    258 88	NOARGS		{ int|compat_43_sys||sethostname(char *hostname, \
    259 			    u_int len); } osethostname
    260 89	NOARGS		{ int|compat_43_sys||getdtablesize(void); } \
    261 			    ogetdtablesize
    262 #else
    263 87	EXCL		compat_43_sys_gethostname
    264 88	EXCL		compat_43_sys_sethostname
    265 89	EXCL		compat_43_sys_getdtablesize
    266 #endif
    267 90	NOARGS		{ int|sys||dup2(int from, int to); }
    268 91	UNIMPL		getdopt
    269 92	NOARGS		{ int|sys||fcntl(int fd, int cmd, ... void *arg); }
    270 93	NOARGS		{ int|compat_50_sys||select(int nd, fd_set *in, \
    271 			    fd_set *ou, fd_set *ex, struct timeval50 *tv); }
    272 94	UNIMPL		setdopt
    273 95	NOARGS		{ int|sys||fsync(int fd); }
    274 96	NOARGS		{ int|sys||setpriority(int which, int who, int prio); }
    275 #if defined(COMPAT_30) || !defined(_KERNEL)
    276 97	NOARGS		{ int|compat_30_sys||socket(int domain, int type, int protocol); }
    277 #else
    278 97	EXCL		compat_30_sys_socket
    279 #endif
    280 98	NOARGS		{ int|sys||connect(int s, const struct sockaddr *name, \
    281 			    int namelen); }
    282 #if defined(COMPAT_43) || !defined(_KERNEL)
    283 99	NOARGS		{ int|compat_43_sys||accept(int s, void *name, \
    284 			    int *anamelen); } oaccept
    285 #else
    286 99	EXCL		compat_43_sys_accept
    287 #endif
    288 100	NOARGS		{ int|sys||getpriority(int which, int who); }
    289 #if defined(COMPAT_43) || !defined(_KERNEL)
    290 101	NOARGS		{ int|compat_43_sys||send(int s, void *buf, int len, \
    291 			    int flags); } osend
    292 102	NOARGS		{ int|compat_43_sys||recv(int s, void *buf, int len, \
    293 			    int flags); } orecv
    294 #else
    295 101	EXCL		compat_43_sys_send
    296 102	EXCL		compat_43_sys_recv
    297 #endif
    298 #if defined(COMPAT_13) || !defined(_KERNEL)
    299 103	NOARGS		{ int|compat_13_sys||sigreturn( \
    300 			    struct sigcontext13 *sigcntxp); } sigreturn13
    301 #else
    302 103	EXCL		compat_13_sys_sigreturn
    303 #endif
    304 104	NOARGS		{ int|sys||bind(int s, const struct sockaddr *name, \
    305 			    int namelen); }
    306 105	NOARGS		{ int|sys||setsockopt(int s, int level, int name, \
    307 			    const void *val, int valsize); }
    308 106	NOARGS		{ int|sys||listen(int s, int backlog); }
    309 107	OBSOL		vtimes
    310 #if defined(COMPAT_43) || !defined(_KERNEL)
    311 108	NOARGS		{ int|compat_43_sys||sigvec(int signum, \
    312 			    struct sigvec *nsv, struct sigvec *osv); } osigvec
    313 109	NOARGS		{ int|compat_43_sys||sigblock(int mask); } osigblock
    314 110	NOARGS		{ int|compat_43_sys||sigsetmask(int mask); } osigsetmask
    315 #else
    316 108	EXCL		compat_43_sys_sigvec
    317 109	EXCL		compat_43_sys_sigblock
    318 110	EXCL		compat_43_sys_sigsetmask
    319 #endif
    320 #if defined(COMPAT_13) || !defined(_KERNEL)
    321 111	NOARGS		{ int|compat_13_sys||sigsuspend(int mask); } sigsuspend13
    322 #else
    323 111	EXCL		compat_13_sys_sigsuspend
    324 #endif
    325 #if defined(COMPAT_43) || !defined(_KERNEL)
    326 112	NOARGS		{ int|compat_43_sys||sigstack(struct sigstack *nss, \
    327 			    struct sigstack *oss); } osigstack
    328 113	NOARGS		{ int|compat_43_sys||recvmsg(int s, \
    329 			    struct omsghdr *msg, int flags); } orecvmsg
    330 114	NOARGS		{ int|compat_43_sys||sendmsg(int s, void *msg, \
    331 			    int flags); } osendmsg
    332 #else
    333 112	EXCL		compat_43_sys_sigstack
    334 113	EXCL		compat_43_sys_recvmesg
    335 114	EXCL		compat_43_sys_sendmesg
    336 #endif
    337 115	OBSOL		vtrace
    338 116	NOARGS		{ int|compat_50_sys||gettimeofday(struct timeval50 *tp, \
    339 			    struct timezone *tzp); }
    340 117	NOARGS		{ int|compat_50_sys||getrusage(int who, \
    341 			    struct rusage50 *rusage); }
    342 118	NOARGS		{ int|sys||getsockopt(int s, int level, int name, \
    343 			    void *val, int *avalsize); }
    344 119	OBSOL		resuba
    345 120	NOARGS		{ ssize_t|sys||readv(int fd, \
    346 			    const struct iovec *iovp, int iovcnt); }
    347 121	NOARGS		{ ssize_t|sys||writev(int fd, \
    348 			    const struct iovec *iovp, int iovcnt); }
    349 122	NOARGS		{ int|compat_50_sys||settimeofday( \
    350 			    const struct timeval50 *tv, \
    351 			    const struct timezone *tzp); }
    352 123	NOARGS		{ int|sys||fchown(int fd, uid_t uid, gid_t gid); }
    353 124	NOARGS		{ int|sys||fchmod(int fd, mode_t mode); }
    354 #if defined(COMPAT_43) || !defined(_KERNEL)
    355 125	NOARGS		{ int|compat_43_sys||recvfrom(int s, void *buf, \
    356 			    size_t len, int flags, void *from, \
    357 			    int *fromlenaddr); } orecvfrom
    358 #else
    359 125	EXCL		compat_43_sys_recvfrom
    360 #endif
    361 126	NOARGS		{ int|sys||setreuid(uid_t ruid, uid_t euid); }
    362 127	NOARGS		{ int|sys||setregid(gid_t rgid, gid_t egid); }
    363 128	NOARGS		{ int|sys||rename(const char *from, const char *to); }
    364 #if defined(COMPAT_43) || !defined(_KERNEL)
    365 129	NOARGS		{ int|compat_43_sys||truncate(const char *path, \
    366 			    long length); } otruncate
    367 130	NOARGS		{ int|compat_43_sys||ftruncate(int fd, long length); } \
    368 			    oftruncate
    369 #else
    370 129	EXCL		compat_43_sys_truncate
    371 130	EXCL		compat_43_sys_ftruncate
    372 #endif
    373 131	NOARGS		{ int|sys||flock(int fd, int how); }
    374 132	NOARGS		{ int|sys||mkfifo(const char *path, mode_t mode); }
    375 133	NOARGS		{ ssize_t|sys||sendto(int s, const void *buf, \
    376 			    size_t len, int flags, const struct sockaddr *to, \
    377 			    int tolen); }
    378 134	NOARGS		{ int|sys||shutdown(int s, int how); }
    379 135	NOARGS		{ int|sys||socketpair(int domain, int type, \
    380 			    int protocol, int *rsv); }
    381 136	NOARGS		{ int|sys||mkdir(const char *path, mode_t mode); }
    382 137	NOARGS		{ int|sys||rmdir(const char *path); }
    383 138	NOARGS		{ int|compat_50_sys||utimes(const char *path, \
    384 			    const struct timeval50 *tptr); }
    385 139	OBSOL		4.2 sigreturn
    386 140	NOARGS		{ int|compat_50_sys||adjtime( \
    387 			    const struct timeval50 *delta, \
    388 			    struct timeval50 *olddelta); }
    389 #if defined(COMPAT_43) || !defined(_KERNEL)
    390 141	NOARGS		{ int|compat_43_sys||getpeername(int fdes, void *asa, \
    391 			    int *alen); } ogetpeername
    392 142	NOARGS		{ int32_t|compat_43_sys||gethostid(void); } ogethostid
    393 143	NOARGS		{ int|compat_43_sys||sethostid(int32_t hostid); } \
    394 			    osethostid
    395 144	NOARGS		{ int|compat_43_sys||getrlimit(int which, \
    396 			    struct orlimit *rlp); } ogetrlimit
    397 145	NOARGS		{ int|compat_43_sys||setrlimit(int which, \
    398 			    const struct orlimit *rlp); } osetrlimit
    399 146	NOARGS		{ int|compat_43_sys||killpg(int pgid, int signum); } \
    400 			    okillpg
    401 #else
    402 141	EXCL		compat_43_sys_getpeername
    403 142	EXCL		compat_43_sys_gethostid
    404 143	EXCL		compat_43_sys_sethostid
    405 144	EXCL		compat_43_sys_getrlimit
    406 145	EXCL		compat_43_sys_setrlimit
    407 146	EXCL		compat_43_sys_killpg
    408 #endif
    409 147	NOARGS		{ int|sys||setsid(void); }
    410 #if defined(QUOTA) || !defined(_KERNEL_OPT)
    411 148	NOARGS		{ int|compat_50_sys||quotactl(const char *path, \
    412 			    int cmd, int uid, void *arg); }
    413 #else
    414 148	EXCL		compat_50_sys_quotactl
    415 #endif
    416 #if (defined(QUOTA) && defined(COMPAT_43)) || !defined(_KERNEL_OPT)
    417 149	NOARGS		{ int|compat_43_sys||quota(void); } oquota
    418 #else
    419 149	EXCL		compat_43_sys_quota
    420 #endif
    421 #if defined(COMPAT_43) || !defined(_KERNEL_OPT)
    422 150	NOARGS		{ int|compat_43_sys||getsockname(int fdec, void *asa, \
    423 			    int *alen); } ogetsockname
    424 #else
    425 150	EXCL		compat_43_sys_getsockname
    426 #endif
    427 
    428 ; Syscalls 151-180 inclusive are reserved for vendor-specific
    429 ; system calls.  (This includes various calls added for compatibity
    430 ; with other Unix variants.)
    431 ; Some of these calls are now supported by BSD...
    432 151	UNIMPL
    433 152	UNIMPL
    434 153	UNIMPL
    435 154	UNIMPL
    436 155	EXCL		nfssvc
    437 #if defined(COMPAT_43) || !defined(_KERNEL)
    438 156	NOARGS		{ int|compat_43_sys||getdirentries(int fd, char *buf, \
    439 			    u_int count, long *basep); } ogetdirentries
    440 #else
    441 156	EXCL		compat_43_sys_getdirentries
    442 #endif
    443 #if defined(COMPAT_20) || !defined(_KERNEL)
    444 157	NOARGS		{ int|compat_20_sys||statfs(const char *path, \
    445 			    struct statfs12 *buf); }
    446 #else
    447 157	EXCL		compat_20_sys_statfs
    448 #endif
    449 #if defined(COMPAT_20) || !defined(_KERNEL)
    450 158	NOARGS		{ int|compat_20_sys||fstatfs(int fd, \
    451 			    struct statfs12 *buf); }
    452 #else
    453 158	EXCL		compat_20_sys_statfs
    454 #endif
    455 159	UNIMPL
    456 160	UNIMPL
    457 #if defined(COMPAT_30) || !defined(_KERNEL)
    458 161	NOARGS		{ int|compat_30_sys||getfh(const char *fname, \
    459 			    struct compat_30_fhandle *fhp); }
    460 #else
    461 161	EXCL		compat_30_sys_getfh
    462 #endif
    463 #if defined(COMPAT_09) || !defined(_KERNEL)
    464 162	NOARGS		{ int|compat_09_sys||getdomainname(char *domainname, \
    465 			    int len); } ogetdomainname
    466 163	NOARGS		{ int|compat_09_sys||setdomainname(char *domainname, \
    467 			    int len); } osetdomainname
    468 164	NOARGS		{ int|compat_09_sys||uname(struct outsname *name); } \
    469 			    ouname
    470 #else
    471 162	EXCL		compat_09_sys_getdomainname
    472 163	EXCL		compat_09_sys_setdomainname
    473 164	EXCL		compat_09_sys_uname
    474 #endif
    475 165	NOARGS		{ int|sys||sysarch(int op, void *parms); }
    476 166	UNIMPL
    477 167	UNIMPL
    478 168	UNIMPL
    479 ; XXX more generally, never on machines where sizeof(void *) != sizeof(int)
    480 #if (defined(SYSVSEM) || !defined(_KERNEL)) && !defined(_LP64) && defined(COMPAT_10)
    481 169	NOARGS		{ int|compat_10_sys||semsys(int which, int a2, int a3, \
    482 			    int a4, int a5); } osemsys
    483 #else
    484 169	EXCL		1.0 semsys
    485 #endif
    486 ; XXX more generally, never on machines where sizeof(void *) != sizeof(int)
    487 #if (defined(SYSVMSG) || !defined(_KERNEL)) && !defined(_LP64) && defined(COMPAT_10)
    488 170	NOARGS		{ int|compat_10_sys||msgsys(int which, int a2, int a3, \
    489 			    int a4, int a5, int a6); } omsgsys
    490 #else
    491 170	EXCL		1.0 msgsys
    492 #endif
    493 ; XXX more generally, never on machines where sizeof(void *) != sizeof(int)
    494 #if (defined(SYSVSHM) || !defined(_KERNEL)) && !defined(_LP64) && defined(COMPAT_10)
    495 171	NOARGS		{ int|compat_10_sys||shmsys(int which, int a2, int a3, \
    496 			    int a4); } oshmsys
    497 #else
    498 171	EXCL		1.0 shmsys
    499 #endif
    500 172	UNIMPL
    501 173	NOARGS		{ ssize_t|sys||pread(int fd, void *buf, \
    502 			    size_t nbyte, int pad, off_t offset); }
    503 174	NOARGS		{ ssize_t|sys||pwrite(int fd, const void *buf, \
    504 			    size_t nbyte, int pad, off_t offset); }
    505 175	UNIMPL		sys_ntp_gettime
    506 #if defined(NTP) || !defined(_KERNEL)
    507 176	NOARGS		{ int|sys||ntp_adjtime(struct timex *tp); }
    508 #else
    509 176	EXCL		ntp_adjtime
    510 #endif
    511 177	UNIMPL
    512 178	UNIMPL
    513 179	UNIMPL
    514 180	UNIMPL
    515 
    516 ; Syscalls 180-199 are used by/reserved for BSD
    517 181	NOARGS		{ int|sys||setgid(gid_t gid); }
    518 182	NOARGS		{ int|sys||setegid(gid_t egid); }
    519 183	NOARGS		{ int|sys||seteuid(uid_t euid); }
    520 184	EXCL		lfs_bmapv
    521 185	EXCL		lfs_markv
    522 186	EXCL		lfs_segclean
    523 187	EXCL		lfs_segwait
    524 #if defined(COMPAT_12) || !defined(_KERNEL)
    525 188	STD	{ int|aoutm68k_compat_12_sys||stat(const char *path, \
    526 			    struct aoutm68k_stat12 *ub); } stat12
    527 189	STD		{ int|aoutm68k_compat_12_sys||fstat(int fd, \
    528 			    struct aoutm68k_stat12 *sb); } fstat12
    529 190	STD		{ int|aoutm68k_compat_12_sys||lstat(const char *path, \
    530 			    struct aoutm68k_stat12 *ub); } lstat12
    531 #else
    532 188	EXCL		aoutm68k_compat_12_sys_stat
    533 189	EXCL		aoutm68k_compat_12_sys_fstat
    534 190	EXCL		aoutm68k_compat_12_sys_lstat
    535 #endif
    536 191	NOARGS		{ long|sys||pathconf(const char *path, int name); }
    537 192	NOARGS		{ long|sys||fpathconf(int fd, int name); }
    538 193	UNIMPL
    539 194	NOARGS		{ int|sys||getrlimit(int which, \
    540 			    struct rlimit *rlp); }
    541 195	NOARGS		{ int|sys||setrlimit(int which, \
    542 			    const struct rlimit *rlp); }
    543 #if defined(COMPAT_12) || !defined(_KERNEL)
    544 196	NOARGS		{ int|compat_12_sys||getdirentries(int fd, char *buf, \
    545 			    u_int count, long *basep); }
    546 #else
    547 196	EXCL		compat_12_sys_getdirentries
    548 #endif
    549 197	NOARGS		{ void *|sys||mmap(void *addr, size_t len, int prot, \
    550 			    int flags, int fd, long pad, off_t pos); }
    551 198	NOARGS INDIR	{ quad_t|sys||__syscall(quad_t code, \
    552 			    ... register32_t args[AOUTM68K_SYS_MAXSYSARGS]); }
    553 199	NOARGS		{ off_t|sys||lseek(int fd, int pad, off_t offset, \
    554 			    int whence); }
    555 200	NOARGS		{ int|sys||truncate(const char *path, int pad, \
    556 			    off_t length); }
    557 201	NOARGS		{ int|sys||ftruncate(int fd, int pad, off_t length); }
    558 202	NOARGS		{ int|sys||__sysctl(int *name, u_int namelen, \
    559 			    void *old, size_t *oldlenp, void *new, \
    560 			    size_t newlen); }
    561 203	NOARGS		{ int|sys||mlock(const void *addr, size_t len); }
    562 204	NOARGS		{ int|sys||munlock(const void *addr, size_t len); }
    563 205	NOARGS		{ int|sys||undelete(const char *path); }
    564 206	NOARGS		{ int|compat_50_sys||futimes(int fd, \
    565 			    const struct timeval50 *tptr); }
    566 207	NOARGS		{ pid_t|sys||getpgid(pid_t pid); }
    567 208	NOARGS		{ int|sys||reboot(int opt, char *bootstr); }
    568 209	NOARGS		{ int|sys||poll(struct pollfd *fds, u_int nfds, \
    569 			    int timeout); }
    570 210	UNIMPL
    571 211	UNIMPL
    572 212	UNIMPL
    573 213	UNIMPL
    574 214	UNIMPL
    575 215	UNIMPL
    576 216	UNIMPL
    577 217	UNIMPL
    578 218	UNIMPL
    579 219	UNIMPL
    580 ; System calls 220-300 are reserved for use by NetBSD
    581 #if defined(SYSVSEM) || !defined(_KERNEL)
    582 #if defined(COMPAT_14) || !defined(_KERNEL)
    583 220	NOARGS		{ int|compat_14_sys||__semctl(int semid, \
    584 			    int semnum, int cmd, union __semun *arg); }
    585 #else
    586 220	EXCL		compat_14_semctl
    587 #endif
    588 221	NOARGS		{ int|sys||semget(key_t key, int nsems, int semflg); }
    589 222	NOARGS		{ int|sys||semop(int semid, struct sembuf *sops, \
    590 			    size_t nsops); }
    591 223	NOARGS		{ int|sys||semconfig(int flag); }
    592 #else
    593 220	EXCL		compat_14_semctl
    594 221	EXCL		semget
    595 222	EXCL		semop
    596 223	EXCL		semconfig
    597 #endif
    598 #if defined(SYSVMSG) || !defined(_KERNEL)
    599 #if defined(COMPAT_14) || !defined(_KERNEL)
    600 224	NOARGS		{ int|compat_14_sys||msgctl(int msqid, int cmd, \
    601 			    struct msqid_ds14 *buf); }
    602 #else
    603 224	EXCL		compat_14_sys_msgctl
    604 #endif
    605 225	NOARGS		{ int|sys||msgget(key_t key, int msgflg); }
    606 226	NOARGS		{ int|sys||msgsnd(int msqid, const void *msgp, \
    607 			    size_t msgsz, int msgflg); }
    608 227	NOARGS		{ ssize_t|sys||msgrcv(int msqid, void *msgp, \
    609 			    size_t msgsz, long msgtyp, int msgflg); }
    610 #else
    611 224	EXCL		compat_14_msgctl
    612 225	EXCL		msgget
    613 226	EXCL		msgsnd
    614 227	EXCL		msgrcv
    615 #endif
    616 #if defined(SYSVSHM) || !defined(_KERNEL)
    617 228	NOARGS		{ void *|sys||shmat(int shmid, const void *shmaddr, \
    618 			    int shmflg); }
    619 #if defined(COMPAT_14) || !defined(_KERNEL)
    620 229	NOARGS		{ int|compat_14_sys||shmctl(int shmid, int cmd, \
    621 			    struct shmid_ds14 *buf); }
    622 #else
    623 229	EXCL		compat_14_sys_shmctl
    624 #endif
    625 230	NOARGS		{ int|sys||shmdt(const void *shmaddr); }
    626 231	NOARGS		{ int|sys||shmget(key_t key, size_t size, int shmflg); }
    627 #else
    628 228	EXCL		shmat
    629 229	EXCL		compat_14_shmctl
    630 230	EXCL		shmdt
    631 231	EXCL		shmget
    632 #endif
    633 232	NOARGS		{ int|compat_50_sys||clock_gettime(clockid_t clock_id, \
    634 			    struct timespec50 *tp); }
    635 233	NOARGS		{ int|compat_50_sys||clock_settime(clockid_t clock_id, \
    636 			    const struct timespec50 *tp); }
    637 234	NOARGS		{ int|compat_50_sys||clock_getres(clockid_t clock_id, \
    638 			    struct timespec50 *tp); }
    639 235	UNIMPL		timer_create
    640 236	UNIMPL		timer_delete
    641 237	UNIMPL		timer_settime
    642 238	UNIMPL		timer_gettime
    643 239	UNIMPL		timer_getoverrun
    644 ;
    645 ; Syscalls 240-269 are reserved for other IEEE Std1003.1b syscalls
    646 ;
    647 240	NOARGS		{ int|compat_50_sys||nanosleep( \
    648 			    const struct timespec50 *rqtp, \
    649 			    struct timespec50 *rmtp); }
    650 241	NOARGS		{ int|sys||fdatasync(int fd); }
    651 242	NOARGS		{ int|sys||mlockall(int flags); }
    652 243	NOARGS		{ int|sys||munlockall(void); }
    653 244	UNIMPL
    654 245	UNIMPL
    655 246	UNIMPL
    656 247	UNIMPL
    657 248	UNIMPL
    658 249	UNIMPL
    659 250	UNIMPL
    660 251	UNIMPL
    661 252	UNIMPL
    662 253	UNIMPL
    663 254	UNIMPL
    664 255	UNIMPL
    665 256	UNIMPL
    666 257	UNIMPL
    667 258	UNIMPL
    668 259	UNIMPL
    669 260	UNIMPL
    670 261	UNIMPL
    671 262	UNIMPL
    672 263	UNIMPL
    673 264	UNIMPL
    674 265	UNIMPL
    675 266	UNIMPL
    676 267	UNIMPL
    677 268	UNIMPL
    678 269	UNIMPL
    679 270	NOARGS		{ int|sys||__posix_rename(const char *from, \
    680 			    const char *to); }
    681 271	NOARGS		{ int|sys||swapctl(int cmd, const void *arg, int misc); }
    682 #if defined(COMPAT_30) || !defined(_KERNEL)
    683 272	NOARGS		{ int|compat_30_sys||getdents(int fd, char *buf, size_t count); }
    684 #else
    685 272	EXCL		compat_30_sys_getdents
    686 #endif
    687 273	NOARGS		{ int|sys||minherit(void *addr, size_t len, \
    688 			    int inherit); }
    689 274	NOARGS		{ int|sys||lchmod(const char *path, mode_t mode); }
    690 275	NOARGS		{ int|sys||lchown(const char *path, uid_t uid, \
    691 			    gid_t gid); }
    692 276	NOARGS		{ int|compat_50_sys||lutimes(const char *path, \
    693 			    const struct timeval50 *tptr); }
    694 277	NOARGS		{ int|sys|13|msync(void *addr, size_t len, int flags); }
    695 278	STD		{ int|aoutm68k_sys|13|stat(const char *path, \
    696 			    struct aoutm68k_stat *ub); }
    697 279	STD		{ int|aoutm68k_sys|13|fstat(int fd, \
    698 			    struct aoutm68k_stat *sb); }
    699 280	STD		{ int|aoutm68k_sys|13|lstat(const char *path, \
    700 			    struct aoutm68k_stat *ub); }
    701 281	NOARGS		{ int|sys|14|sigaltstack( \
    702 			    const struct sigaltstack *nss, \
    703 			    struct sigaltstack *oss); }
    704 282	NOARGS		{ int|sys|14|vfork(void); }
    705 283	NOARGS		{ int|sys||__posix_chown(const char *path, uid_t uid, \
    706 			    gid_t gid); }
    707 284	NOARGS		{ int|sys||__posix_fchown(int fd, uid_t uid, \
    708 			    gid_t gid); }
    709 285	NOARGS		{ int|sys||__posix_lchown(const char *path, uid_t uid, \
    710 			    gid_t gid); }
    711 286	NOARGS		{ pid_t|sys||getsid(pid_t pid); }
    712 287	UNIMPL
    713 #if defined(KTRACE) || !defined(_KERNEL)
    714 288	NOARGS		{ int|sys||fktrace(const int fd, int ops, \
    715 			    int facs, int pid); }
    716 #else
    717 288	EXCL		ktrace
    718 #endif
    719 289	NOARGS		{ ssize_t|sys||preadv(int fd, \
    720 			    const struct iovec *iovp, int iovcnt, \
    721 			    int pad, off_t offset); }
    722 290	NOARGS		{ ssize_t|sys||pwritev(int fd, \
    723 			    const struct iovec *iovp, int iovcnt, \
    724 			    int pad, off_t offset); }
    725 #if defined(COMPAT_16) || !defined(_KERNEL)
    726 291	NOARGS		{ int|compat_16_sys|14|sigaction(int signum, \
    727 			    const struct sigaction *nsa, \
    728 			    struct sigaction *osa); }
    729 #else
    730 291	EXCL		compat_16_sys___sigaction14
    731 #endif
    732 292	NOARGS		{ int|sys|14|sigpending(sigset_t *set); }
    733 293	NOARGS		{ int|sys|14|sigprocmask(int how, \
    734 			    const sigset_t *set, \
    735 			    sigset_t *oset); }
    736 294	NOARGS		{ int|sys|14|sigsuspend(const sigset_t *set); }
    737 #if defined(COMPAT_16) || !defined(_KERNEL)
    738 295	NOARGS		{ int|compat_16_sys|14|sigreturn(\
    739 			    struct sigcontext *sigcntxp); }
    740 #else
    741 295	EXCL		compat_16_sys___sigreturn14
    742 #endif
    743 296	NOARGS		{ int|sys||__getcwd(char *bufp, size_t length); }
    744 297	NOARGS		{ int|sys||fchroot(int fd); }
    745 #if defined(COMPAT_30) || ! defined(_KERNEL)
    746 298	NOARGS		{ int|compat_30_sys||fhopen(const \
    747 			    struct compat_30_fhandle *fhp, int flags); }
    748 #else
    749 298	EXCL		compat_30_sys_fhopen
    750 #endif
    751 299	STD		{ int|aoutm68k_sys||fhstat(const struct \
    752 			    compat_30_fhandle *fhp, \
    753 			    struct aoutm68k_stat *sb); }
    754 #if defined(COMPAT_20) || !defined(_KERNEL)
    755 300	NOARGS		{ int|compat_20_sys||fhstatfs(const struct \
    756 			    compat_30-fhandle *fhp, \
    757 			    struct statfs12 *buf); }
    758 #else
    759 300	EXCL		compat_20_sys_fhstatfs
    760 #endif
    761 #if defined(SYSVSEM) || !defined(_KERNEL)
    762 301	NOARGS		{ int|compat_50_sys|13|__semctl(int semid, \
    763 			    int semnum, int cmd, ... union __semun *arg); }
    764 #else
    765 301	EXCL		____semctl13
    766 #endif
    767 #if defined(SYSVMSG) || !defined(_KERNEL)
    768 302	NOARGS		{ int|compat_50_sys|13|msgctl(int msqid, int cmd, \
    769 			    struct msqid_ds *buf); }
    770 #else
    771 302	EXCL		__msgctl13
    772 #endif
    773 #if defined(SYSVSHM) || !defined(_KERNEL)
    774 303	NOARGS		{ int|compat_50_sys|13|shmctl(int shmid, int cmd, \
    775 			    struct shmid_ds *buf); }
    776 #else
    777 303	EXCL		__shmctl13
    778 #endif
    779 304	NOARGS		{ int|sys||lchflags(const char *path, u_long flags); }
    780 305	NOARGS		{ int|sys||issetugid(void); }
    781 306	NOARGS		{ int|sys||getcontext(struct __ucontext *ucp); }
    782 307	NOARGS		{ int|sys||setcontext(const struct __ucontext *ucp); }
    783