1 $FreeBSD$ 2; from: @(#)syscalls.master 8.2 (Berkeley) 1/13/94 3; 4; System call name/number master file. 5; Processed to created init_sysent.c, syscalls.c and syscall.h. 6 7; Columns: number [M]type nargs name alt{name,tag,rtyp}/comments 8; number system call number, must be in order 9; type one of [M]STD, [M]OBSOL, [M]UNIMPL, [M]COMPAT, [M]CPT_NOA, 10; [M]LIBCOMPAT, [M]NODEF, [M]NOARGS, [M]NOPROTO, [M]NOIMPL, 11; [M]NOSTD, [M]COMPAT4 12; name psuedo-prototype of syscall routine 13; If one of the following alts is different, then all appear: 14; altname name of system call if different 15; alttag name of args struct tag if different from [o]`name'"_args" 16; altrtyp return type if not int (bogus - syscalls always return int) 17; for UNIMPL/OBSOL, name continues with comments 18 19; types: 20; [M] e.g. like MSTD -- means the system call is MP-safe. If no 21; M prefix is used, the syscall wrapper will obtain the Giant 22; lock for the syscall. 23; STD always included 24; COMPAT included on COMPAT #ifdef 25; COMPAT4 included on COMPAT4 #ifdef (FreeBSD 4 compat) 26; LIBCOMPAT included on COMPAT #ifdef, and placed in syscall.h 27; OBSOL obsolete, not included in system, only specifies name 28; UNIMPL not implemented, placeholder only 29; NOSTD implemented but as a lkm that can be statically 30; compiled in sysent entry will be filled with lkmsys 31; so the SYSCALL_MODULE macro works 32; 33; Please copy any additions and changes to the following compatability tables: 34; sys/compat/freebsd32/syscalls.master 35 36; #ifdef's, etc. may be included, and are copied to the output files. 37 38#include <sys/param.h> 39#include <sys/sysent.h> 40#include <sys/sysproto.h> 41 42; Reserved/unimplemented system calls in the range 0-150 inclusive 43; are reserved for use in future Berkeley releases. 44; Additional system calls implemented in vendor and other 45; redistributions should be placed in the reserved range at the end 46; of the current calls. 47 480 MSTD { int nosys(void); } syscall nosys_args int 491 MSTD { void sys_exit(int rval); } exit sys_exit_args void 502 MSTD { int fork(void); } 513 MSTD { ssize_t read(int fd, void *buf, size_t nbyte); } 524 MSTD { ssize_t write(int fd, const void *buf, size_t nbyte); } 535 MSTD { int open(char *path, int flags, int mode); } 54; XXX should be { int open(const char *path, int flags, ...); } 55; but we're not ready for `const' or varargs. 56; XXX man page says `mode_t mode'. 576 MSTD { int close(int fd); } 587 MSTD { int wait4(int pid, int *status, int options, \ 59 struct rusage *rusage); } wait4 wait_args int 608 MCOMPAT { int creat(char *path, int mode); } 619 MSTD { int link(char *path, char *link); } 6210 MSTD { int unlink(char *path); } 6311 OBSOL execv 6412 MSTD { int chdir(char *path); } 6513 MSTD { int fchdir(int fd); } 6614 MSTD { int mknod(char *path, int mode, int dev); } 6715 MSTD { int chmod(char *path, int mode); } 6816 MSTD { int chown(char *path, int uid, int gid); } 6917 MSTD { int obreak(char *nsize); } break obreak_args int 7018 COMPAT4 { int getfsstat(struct ostatfs *buf, long bufsize, int flags); } 7119 COMPAT { long lseek(int fd, long offset, int whence); } 7220 MSTD { pid_t getpid(void); } 7321 STD { int mount(char *type, char *path, int flags, caddr_t data); } 74; XXX `path' should have type `const char *' but we're not ready for that. 7522 STD { int unmount(char *path, int flags); } 7623 MSTD { int setuid(uid_t uid); } 7724 MSTD { uid_t getuid(void); } 7825 MSTD { uid_t geteuid(void); } 7926 MSTD { int ptrace(int req, pid_t pid, caddr_t addr, int data); } 8027 MSTD { int recvmsg(int s, struct msghdr *msg, int flags); } 8128 MSTD { int sendmsg(int s, struct msghdr *msg, int flags); } 8229 MSTD { int recvfrom(int s, caddr_t buf, size_t len, int flags, \ 83 struct sockaddr * __restrict from, \ 84 __socklen_t * __restrict fromlenaddr); } 8530 MSTD { int accept(int s, struct sockaddr * __restrict name, \ 86 __socklen_t * __restrict anamelen); } 8731 MSTD { int getpeername(int fdes, struct sockaddr * __restrict asa, \ 88 __socklen_t * __restrict alen); } 8932 MSTD { int getsockname(int fdes, struct sockaddr * __restrict asa, \ 90 __socklen_t * __restrict alen); } 9133 MSTD { int access(char *path, int flags); } 9234 MSTD { int chflags(char *path, int flags); } 9335 MSTD { int fchflags(int fd, int flags); } 9436 MSTD { int sync(void); } 9537 MSTD { int kill(int pid, int signum); } 9638 COMPAT { int stat(char *path, struct ostat *ub); } 9739 MSTD { pid_t getppid(void); } 9840 COMPAT { int lstat(char *path, struct ostat *ub); } 9941 MSTD { int dup(u_int fd); } 10042 MSTD { int pipe(void); } 10143 MSTD { gid_t getegid(void); } 10244 MSTD { int profil(caddr_t samples, size_t size, size_t offset, \ 103 u_int scale); } 10445 MSTD { int ktrace(const char *fname, int ops, int facs, int pid); } 10546 MCOMPAT { int sigaction(int signum, struct osigaction *nsa, \ 106 struct osigaction *osa); } 10747 MSTD { gid_t getgid(void); } 10848 MCOMPAT { int sigprocmask(int how, osigset_t mask); } 109; XXX note nonstandard (bogus) calling convention - the libc stub passes 110; us the mask, not a pointer to it, and we return the old mask as the 111; (int) return value. 11249 MSTD { int getlogin(char *namebuf, u_int namelen); } 11350 MSTD { int setlogin(char *namebuf); } 11451 MSTD { int acct(char *path); } 11552 MCOMPAT { int sigpending(void); } 11653 MSTD { int sigaltstack(stack_t *ss, stack_t *oss); } 11754 MSTD { int ioctl(int fd, u_long com, caddr_t data); } 11855 MSTD { int reboot(int opt); } 11956 MSTD { int revoke(char *path); } 12057 MSTD { int symlink(char *path, char *link); } 12158 MSTD { int readlink(char *path, char *buf, int count); } 12259 MSTD { int execve(char *fname, char **argv, char **envv); } 12360 MSTD { int umask(int newmask); } umask umask_args int 12461 MSTD { int chroot(char *path); } 12562 MCOMPAT { int fstat(int fd, struct ostat *sb); } 12663 MCOMPAT { int getkerninfo(int op, char *where, size_t *size, \ 127 int arg); } getkerninfo getkerninfo_args int 12864 MCOMPAT { int getpagesize(void); } getpagesize getpagesize_args int 12965 MSTD { int msync(void *addr, size_t len, int flags); } 13066 MSTD { int vfork(void); } 13167 OBSOL vread 13268 OBSOL vwrite 13369 MSTD { int sbrk(int incr); } 13470 MSTD { int sstk(int incr); } 13571 MCOMPAT { int mmap(void *addr, int len, int prot, int flags, int fd, \ 136 long pos); } 13772 MSTD { int ovadvise(int anom); } vadvise ovadvise_args int 13873 MSTD { int munmap(void *addr, size_t len); } 13974 MSTD { int mprotect(const void *addr, size_t len, int prot); } 14075 MSTD { int madvise(void *addr, size_t len, int behav); } 14176 OBSOL vhangup 14277 OBSOL vlimit 14378 MSTD { int mincore(const void *addr, size_t len, char *vec); } 14479 MSTD { int getgroups(u_int gidsetsize, gid_t *gidset); } 14580 MSTD { int setgroups(u_int gidsetsize, gid_t *gidset); } 14681 MSTD { int getpgrp(void); } 14782 MSTD { int setpgid(int pid, int pgid); } 14883 MSTD { int setitimer(u_int which, struct itimerval *itv, \ 149 struct itimerval *oitv); } 15084 MCOMPAT { int wait(void); } 15185 MSTD { int swapon(char *name); } 15286 MSTD { int getitimer(u_int which, struct itimerval *itv); } 15387 MCOMPAT { int gethostname(char *hostname, u_int len); } \ 154 gethostname gethostname_args int 15588 MCOMPAT { int sethostname(char *hostname, u_int len); } \ 156 sethostname sethostname_args int 15789 MSTD { int getdtablesize(void); } 15890 MSTD { int dup2(u_int from, u_int to); } 15991 UNIMPL getdopt 16092 MSTD { int fcntl(int fd, int cmd, long arg); } 161; XXX should be { int fcntl(int fd, int cmd, ...); } 162; but we're not ready for varargs. 16393 MSTD { int select(int nd, fd_set *in, fd_set *ou, \ 164 fd_set *ex, struct timeval *tv); } 16594 UNIMPL setdopt 16695 MSTD { int fsync(int fd); } 16796 MSTD { int setpriority(int which, int who, int prio); } 16897 MSTD { int socket(int domain, int type, int protocol); } 16998 MSTD { int connect(int s, caddr_t name, int namelen); } 17099 MCPT_NOA { int accept(int s, caddr_t name, int *anamelen); } \ 171 accept accept_args int 172100 MSTD { int getpriority(int which, int who); } 173101 MCOMPAT { int send(int s, caddr_t buf, int len, int flags); } 174102 MCOMPAT { int recv(int s, caddr_t buf, int len, int flags); } 175103 MCOMPAT { int sigreturn(struct osigcontext *sigcntxp); } 176104 MSTD { int bind(int s, caddr_t name, int namelen); } 177105 MSTD { int setsockopt(int s, int level, int name, caddr_t val, \ 178 int valsize); } 179106 MSTD { int listen(int s, int backlog); } 180107 OBSOL vtimes 181108 MCOMPAT { int sigvec(int signum, struct sigvec *nsv, \ 182 struct sigvec *osv); } 183109 MCOMPAT { int sigblock(int mask); } 184110 MCOMPAT { int sigsetmask(int mask); } 185111 MCOMPAT { int sigsuspend(osigset_t mask); } 186; XXX note nonstandard (bogus) calling convention - the libc stub passes 187; us the mask, not a pointer to it. 188112 MCOMPAT { int sigstack(struct sigstack *nss, struct sigstack *oss); } 189113 MCOMPAT { int recvmsg(int s, struct omsghdr *msg, int flags); } 190114 MCOMPAT { int sendmsg(int s, caddr_t msg, int flags); } 191115 OBSOL vtrace 192116 MSTD { int gettimeofday(struct timeval *tp, struct timezone *tzp); } 193117 MSTD { int getrusage(int who, struct rusage *rusage); } 194118 MSTD { int getsockopt(int s, int level, int name, caddr_t val, \ 195 int *avalsize); } 196119 UNIMPL resuba (BSD/OS 2.x) 197120 MSTD { int readv(int fd, struct iovec *iovp, u_int iovcnt); } 198121 MSTD { int writev(int fd, struct iovec *iovp, u_int iovcnt); } 199122 MSTD { int settimeofday(struct timeval *tv, struct timezone *tzp); } 200123 MSTD { int fchown(int fd, int uid, int gid); } 201124 MSTD { int fchmod(int fd, int mode); } 202125 MCPT_NOA { int recvfrom(int s, caddr_t buf, size_t len, int flags, \ 203 caddr_t from, int *fromlenaddr); } \ 204 recvfrom recvfrom_args int 205126 MSTD { int setreuid(int ruid, int euid); } 206127 MSTD { int setregid(int rgid, int egid); } 207128 MSTD { int rename(char *from, char *to); } 208129 COMPAT { int truncate(char *path, long length); } 209130 COMPAT { int ftruncate(int fd, long length); } 210131 MSTD { int flock(int fd, int how); } 211132 MSTD { int mkfifo(char *path, int mode); } 212133 MSTD { int sendto(int s, caddr_t buf, size_t len, int flags, \ 213 caddr_t to, int tolen); } 214134 MSTD { int shutdown(int s, int how); } 215135 MSTD { int socketpair(int domain, int type, int protocol, \ 216 int *rsv); } 217136 MSTD { int mkdir(char *path, int mode); } 218137 MSTD { int rmdir(char *path); } 219138 MSTD { int utimes(char *path, struct timeval *tptr); } 220139 OBSOL 4.2 sigreturn 221140 MSTD { int adjtime(struct timeval *delta, \ 222 struct timeval *olddelta); } 223141 MCOMPAT { int getpeername(int fdes, caddr_t asa, int *alen); } 224142 MCOMPAT { long gethostid(void); } 225143 MCOMPAT { int sethostid(long hostid); } 226144 MCOMPAT { int getrlimit(u_int which, struct orlimit *rlp); } 227145 MCOMPAT { int setrlimit(u_int which, struct orlimit *rlp); } 228146 MCOMPAT { int killpg(int pgid, int signum); } 229147 MSTD { int setsid(void); } 230148 STD { int quotactl(char *path, int cmd, int uid, caddr_t arg); } 231149 MCOMPAT { int quota(void); } 232150 MCPT_NOA { int getsockname(int fdec, caddr_t asa, int *alen); }\ 233 getsockname getsockname_args int 234 235; Syscalls 151-180 inclusive are reserved for vendor-specific 236; system calls. (This includes various calls added for compatibity 237; with other Unix variants.) 238; Some of these calls are now supported by BSD... 239151 UNIMPL sem_lock (BSD/OS 2.x) 240152 UNIMPL sem_wakeup (BSD/OS 2.x) 241153 UNIMPL asyncdaemon (BSD/OS 2.x) 242154 UNIMPL nosys 243; 155 is initialized by the NFS code, if present. 244155 MNOIMPL { int nfssvc(int flag, caddr_t argp); } 245156 COMPAT { int getdirentries(int fd, char *buf, u_int count, \ 246 long *basep); } 247157 COMPAT4 { int statfs(char *path, struct ostatfs *buf); } 248158 COMPAT4 { int fstatfs(int fd, struct ostatfs *buf); } 249159 UNIMPL nosys 250160 MSTD { int lgetfh(char *fname, struct fhandle *fhp); } 251161 MSTD { int getfh(char *fname, struct fhandle *fhp); } 252162 MSTD { int getdomainname(char *domainname, int len); } 253163 MSTD { int setdomainname(char *domainname, int len); } 254164 MSTD { int uname(struct utsname *name); } 255165 MSTD { int sysarch(int op, char *parms); } 256166 MSTD { int rtprio(int function, pid_t pid, struct rtprio *rtp); } 257167 UNIMPL nosys 258168 UNIMPL nosys 259; 169 is initialized by the SYSVSEM code if present or loaded 260169 MNOSTD { int semsys(int which, int a2, int a3, int a4, int a5); } 261; 169 is initialized by the SYSVMSG code if present or loaded 262; XXX should be { int semsys(int which, ...); } 263170 MNOSTD { int msgsys(int which, int a2, int a3, int a4, int a5, \ 264 int a6); } 265; 169 is initialized by the SYSVSHM code if present or loaded 266; XXX should be { int msgsys(int which, ...); } 267171 MNOSTD { int shmsys(int which, int a2, int a3, int a4); } 268; XXX should be { int shmsys(int which, ...); } 269172 UNIMPL nosys 270173 MSTD { ssize_t pread(int fd, void *buf, size_t nbyte, \ 271 int pad, off_t offset); } 272174 MSTD { ssize_t pwrite(int fd, const void *buf, \ 273 size_t nbyte, int pad, off_t offset); } 274175 UNIMPL nosys 275176 MSTD { int ntp_adjtime(struct timex *tp); } 276177 UNIMPL sfork (BSD/OS 2.x) 277178 UNIMPL getdescriptor (BSD/OS 2.x) 278179 UNIMPL setdescriptor (BSD/OS 2.x) 279180 UNIMPL nosys 280 281; Syscalls 181-199 are used by/reserved for BSD 282181 MSTD { int setgid(gid_t gid); } 283182 MSTD { int setegid(gid_t egid); } 284183 MSTD { int seteuid(uid_t euid); } 285184 UNIMPL lfs_bmapv 286185 UNIMPL lfs_markv 287186 UNIMPL lfs_segclean 288187 UNIMPL lfs_segwait 289188 MSTD { int stat(char *path, struct stat *ub); } 290189 MSTD { int fstat(int fd, struct stat *sb); } 291190 MSTD { int lstat(char *path, struct stat *ub); } 292191 MSTD { int pathconf(char *path, int name); } 293192 MSTD { int fpathconf(int fd, int name); } 294193 UNIMPL nosys 295194 MSTD { int getrlimit(u_int which, struct rlimit *rlp); } \ 296 getrlimit __getrlimit_args int 297195 MSTD { int setrlimit(u_int which, struct rlimit *rlp); } \ 298 setrlimit __setrlimit_args int 299196 MSTD { int getdirentries(int fd, char *buf, u_int count, \ 300 long *basep); } 301197 MSTD { caddr_t mmap(caddr_t addr, size_t len, int prot, \ 302 int flags, int fd, int pad, off_t pos); } 303198 MSTD { int nosys(void); } __syscall __syscall_args int 304199 MSTD { off_t lseek(int fd, int pad, off_t offset, int whence); } 305200 MSTD { int truncate(char *path, int pad, off_t length); } 306201 MSTD { int ftruncate(int fd, int pad, off_t length); } 307202 MSTD { int __sysctl(int *name, u_int namelen, void *old, \ 308 size_t *oldlenp, void *new, size_t newlen); } \ 309 __sysctl sysctl_args int 310203 MSTD { int mlock(const void *addr, size_t len); } 311204 MSTD { int munlock(const void *addr, size_t len); } 312205 MSTD { int undelete(char *path); } 313206 MSTD { int futimes(int fd, struct timeval *tptr); } 314207 MSTD { int getpgid(pid_t pid); } 315208 UNIMPL newreboot (NetBSD) 316209 MSTD { int poll(struct pollfd *fds, u_int nfds, int timeout); } 317 318; 319; The following are reserved for loadable syscalls 320; 321210 NODEF lkmnosys lkmnosys nosys_args int 322211 NODEF lkmnosys lkmnosys nosys_args int 323212 NODEF lkmnosys lkmnosys nosys_args int 324213 NODEF lkmnosys lkmnosys nosys_args int 325214 NODEF lkmnosys lkmnosys nosys_args int 326215 NODEF lkmnosys lkmnosys nosys_args int 327216 NODEF lkmnosys lkmnosys nosys_args int 328217 NODEF lkmnosys lkmnosys nosys_args int 329218 NODEF lkmnosys lkmnosys nosys_args int 330219 NODEF lkmnosys lkmnosys nosys_args int 331 332; 333; The following were introduced with NetBSD/4.4Lite-2 334; They are initialized by thier respective modules/sysinits 335220 MNOSTD { int __semctl(int semid, int semnum, int cmd, \ 336 union semun *arg); } 337221 MNOSTD { int semget(key_t key, int nsems, int semflg); } 338222 MNOSTD { int semop(int semid, struct sembuf *sops, size_t nsops); } 339223 UNIMPL semconfig 340224 MNOSTD { int msgctl(int msqid, int cmd, struct msqid_ds *buf); } 341225 MNOSTD { int msgget(key_t key, int msgflg); } 342226 MNOSTD { int msgsnd(int msqid, const void *msgp, size_t msgsz, \ 343 int msgflg); } 344227 MNOSTD { int msgrcv(int msqid, void *msgp, size_t msgsz, \ 345 long msgtyp, int msgflg); } 346228 MNOSTD { int shmat(int shmid, const void *shmaddr, int shmflg); } 347229 MNOSTD { int shmctl(int shmid, int cmd, struct shmid_ds *buf); } 348230 MNOSTD { int shmdt(const void *shmaddr); } 349231 MNOSTD { int shmget(key_t key, size_t size, int shmflg); } 350; 351232 MSTD { int clock_gettime(clockid_t clock_id, struct timespec *tp); } 352233 MSTD { int clock_settime(clockid_t clock_id, \ 353 const struct timespec *tp); } 354234 MSTD { int clock_getres(clockid_t clock_id, struct timespec *tp); } 355235 UNIMPL timer_create 356236 UNIMPL timer_delete 357237 UNIMPL timer_settime 358238 UNIMPL timer_gettime 359239 UNIMPL timer_getoverrun 360240 MSTD { int nanosleep(const struct timespec *rqtp, \ 361 struct timespec *rmtp); } 362241 UNIMPL nosys 363242 UNIMPL nosys 364243 UNIMPL nosys 365244 UNIMPL nosys 366245 UNIMPL nosys 367246 UNIMPL nosys 368247 UNIMPL nosys 369248 STD { int ntp_gettime(struct ntptimeval *ntvp); } 370249 UNIMPL nosys 371; syscall numbers initially used in OpenBSD 372250 MSTD { int minherit(void *addr, size_t len, int inherit); } 373251 MSTD { int rfork(int flags); } 374252 MSTD { int openbsd_poll(struct pollfd *fds, u_int nfds, \ 375 int timeout); } 376253 MSTD { int issetugid(void); } 377254 MSTD { int lchown(char *path, int uid, int gid); } 378255 UNIMPL nosys 379256 UNIMPL nosys 380257 UNIMPL nosys 381258 UNIMPL nosys 382259 UNIMPL nosys 383260 UNIMPL nosys 384261 UNIMPL nosys 385262 UNIMPL nosys 386263 UNIMPL nosys 387264 UNIMPL nosys 388265 UNIMPL nosys 389266 UNIMPL nosys 390267 UNIMPL nosys 391268 UNIMPL nosys 392269 UNIMPL nosys 393270 UNIMPL nosys 394271 UNIMPL nosys 395272 MSTD { int getdents(int fd, char *buf, size_t count); } 396273 UNIMPL nosys 397274 MSTD { int lchmod(char *path, mode_t mode); } 398275 NOPROTO { int lchown(char *path, uid_t uid, gid_t gid); } \ 399 netbsd_lchown lchown_args int 400276 MSTD { int lutimes(char *path, struct timeval *tptr); } 401277 MNOPROTO { int msync(void *addr, size_t len, int flags); } \ 402 netbsd_msync msync_args int 403278 MSTD { int nstat(char *path, struct nstat *ub); } 404279 MSTD { int nfstat(int fd, struct nstat *sb); } 405280 MSTD { int nlstat(char *path, struct nstat *ub); } 406281 UNIMPL nosys 407282 UNIMPL nosys 408283 UNIMPL nosys 409284 UNIMPL nosys 410285 UNIMPL nosys 411286 UNIMPL nosys 412287 UNIMPL nosys 413288 UNIMPL nosys 414289 UNIMPL nosys 415290 UNIMPL nosys 416291 UNIMPL nosys 417292 UNIMPL nosys 418293 UNIMPL nosys 419294 UNIMPL nosys 420295 UNIMPL nosys 421296 UNIMPL nosys 422; XXX 297 is 300 in NetBSD 423297 COMPAT4 { int fhstatfs(const struct fhandle *u_fhp, \ 424 struct ostatfs *buf); } 425298 STD { int fhopen(const struct fhandle *u_fhp, int flags); } 426299 STD { int fhstat(const struct fhandle *u_fhp, struct stat *sb); } 427; syscall numbers for FreeBSD 428300 MSTD { int modnext(int modid); } 429301 MSTD { int modstat(int modid, struct module_stat* stat); } 430302 MSTD { int modfnext(int modid); } 431303 MSTD { int modfind(const char *name); } 432304 MSTD { int kldload(const char *file); } 433305 MSTD { int kldunload(int fileid); } 434306 MSTD { int kldfind(const char *file); } 435307 MSTD { int kldnext(int fileid); } 436308 MSTD { int kldstat(int fileid, struct kld_file_stat* stat); } 437309 MSTD { int kldfirstmod(int fileid); } 438310 MSTD { int getsid(pid_t pid); } 439311 MSTD { int setresuid(uid_t ruid, uid_t euid, uid_t suid); } 440312 MSTD { int setresgid(gid_t rgid, gid_t egid, gid_t sgid); } 441313 OBSOL signanosleep 442314 NOSTD { int aio_return(struct aiocb *aiocbp); } 443315 NOSTD { int aio_suspend(struct aiocb * const * aiocbp, int nent, \ 444 const struct timespec *timeout); } 445316 NOSTD { int aio_cancel(int fd, struct aiocb *aiocbp); } 446317 NOSTD { int aio_error(struct aiocb *aiocbp); } 447318 NOSTD { int aio_read(struct aiocb *aiocbp); } 448319 NOSTD { int aio_write(struct aiocb *aiocbp); } 449320 NOSTD { int lio_listio(int mode, struct aiocb * const *acb_list, \ 450 int nent, struct sigevent *sig); } 451321 MSTD { int yield(void); } 452322 OBSOL thr_sleep 453323 OBSOL thr_wakeup 454324 MSTD { int mlockall(int how); } 455325 MSTD { int munlockall(void); } 456326 MSTD { int __getcwd(u_char *buf, u_int buflen); } 457 458327 MSTD { int sched_setparam (pid_t pid, \ 459 const struct sched_param *param); } 460328 MSTD { int sched_getparam (pid_t pid, struct sched_param *param); } 461 462329 MSTD { int sched_setscheduler (pid_t pid, int policy, \ 463 const struct sched_param *param); } 464330 MSTD { int sched_getscheduler (pid_t pid); } 465 466331 MSTD { int sched_yield (void); } 467332 MSTD { int sched_get_priority_max (int policy); } 468333 MSTD { int sched_get_priority_min (int policy); } 469334 MSTD { int sched_rr_get_interval (pid_t pid, \ 470 struct timespec *interval); } 471335 MSTD { int utrace(const void *addr, size_t len); } 472336 MCOMPAT4 { int sendfile(int fd, int s, off_t offset, size_t nbytes, \ 473 struct sf_hdtr *hdtr, off_t *sbytes, int flags); } 474337 MSTD { int kldsym(int fileid, int cmd, void *data); } 475338 MSTD { int jail(struct jail *jail); } 476339 UNIMPL pioctl 477340 MSTD { int sigprocmask(int how, const sigset_t *set, \ 478 sigset_t *oset); } 479341 MSTD { int sigsuspend(const sigset_t *sigmask); } 480342 MCOMPAT4 { int sigaction(int sig, const struct sigaction *act, \ 481 struct sigaction *oact); } 482343 MSTD { int sigpending(sigset_t *set); } 483344 MCOMPAT4 { int sigreturn(const struct ucontext4 *sigcntxp); } 484345 MSTD { int sigtimedwait(const sigset_t *set, \ 485 siginfo_t *info, const struct timespec *timeout); } 486346 MSTD { int sigwaitinfo(const sigset_t *set, siginfo_t *info); } 487347 MSTD { int __acl_get_file(const char *path, \ 488 acl_type_t type, struct acl *aclp); } 489348 MSTD { int __acl_set_file(const char *path, \ 490 acl_type_t type, struct acl *aclp); } 491349 MSTD { int __acl_get_fd(int filedes, acl_type_t type, \ 492 struct acl *aclp); } 493350 MSTD { int __acl_set_fd(int filedes, acl_type_t type, \ 494 struct acl *aclp); } 495351 MSTD { int __acl_delete_file(const char *path, acl_type_t type); } 496352 MSTD { int __acl_delete_fd(int filedes, acl_type_t type); } 497353 MSTD { int __acl_aclcheck_file(const char *path, \ 498 acl_type_t type, struct acl *aclp); } 499354 MSTD { int __acl_aclcheck_fd(int filedes, acl_type_t type, \ 500 struct acl *aclp); } 501355 STD { int extattrctl(const char *path, int cmd, \ 502 const char *filename, int attrnamespace, \ 503 const char *attrname); } 504356 STD { int extattr_set_file(const char *path, \ 505 int attrnamespace, const char *attrname, \ 506 void *data, size_t nbytes); } 507357 STD { ssize_t extattr_get_file(const char *path, \ 508 int attrnamespace, const char *attrname, \ 509 void *data, size_t nbytes); } 510358 STD { int extattr_delete_file(const char *path, \ 511 int attrnamespace, const char *attrname); } 512359 NOSTD { int aio_waitcomplete(struct aiocb **aiocbp, \ 513 struct timespec *timeout); } 514360 MSTD { int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid); } 515361 MSTD { int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid); } 516362 MSTD { int kqueue(void); } 517363 MSTD { int kevent(int fd, \ 518 const struct kevent *changelist, int nchanges, \ 519 struct kevent *eventlist, int nevents, \ 520 const struct timespec *timeout); } 521364 UNIMPL __cap_get_proc 522365 UNIMPL __cap_set_proc 523366 UNIMPL __cap_get_fd 524367 UNIMPL __cap_get_file 525368 UNIMPL __cap_set_fd 526369 UNIMPL __cap_set_file 527370 NODEF lkmressys lkmressys nosys_args int 528371 STD { int extattr_set_fd(int fd, int attrnamespace, \ 529 const char *attrname, void *data, \ 530 size_t nbytes); } 531372 STD { ssize_t extattr_get_fd(int fd, int attrnamespace, \ 532 const char *attrname, void *data, size_t nbytes); } 533373 STD { int extattr_delete_fd(int fd, int attrnamespace, \ 534 const char *attrname); } 535374 MSTD { int __setugid(int flag); } 536375 NOIMPL { int nfsclnt(int flag, caddr_t argp); } 537376 MSTD { int eaccess(char *path, int flags); } 538377 UNIMPL afs_syscall 539378 STD { int nmount(struct iovec *iovp, unsigned int iovcnt, \ 540 int flags); } 541379 MSTD { int kse_exit(void); } 542380 MSTD { int kse_wakeup(struct kse_mailbox *mbx); } 543381 MSTD { int kse_create(struct kse_mailbox *mbx, \ 544 int newgroup); } 545382 MSTD { int kse_thr_interrupt(struct kse_thr_mailbox *tmbx, int cmd, \ 546 long data); } 547383 MSTD { int kse_release(struct timespec *timeout); } 548384 MSTD { int __mac_get_proc(struct mac *mac_p); } 549385 MSTD { int __mac_set_proc(struct mac *mac_p); } 550386 MSTD { int __mac_get_fd(int fd, struct mac *mac_p); } 551387 MSTD { int __mac_get_file(const char *path_p, \ 552 struct mac *mac_p); } 553388 MSTD { int __mac_set_fd(int fd, struct mac *mac_p); } 554389 MSTD { int __mac_set_file(const char *path_p, \ 555 struct mac *mac_p); } 556390 STD { int kenv(int what, const char *name, char *value, \ 557 int len); } 558391 MSTD { int lchflags(const char *path, int flags); } 559392 MSTD { int uuidgen(struct uuid *store, int count); } 560393 MSTD { int sendfile(int fd, int s, off_t offset, size_t nbytes, \ 561 struct sf_hdtr *hdtr, off_t *sbytes, int flags); } 562394 MSTD { int mac_syscall(const char *policy, int call, \ 563 void *arg); } 564395 MSTD { int getfsstat(struct statfs *buf, long bufsize, \ 565 int flags); } 566396 MSTD { int statfs(char *path, struct statfs *buf); } 567397 MSTD { int fstatfs(int fd, struct statfs *buf); } 568398 STD { int fhstatfs(const struct fhandle *u_fhp, \ 569 struct statfs *buf); } 570399 UNIMPL nosys 571400 MNOSTD { int ksem_close(semid_t id); } 572401 MNOSTD { int ksem_post(semid_t id); } 573402 MNOSTD { int ksem_wait(semid_t id); } 574403 MNOSTD { int ksem_trywait(semid_t id); } 575404 MNOSTD { int ksem_init(semid_t *idp, unsigned int value); } 576405 MNOSTD { int ksem_open(semid_t *idp, const char *name, \ 577 int oflag, mode_t mode, unsigned int value); } 578406 MNOSTD { int ksem_unlink(const char *name); } 579407 MNOSTD { int ksem_getvalue(semid_t id, int *val); } 580408 MNOSTD { int ksem_destroy(semid_t id); } 581409 MSTD { int __mac_get_pid(pid_t pid, struct mac *mac_p); } 582410 MSTD { int __mac_get_link(const char *path_p, \ 583 struct mac *mac_p); } 584411 MSTD { int __mac_set_link(const char *path_p, \ 585 struct mac *mac_p); } 586412 STD { int extattr_set_link(const char *path, \ 587 int attrnamespace, const char *attrname, \ 588 void *data, size_t nbytes); } 589413 STD { ssize_t extattr_get_link(const char *path, \ 590 int attrnamespace, const char *attrname, \ 591 void *data, size_t nbytes); } 592414 STD { int extattr_delete_link(const char *path, \ 593 int attrnamespace, const char *attrname); } 594415 MSTD { int __mac_execve(char *fname, char **argv, \ 595 char **envv, struct mac *mac_p); } 596416 MSTD { int sigaction(int sig, const struct sigaction *act, \ 597 struct sigaction *oact); } 598417 MSTD { int sigreturn(const struct __ucontext *sigcntxp); } 599418 UNIMPL __xstat 600419 UNIMPL __xfstat 601420 UNIMPL __xlstat 602421 MSTD { int getcontext(struct __ucontext *ucp); } 603422 MSTD { int setcontext(const struct __ucontext *ucp); } 604423 MSTD { int swapcontext(struct __ucontext *oucp, \ 605 const struct __ucontext *ucp); } 606424 MSTD { int swapoff(const char *name); } 607425 MSTD { int __acl_get_link(const char *path, \ 608 acl_type_t type, struct acl *aclp); } 609426 MSTD { int __acl_set_link(const char *path, \ 610 acl_type_t type, struct acl *aclp); } 611427 MSTD { int __acl_delete_link(const char *path, \ 612 acl_type_t type); } 613428 MSTD { int __acl_aclcheck_link(const char *path, \ 614 acl_type_t type, struct acl *aclp); } 615429 MSTD { int sigwait(const sigset_t *set, int *sig); } 616430 MSTD { int thr_create(ucontext_t *ctx, long *id, int flags); } 617431 MSTD { void thr_exit(long *state); } 618432 MSTD { int thr_self(long *id); } 619433 MSTD { int thr_kill(long id, int sig); } 620434 MSTD { int _umtx_lock(struct umtx *umtx); } 621435 MSTD { int _umtx_unlock(struct umtx *umtx); } 622436 MSTD { int jail_attach(int jid); } 623437 STD { ssize_t extattr_list_fd(int fd, int attrnamespace, \ 624 void *data, size_t nbytes); } 625438 STD { ssize_t extattr_list_file(const char *path, \ 626 int attrnamespace, void *data, size_t nbytes); } 627439 STD { ssize_t extattr_list_link(const char *path, \ 628 int attrnamespace, void *data, size_t nbytes); } 629440 MSTD { int kse_switchin(struct kse_thr_mailbox *tmbx, \ 630 int flags); } 631441 MNOSTD { int ksem_timedwait(semid_t id, struct timespec *abstime); } 632442 MSTD { int thr_suspend(const struct timespec *timeout); } 633443 MSTD { int thr_wake(long id); } 634444 MSTD { int kldunloadf(int fileid, int flags); } 635445 MNOSTD { int audit(const void *record, u_int length); } 636446 MNOSTD { int auditon(int cmd, void *data, u_int length); } 637447 MNOSTD { int getauid(uid_t *auid); } 638448 MNOSTD { int setauid(uid_t *auid); } 639449 MNOSTD { int getaudit(struct auditinfo *auditinfo); } 640450 MNOSTD { int setaudit(struct auditinfo *auditinfo); } 641451 MNOSTD { int getaudit_addr(struct auditinfo_addr \ 642 *auditinfo_addr, u_int length); } 643452 MNOSTD { int setaudit_addr(struct auditinfo_addr \ 644 *auditinfo_addr, u_int length); } 645453 MNOSTD { int auditctl(int cmd, char *path); } 646454 MSTD { int _umtx_op(struct umtx *umtx, int op, long id, void *uaddr,\ 647 void *uaddr2); } 648; Please copy any additions and changes to the following compatability tables: 649; sys/compat/freebsd32/syscalls.master 650