syscalls.master revision 33040
1139804Simp $Id: syscalls.master,v 1.47 1998/01/30 11:33:01 phk Exp $ 21541Srgrimes; from: @(#)syscalls.master 8.2 (Berkeley) 1/13/94 31541Srgrimes; 41541Srgrimes; System call name/number master file. 51541Srgrimes; Processed to created init_sysent.c, syscalls.c and syscall.h. 61541Srgrimes 71541Srgrimes; Columns: number type nargs namespc name alt{name,tag,rtyp}/comments 81541Srgrimes; number system call number, must be in order 91541Srgrimes; type one of STD, OBSOL, UNIMPL, COMPAT 101541Srgrimes; namespc one of POSIX, BSD, NOHIDE 111541Srgrimes; name psuedo-prototype of syscall routine 121541Srgrimes; If one of the following alts is different, then all appear: 131541Srgrimes; altname name of system call if different 141541Srgrimes; alttag name of args struct tag if different from [o]`name'"_args" 151541Srgrimes; altrtyp return type if not int (bogus - syscalls always return int) 161541Srgrimes; for UNIMPL/OBSOL, name continues with comments 171541Srgrimes 181541Srgrimes; types: 191541Srgrimes; STD always included 201541Srgrimes; COMPAT included on COMPAT #ifdef 211541Srgrimes; LIBCOMPAT included on COMPAT #ifdef, and placed in syscall.h 221541Srgrimes; OBSOL obsolete, not included in system, only specifies name 231541Srgrimes; UNIMPL not implemented, placeholder only 241541Srgrimes 251541Srgrimes; #ifdef's, etc. may be included, and are copied to the output files. 261541Srgrimes 271541Srgrimes#include <sys/param.h> 281541Srgrimes#include <sys/sysent.h> 2922521Sdyson#include <sys/sysproto.h> 3050477Speter 311541Srgrimes; Reserved/unimplemented system calls in the range 0-150 inclusive 3222521Sdyson; are reserved for use in future Berkeley releases. 3322521Sdyson; Additional system calls implemented in vendor and other 34159082Sdds; redistributions should be placed in the reserved range at the end 35159082Sdds; of the current calls. 36159082Sdds 37159082Sdds0 STD NOHIDE { int nosys(void); } syscall nosys_args int 38159082Sdds1 STD NOHIDE { void exit(int rval); } exit rexit_args void 39159082Sdds2 STD POSIX { int fork(void); } 4022521Sdyson3 STD POSIX { int read(int fd, char *buf, u_int nbyte); } 4122521Sdyson4 STD POSIX { int write(int fd, char *buf, u_int nbyte); } 4254444Seivind5 STD POSIX { int open(char *path, int flags, int mode); } 4354444Seivind; XXX should be { int open(const char *path, int flags, ...); } 4454444Seivind; but we're not ready for `const' or varargs. 4554444Seivind; XXX man page says `mode_t mode'. 4654444Seivind6 STD POSIX { int close(int fd); } 4745058Seivind7 STD BSD { int wait4(int pid, int *status, int options, \ 4822521Sdyson struct rusage *rusage); } wait4 wait_args int 4922521Sdyson8 COMPAT BSD { int creat(char *path, int mode); } 5022521Sdyson9 STD POSIX { int link(char *path, char *link); } 5122521Sdyson10 STD POSIX { int unlink(char *path); } 52116615Sse11 OBSOL NOHIDE execv 53116615Sse12 STD POSIX { int chdir(char *path); } 54116615Sse13 STD BSD { int fchdir(int fd); } 55159082Sdds14 STD POSIX { int mknod(char *path, int mode, int dev); } 56159082Sdds15 STD POSIX { int chmod(char *path, int mode); } 57159082Sdds16 STD POSIX { int chown(char *path, int uid, int gid); } 58116615Sse17 STD BSD { int obreak(char *nsize); } break obreak_args int 59116615Sse18 STD BSD { int getfsstat(struct statfs *buf, long bufsize, \ 60116615Sse int flags); } 6122521Sdyson19 COMPAT POSIX { long lseek(int fd, long offset, int whence); } 6251679Seivind20 STD POSIX { pid_t getpid(void); } 6351679Seivind21 STD BSD { int mount(char *type, char *path, int flags, \ 6483366Sjulian caddr_t data); } 6551679Seivind; XXX 4.4lite2 uses `char *type' but we're not ready for that. 6651679Seivind; XXX `path' should have type `const char *' but we're not ready for that. 67159082Sdds22 STD BSD { int unmount(char *path, int flags); } 68159082Sdds23 STD POSIX { int setuid(uid_t uid); } 69159082Sdds24 STD POSIX { uid_t getuid(void); } 70159082Sdds25 STD POSIX { uid_t geteuid(void); } 71159082Sdds26 STD BSD { int ptrace(int req, pid_t pid, caddr_t addr, \ 7222521Sdyson int data); } 7322521Sdyson27 STD BSD { int recvmsg(int s, struct msghdr *msg, int flags); } 7422521Sdyson28 STD BSD { int sendmsg(int s, caddr_t msg, int flags); } 75159082Sdds29 STD BSD { int recvfrom(int s, caddr_t buf, size_t len, \ 761541Srgrimes int flags, caddr_t from, int *fromlenaddr); } 771541Srgrimes30 STD BSD { int accept(int s, caddr_t name, int *anamelen); } 781541Srgrimes31 STD BSD { int getpeername(int fdes, caddr_t asa, int *alen); } 791541Srgrimes32 STD BSD { int getsockname(int fdes, caddr_t asa, int *alen); } 801541Srgrimes33 STD POSIX { int access(char *path, int flags); } 811541Srgrimes34 STD BSD { int chflags(char *path, int flags); } 82159082Sdds35 STD BSD { int fchflags(int fd, int flags); } 83159082Sdds36 STD BSD { int sync(void); } 84159082Sdds37 STD POSIX { int kill(int pid, int signum); } 8528732Sphk38 COMPAT POSIX { int stat(char *path, struct ostat *ub); } 86159082Sdds39 STD POSIX { pid_t getppid(void); } 8728732Sphk40 COMPAT POSIX { int lstat(char *path, struct ostat *ub); } 8828732Sphk41 STD POSIX { int dup(u_int fd); } 8928732Sphk42 STD POSIX { int pipe(void); } 9028732Sphk43 STD POSIX { gid_t getegid(void); } 9128732Sphk44 STD BSD { int profil(caddr_t samples, u_int size, \ 9228732Sphk u_int offset, u_int scale); } 93159082Sdds45 STD BSD { int ktrace(char *fname, int ops, int facs, \ 94159082Sdds int pid); } 95159082Sdds46 STD POSIX { int sigaction(int signum, struct sigaction *nsa, \ 96159082Sdds struct sigaction *osa); } 971541Srgrimes47 STD POSIX { gid_t getgid(void); } 9835823Smsmith48 STD POSIX { int sigprocmask(int how, sigset_t mask); } 991541Srgrimes; XXX note nonstandard (bogus) calling convention - the libc stub passes 1001541Srgrimes; us the mask, not a pointer to it, and we return the old mask as the 1011541Srgrimes; (int) return value. 1021541Srgrimes49 STD BSD { int getlogin(char *namebuf, u_int namelen); } 1031541Srgrimes50 STD BSD { int setlogin(char *namebuf); } 104159082Sdds51 STD BSD { int acct(char *path); } 105159082Sdds52 STD POSIX { int sigpending(void); } 106159082Sdds53 STD BSD { int sigaltstack(struct sigaltstack *nss, \ 10722521Sdyson struct sigaltstack *oss); } 10835823Smsmith54 STD POSIX { int ioctl(int fd, u_long com, caddr_t data); } 10922521Sdyson55 STD BSD { int reboot(int opt); } 11022521Sdyson56 STD POSIX { int revoke(char *path); } 11122521Sdyson57 STD POSIX { int symlink(char *path, char *link); } 11222521Sdyson58 STD POSIX { int readlink(char *path, char *buf, int count); } 113159082Sdds59 STD POSIX { int execve(char *fname, char **argv, char **envv); } 114159082Sdds60 STD POSIX { int umask(int newmask); } umask umask_args int 115159082Sdds61 STD BSD { int chroot(char *path); } 116159082Sdds62 COMPAT POSIX { int fstat(int fd, struct ostat *sb); } 117159082Sdds63 COMPAT BSD { int getkerninfo(int op, char *where, int *size, \ 1181541Srgrimes int arg); } getkerninfo getkerninfo_args int 11935823Smsmith64 COMPAT BSD { int getpagesize(void); } \ 12053101Seivind getpagesize getpagesize_args int 1211541Srgrimes65 STD BSD { int msync(void *addr, size_t len, int flags); } 1221541Srgrimes66 STD BSD { int vfork(void); } 1231541Srgrimes67 OBSOL NOHIDE vread 1241541Srgrimes68 OBSOL NOHIDE vwrite 125159082Sdds69 STD BSD { int sbrk(int incr); } 126159082Sdds70 STD BSD { int sstk(int incr); } 127159082Sdds71 COMPAT BSD { int mmap(void *addr, int len, int prot, \ 1281541Srgrimes int flags, int fd, long pos); } 1291541Srgrimes72 STD BSD { int ovadvise(int anom); } vadvise ovadvise_args int 1301541Srgrimes73 STD BSD { int munmap(void *addr, size_t len); } 1311541Srgrimes74 STD BSD { int mprotect(const void *addr, size_t len, int prot); } 13283366Sjulian75 STD BSD { int madvise(void *addr, size_t len, int behav); } 133118093Sphk76 OBSOL NOHIDE vhangup 1341541Srgrimes77 OBSOL NOHIDE vlimit 1351541Srgrimes78 STD BSD { int mincore(const void *addr, size_t len, \ 136159082Sdds char *vec); } 137159082Sdds79 STD POSIX { int getgroups(u_int gidsetsize, gid_t *gidset); } 138159082Sdds80 STD POSIX { int setgroups(u_int gidsetsize, gid_t *gidset); } 1391541Srgrimes81 STD POSIX { int getpgrp(void); } 1401541Srgrimes82 STD POSIX { int setpgid(int pid, int pgid); } 1411541Srgrimes83 STD BSD { int setitimer(u_int which, struct itimerval *itv, \ 1421541Srgrimes struct itimerval *oitv); } 14383366Sjulian84 COMPAT BSD { int wait(void); } 1441541Srgrimes85 STD BSD { int swapon(char *name); } 1451541Srgrimes86 STD BSD { int getitimer(u_int which, struct itimerval *itv); } 146159082Sdds87 COMPAT BSD { int gethostname(char *hostname, u_int len); } \ 147159082Sdds gethostname gethostname_args int 148159082Sdds88 COMPAT BSD { int sethostname(char *hostname, u_int len); } \ 1491541Srgrimes sethostname sethostname_args int 1501541Srgrimes89 STD BSD { int getdtablesize(void); } 1511541Srgrimes90 STD POSIX { int dup2(u_int from, u_int to); } 1521541Srgrimes91 UNIMPL BSD getdopt 15383366Sjulian92 STD POSIX { int fcntl(int fd, int cmd, int arg); } 1541541Srgrimes; XXX should be { int fcntl(int fd, int cmd, ...); } 1551541Srgrimes; but we're not ready for varargs. 156159082Sdds; XXX man page says `int arg' too. 157159082Sdds93 STD BSD { int select(int nd, fd_set *in, fd_set *ou, \ 158159082Sdds fd_set *ex, struct timeval *tv); } 1591541Srgrimes94 UNIMPL BSD setdopt 1601541Srgrimes95 STD POSIX { int fsync(int fd); } 16154803Srwatson96 STD BSD { int setpriority(int which, int who, int prio); } 1621541Srgrimes97 STD BSD { int socket(int domain, int type, int protocol); } 16383366Sjulian98 STD BSD { int connect(int s, caddr_t name, int namelen); } 1641541Srgrimes99 CPT_NOA BSD { int accept(int s, caddr_t name, int *anamelen); } \ 1651541Srgrimes accept accept_args int 166159082Sdds100 STD BSD { int getpriority(int which, int who); } 167159082Sdds101 COMPAT BSD { int send(int s, caddr_t buf, int len, int flags); } 168159082Sdds102 COMPAT BSD { int recv(int s, caddr_t buf, int len, int flags); } 169159082Sdds103 STD BSD { int sigreturn(struct sigcontext *sigcntxp); } 1701541Srgrimes104 STD BSD { int bind(int s, caddr_t name, int namelen); } 1711541Srgrimes105 STD BSD { int setsockopt(int s, int level, int name, \ 1721541Srgrimes caddr_t val, int valsize); } 1731541Srgrimes106 STD BSD { int listen(int s, int backlog); } 17483366Sjulian107 OBSOL NOHIDE vtimes 1751541Srgrimes108 COMPAT BSD { int sigvec(int signum, struct sigvec *nsv, \ 1761541Srgrimes struct sigvec *osv); } 177159082Sdds109 COMPAT BSD { int sigblock(int mask); } 178159082Sdds110 COMPAT BSD { int sigsetmask(int mask); } 179159082Sdds111 STD POSIX { int sigsuspend(sigset_t mask); } 1801541Srgrimes; XXX note nonstandard (bogus) calling convention - the libc stub passes 1811541Srgrimes; us the mask, not a pointer to it. 1821541Srgrimes112 COMPAT BSD { int sigstack(struct sigstack *nss, \ 1831541Srgrimes struct sigstack *oss); } 1841541Srgrimes113 COMPAT BSD { int recvmsg(int s, struct omsghdr *msg, int flags); } 1851541Srgrimes114 COMPAT BSD { int sendmsg(int s, caddr_t msg, int flags); } 1861541Srgrimes115 OBSOL NOHIDE vtrace 187159082Sdds116 STD BSD { int gettimeofday(struct timeval *tp, \ 188159082Sdds struct timezone *tzp); } 189159082Sdds117 STD BSD { int getrusage(int who, struct rusage *rusage); } 190159082Sdds118 STD BSD { int getsockopt(int s, int level, int name, \ 191159082Sdds caddr_t val, int *avalsize); } 1921541Srgrimes119 UNIMPL NOHIDE resuba (BSD/OS 2.x) 1931541Srgrimes120 STD BSD { int readv(int fd, struct iovec *iovp, u_int iovcnt); } 1941541Srgrimes121 STD BSD { int writev(int fd, struct iovec *iovp, \ 1951541Srgrimes u_int iovcnt); } 1961541Srgrimes122 STD BSD { int settimeofday(struct timeval *tv, \ 1971541Srgrimes struct timezone *tzp); } 1981541Srgrimes123 STD BSD { int fchown(int fd, int uid, int gid); } 199159082Sdds124 STD BSD { int fchmod(int fd, int mode); } 200159082Sdds125 CPT_NOA BSD { int recvfrom(int s, caddr_t buf, size_t len, \ 201159082Sdds int flags, caddr_t from, int *fromlenaddr); } \ 20222521Sdyson recvfrom recvfrom_args int 20322521Sdyson126 STD BSD { int setreuid(int ruid, int euid); } 20483366Sjulian127 STD BSD { int setregid(int rgid, int egid); } 20522521Sdyson128 STD POSIX { int rename(char *from, char *to); } 20622521Sdyson129 COMPAT BSD { int truncate(char *path, long length); } 20722521Sdyson130 COMPAT BSD { int ftruncate(int fd, long length); } 20822521Sdyson131 STD BSD { int flock(int fd, int how); } 209159082Sdds132 STD POSIX { int mkfifo(char *path, int mode); } 210159082Sdds133 STD BSD { int sendto(int s, caddr_t buf, size_t len, \ 211159082Sdds int flags, caddr_t to, int tolen); } 2121541Srgrimes134 STD BSD { int shutdown(int s, int how); } 2131541Srgrimes135 STD BSD { int socketpair(int domain, int type, int protocol, \ 21422521Sdyson int *rsv); } 215153400Sdes136 STD POSIX { int mkdir(char *path, int mode); } 2161541Srgrimes137 STD POSIX { int rmdir(char *path); } 2171541Srgrimes138 STD BSD { int utimes(char *path, struct timeval *tptr); } 21883366Sjulian139 OBSOL NOHIDE 4.2 sigreturn 2191541Srgrimes140 STD BSD { int adjtime(struct timeval *delta, \ 2201541Srgrimes struct timeval *olddelta); } 221159082Sdds141 COMPAT BSD { int getpeername(int fdes, caddr_t asa, int *alen); } 222159082Sdds142 COMPAT BSD { long gethostid(void); } 223159082Sdds143 COMPAT BSD { int sethostid(long hostid); } 22429353Speter144 COMPAT BSD { int getrlimit(u_int which, struct ogetrlimit *rlp); } 2251541Srgrimes145 COMPAT BSD { int setrlimit(u_int which, struct ogetrlimit *rlp); } 22629353Speter146 COMPAT BSD { int killpg(int pgid, int signum); } 2271541Srgrimes147 STD POSIX { int setsid(void); } 22883366Sjulian148 STD BSD { int quotactl(char *path, int cmd, int uid, \ 2291541Srgrimes caddr_t arg); } 2301541Srgrimes149 COMPAT BSD { int quota(void); } 231159082Sdds150 CPT_NOA BSD { int getsockname(int fdec, caddr_t asa, int *alen); }\ 232159082Sdds getsockname getsockname_args int 233159082Sdds 23472521Sjlemon; Syscalls 151-180 inclusive are reserved for vendor-specific 23572521Sjlemon; system calls. (This includes various calls added for compatibity 23672521Sjlemon; with other Unix variants.) 23772521Sjlemon; Some of these calls are now supported by BSD... 23872521Sjlemon151 UNIMPL NOHIDE sem_lock (BSD/OS 2.x) 239159082Sdds152 UNIMPL NOHIDE sem_wakeup (BSD/OS 2.x) 240159082Sdds153 UNIMPL NOHIDE asyncdaemon (BSD/OS 2.x) 241159082Sdds154 UNIMPL NOHIDE nosys 24222521Sdyson; 155 is initialized by the NFS code, if present. 24322521Sdyson155 NOIMPL BSD { int nfssvc(int flag, caddr_t argp); } 24422521Sdyson156 COMPAT BSD { int getdirentries(int fd, char *buf, u_int count, \ 24522521Sdyson long *basep); } 24622521Sdyson157 STD BSD { int statfs(char *path, struct statfs *buf); } 247159082Sdds158 STD BSD { int fstatfs(int fd, struct statfs *buf); } 248159082Sdds159 UNIMPL NOHIDE nosys 249159082Sdds160 UNIMPL NOHIDE nosys 2501541Srgrimes; 161 is initialized by the NFS code, if present. 2511541Srgrimes161 NOIMPL BSD { int getfh(char *fname, struct fhandle *fhp); } 2521541Srgrimes162 STD BSD { int getdomainname(char *domainname, int len); } 25383366Sjulian163 STD BSD { int setdomainname(char *domainname, int len); } 2541541Srgrimes164 STD BSD { int uname(struct utsname *name); } 2551541Srgrimes165 STD BSD { int sysarch(int op, char *parms); } 256159082Sdds166 STD BSD { int rtprio(int function, pid_t pid, \ 257159082Sdds struct rtprio *rtp); } 258159082Sdds167 UNIMPL NOHIDE nosys 259159082Sdds168 UNIMPL NOHIDE nosys 260159082Sdds169 STD BSD { int semsys(int which, int a2, int a3, int a4, \ 2611541Srgrimes int a5); } 26235823Smsmith; XXX should be { int semsys(int which, ...); } 26335823Smsmith170 STD BSD { int msgsys(int which, int a2, int a3, int a4, \ 2641541Srgrimes int a5, int a6); } 2651541Srgrimes; XXX should be { int msgsys(int which, ...); } 2661541Srgrimes171 STD BSD { int shmsys(int which, int a2, int a3, int a4); } 267159082Sdds; XXX should be { int shmsys(int which, ...); } 268159082Sdds172 UNIMPL NOHIDE nosys 269159082Sdds173 UNIMPL NOHIDE nosys 270159082Sdds174 UNIMPL NOHIDE nosys 271159082Sdds175 UNIMPL NOHIDE nosys 2729842Sdg176 STD BSD { int ntp_adjtime(struct timex *tp); } 27335823Smsmith177 UNIMPL NOHIDE sfork (BSD/OS 2.x) 2749842Sdg178 UNIMPL NOHIDE getdescriptor (BSD/OS 2.x) 2759842Sdg179 UNIMPL NOHIDE setdescriptor (BSD/OS 2.x) 2769842Sdg180 UNIMPL NOHIDE nosys 2771541Srgrimes 278159082Sdds; Syscalls 180-199 are used by/reserved for BSD 279159082Sdds181 STD POSIX { int setgid(gid_t gid); } 280159082Sdds182 STD BSD { int setegid(gid_t egid); } 281159082Sdds183 STD BSD { int seteuid(uid_t euid); } 2821541Srgrimes184 UNIMPL BSD lfs_bmapv 2831541Srgrimes185 UNIMPL BSD lfs_markv 2841541Srgrimes186 UNIMPL BSD lfs_segclean 2851541Srgrimes187 UNIMPL BSD lfs_segwait 2861541Srgrimes188 STD POSIX { int stat(char *path, struct stat *ub); } 2871541Srgrimes189 STD POSIX { int fstat(int fd, struct stat *sb); } 2881541Srgrimes190 STD POSIX { int lstat(char *path, struct stat *ub); } 2891541Srgrimes191 STD POSIX { int pathconf(char *path, int name); } 2901541Srgrimes192 STD POSIX { int fpathconf(int fd, int name); } 291159082Sdds193 UNIMPL NOHIDE nosys 292159082Sdds194 STD BSD { int getrlimit(u_int which, \ 293159082Sdds struct orlimit *rlp); } \ 294159082Sdds getrlimit __getrlimit_args int 295159082Sdds195 STD BSD { int setrlimit(u_int which, \ 2961541Srgrimes struct orlimit *rlp); } \ 29735823Smsmith setrlimit __setrlimit_args int 2981541Srgrimes196 STD BSD { int getdirentries(int fd, char *buf, u_int count, \ 2991541Srgrimes long *basep); } 3001541Srgrimes197 STD BSD { caddr_t mmap(caddr_t addr, size_t len, int prot, \ 3011541Srgrimes int flags, int fd, long pad, off_t pos); } 3021541Srgrimes198 STD NOHIDE { int nosys(void); } __syscall __syscall_args int 303159082Sdds199 STD POSIX { off_t lseek(int fd, int pad, off_t offset, \ 304159082Sdds int whence); } 305159082Sdds200 STD BSD { int truncate(char *path, int pad, off_t length); } 306159082Sdds201 STD BSD { int ftruncate(int fd, int pad, off_t length); } 307159082Sdds202 STD BSD { int __sysctl(int *name, u_int namelen, void *old, \ 3081541Srgrimes size_t *oldlenp, void *new, size_t newlen); } \ 30935823Smsmith __sysctl sysctl_args int 31035823Smsmith; properly, __sysctl should be a NOHIDE, but making an exception 3111541Srgrimes; here allows to avoid one in libc/sys/Makefile.inc. 3121541Srgrimes203 STD BSD { int mlock(const void *addr, size_t len); } 3131541Srgrimes204 STD BSD { int munlock(const void *addr, size_t len); } 314159082Sdds; big problem here. Lite2, NetBSD and OpenBSD have syscall 205 as undelete() 315159082Sdds; we should move utrace before it's too late. 316159082Sdds205 STD BSD { int utrace(caddr_t addr, size_t len); } 317159082Sdds; problem here. NetBSD/OpenBSD have syscall 206 as futimes() 318159082Sdds206 STD BSD { int undelete(char *path); } 3191541Srgrimes207 STD BSD { int getpgid(pid_t pid); } 32035823Smsmith208 UNIMPL NOHIDE newreboot (NetBSD) 32153131Seivind; problem. NetBSD and OpenBSD have a different syscall number for poll() 3221541Srgrimes209 STD BSD { int poll(struct pollfd *fds, u_int nfds, \ 3231541Srgrimes int timeout); } 3241541Srgrimes 3251541Srgrimes; 3261541Srgrimes; The following are reserved for loadable syscalls 327159082Sdds; 328159082Sdds210 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 329159082Sdds211 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3301541Srgrimes212 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3311541Srgrimes213 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3321541Srgrimes214 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3331541Srgrimes215 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3343167Sdfr216 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 33522521Sdyson217 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 33622521Sdyson218 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3371541Srgrimes219 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 3381541Srgrimes 339159082Sdds; 340159082Sdds; The following were introduced with NetBSD/4.4Lite-2 341159082Sdds; 3421541Srgrimes220 STD BSD { int __semctl(int semid, int semnum, int cmd, \ 3431541Srgrimes union semun *arg); } 3441541Srgrimes221 STD BSD { int semget(key_t key, int nsems, int semflg); } 3451541Srgrimes222 STD BSD { int semop(int semid, struct sembuf *sops, \ 3461541Srgrimes u_int nsops); } 3471541Srgrimes223 STD BSD { int semconfig(int flag); } 348159082Sdds224 STD BSD { int msgctl(int msqid, int cmd, \ 349159082Sdds struct msqid_ds *buf); } 350159082Sdds225 STD BSD { int msgget(key_t key, int msgflg); } 3511541Srgrimes226 STD BSD { int msgsnd(int msqid, void *msgp, size_t msgsz, \ 3521541Srgrimes int msgflg); } 35383366Sjulian227 STD BSD { int msgrcv(int msqid, void *msgp, size_t msgsz, \ 3541541Srgrimes long msgtyp, int msgflg); } 3551541Srgrimes228 STD BSD { int shmat(int shmid, void *shmaddr, int shmflg); } 356159082Sdds229 STD BSD { int shmctl(int shmid, int cmd, \ 357159082Sdds struct shmid_ds *buf); } 358159082Sdds230 STD BSD { int shmdt(void *shmaddr); } 3591541Srgrimes231 STD BSD { int shmget(key_t key, int size, int shmflg); } 3601541Srgrimes; 36183366Sjulian232 STD POSIX { int clock_gettime(clockid_t clock_id, \ 3621541Srgrimes struct timespec *tp); } 3631541Srgrimes233 STD POSIX { int clock_settime(clockid_t clock_id, \ 364159082Sdds const struct timespec *tp); } 365159082Sdds234 STD POSIX { int clock_getres(clockid_t clock_id, \ 366159082Sdds struct timespec *tp); } 367159082Sdds235 UNIMPL NOHIDE timer_create 368164248Skmacy236 UNIMPL NOHIDE timer_delete 3691541Srgrimes237 UNIMPL NOHIDE timer_settime 37022521Sdyson238 UNIMPL NOHIDE timer_gettime 37183366Sjulian239 UNIMPL NOHIDE timer_getoverrun 372164248Skmacy240 STD POSIX { int nanosleep(const struct timespec *rqtp, \ 373164248Skmacy struct timespec *rmtp); } 3741541Srgrimes241 UNIMPL NOHIDE nosys 3751541Srgrimes242 UNIMPL NOHIDE nosys 376159082Sdds243 UNIMPL NOHIDE nosys 377159082Sdds244 UNIMPL NOHIDE nosys 378159082Sdds245 UNIMPL NOHIDE nosys 379159082Sdds246 UNIMPL NOHIDE nosys 3801541Srgrimes247 UNIMPL NOHIDE nosys 3811541Srgrimes248 UNIMPL NOHIDE nosys 38222521Sdyson249 UNIMPL NOHIDE nosys 38383366Sjulian; syscall numbers initially used in OpenBSD 3841541Srgrimes250 STD BSD { int minherit(void *addr, size_t len, int inherit); } 3851541Srgrimes251 STD BSD { int rfork(int flags); } 386159082Sdds252 STD BSD { int openbsd_poll(struct pollfd *fds, u_int nfds, \ 387159082Sdds int timeout); } 388159082Sdds253 STD BSD { int issetugid(void); } 3891541Srgrimes254 STD BSD { int lchown(char *path, int uid, int gid); } 3901541Srgrimes255 UNIMPL NOHIDE nosys 39196572Sphk256 UNIMPL NOHIDE nosys 392137726Sphk257 UNIMPL NOHIDE nosys 39396572Sphk258 UNIMPL NOHIDE nosys 3941541Srgrimes259 UNIMPL NOHIDE nosys 39510551Sdyson260 UNIMPL NOHIDE nosys 3961541Srgrimes261 UNIMPL NOHIDE nosys 3971541Srgrimes262 UNIMPL NOHIDE nosys 398159082Sdds263 UNIMPL NOHIDE nosys 399159082Sdds264 UNIMPL NOHIDE nosys 400159082Sdds265 UNIMPL NOHIDE nosys 401159082Sdds266 UNIMPL NOHIDE nosys 40237384Sjulian267 UNIMPL NOHIDE nosys 40337384Sjulian268 UNIMPL NOHIDE nosys 40437384Sjulian269 UNIMPL NOHIDE nosys 40537384Sjulian270 UNIMPL NOHIDE nosys 4061541Srgrimes271 UNIMPL NOHIDE nosys 407159082Sdds272 UNIMPL NOHIDE nosys 408159082Sdds273 UNIMPL NOHIDE nosys 409159082Sdds274 UNIMPL NOHIDE nosys 41062976Smckusick275 UNIMPL NOHIDE nosys 41162976Smckusick276 UNIMPL NOHIDE nosys 41262976Smckusick277 UNIMPL NOHIDE nosys 41362976Smckusick278 UNIMPL NOHIDE nosys 41462976Smckusick279 UNIMPL NOHIDE nosys 415159082Sdds280 UNIMPL NOHIDE nosys 416159082Sdds281 UNIMPL NOHIDE nosys 417159082Sdds282 UNIMPL NOHIDE nosys 4181541Srgrimes283 UNIMPL NOHIDE nosys 4191541Srgrimes284 UNIMPL NOHIDE nosys 4201541Srgrimes285 UNIMPL NOHIDE nosys 4211541Srgrimes286 UNIMPL NOHIDE nosys 422159082Sdds287 UNIMPL NOHIDE nosys 423159082Sdds288 UNIMPL NOHIDE nosys 424159082Sdds289 UNIMPL NOHIDE nosys 4251541Srgrimes290 UNIMPL NOHIDE nosys 4261541Srgrimes291 UNIMPL NOHIDE nosys 4271541Srgrimes292 UNIMPL NOHIDE nosys 42822521Sdyson293 UNIMPL NOHIDE nosys 4291541Srgrimes294 UNIMPL NOHIDE nosys 4301541Srgrimes295 UNIMPL NOHIDE nosys 431159082Sdds296 UNIMPL NOHIDE nosys 432159082Sdds297 UNIMPL NOHIDE nosys 433159082Sdds298 UNIMPL NOHIDE nosys 4341541Srgrimes299 UNIMPL NOHIDE nosys 4351541Srgrimes; syscall numbers for FreeBSD 436153400Sdes300 STD BSD { int modnext(int modid); } 4371541Srgrimes301 STD BSD { int modstat(int modid, struct module_stat* stat); } 4381541Srgrimes302 STD BSD { int modfnext(int modid); } 4391541Srgrimes303 STD BSD { int modfind(char *name); } 4401541Srgrimes304 STD BSD { int kldload(const char *file); } 4411541Srgrimes305 STD BSD { int kldunload(int fileid); } 442159082Sdds306 STD BSD { int kldfind(const char *file); } 443159082Sdds307 STD BSD { int kldnext(int fileid); } 444159082Sdds308 STD BSD { int kldstat(int fileid, struct kld_file_stat* stat); } 4451541Srgrimes309 STD BSD { int kldfirstmod(int fileid); } 4461541Srgrimes310 STD BSD { int getsid(pid_t pid); } 4471541Srgrimes311 UNIMPL NOHIDE setresuid 4481541Srgrimes312 UNIMPL NOHIDE setresgid 4491541Srgrimes313 STD BSD { int signanosleep(const struct timespec *rqtp, \ 450159082Sdds struct timespec *rmtp, sigset_t *mask); } 451159082Sdds314 STD BSD { int aio_return(struct aiocb *aiocbp); } 452159082Sdds315 STD BSD { int aio_suspend(struct aiocb * const * aiocbp, int nent, const struct timespec *timeout); } 45310551Sdyson316 STD BSD { int aio_cancel(int fd, struct aiocb *aiocbp); } 45410551Sdyson317 STD BSD { int aio_error(struct aiocb *aiocbp); } 45510551Sdyson318 STD BSD { int aio_read(struct aiocb *aiocbp); } 45610551Sdyson319 STD BSD { int aio_write(struct aiocb *aiocbp); } 45710551Sdyson320 STD BSD { int lio_listio(int mode, struct aiocb * const *acb_list, int nent, struct sigevent *sig); } 45812767Sdyson321 STD BSD { int yield(void); } 45910551Sdyson322 STD BSD { int thr_sleep(const struct timespec *timeout); } 46010551Sdyson323 STD BSD { int thr_wakeup(pid_t pid); } 461159082Sdds324 STD BSD { int mlockall(int how); } 462159082Sdds325 STD BSD { int munlockall(void); } 463159082Sdds326 STD BSD { int __getcwd(u_char *buf, u_int buflen); } 46410551Sdyson