syscalls.master revision 104734
1 $FreeBSD: head/sys/kern/syscalls.master 104734 2002-10-09 22:04:09Z peter $ 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 namespc 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; namespc one of POSIX, BSD, NOHIDE 13; name psuedo-prototype of syscall routine 14; If one of the following alts is different, then all appear: 15; altname name of system call if different 16; alttag name of args struct tag if different from [o]`name'"_args" 17; altrtyp return type if not int (bogus - syscalls always return int) 18; for UNIMPL/OBSOL, name continues with comments 19 20; types: 21; [M] e.g. like MSTD -- means the system call is MP-safe. If no 22; M prefix is used, the syscall wrapper will obtain the Giant 23; lock for the syscall. 24; STD always included 25; COMPAT included on COMPAT #ifdef 26; COMPAT4 included on COMPAT4 #ifdef (FreeBSD 4 compat) 27; LIBCOMPAT included on COMPAT #ifdef, and placed in syscall.h 28; OBSOL obsolete, not included in system, only specifies name 29; UNIMPL not implemented, placeholder only 30; NOSTD implemented but as a lkm that can be statically 31; compiled in sysent entry will be filled with lkmsys 32; so the SYSCALL_MODULE macro works 33 34+; Please copy any additions and changes to the following compatability tables: 35+; sys/ia64/ia32/syscalls.master (take a best guess) 36+; [other 64 bit platforms with an alternate 32 bit syscall table go here too] 37 38; #ifdef's, etc. may be included, and are copied to the output files. 39 40#include <sys/param.h> 41#include <sys/sysent.h> 42#include <sys/sysproto.h> 43 44; Reserved/unimplemented system calls in the range 0-150 inclusive 45; are reserved for use in future Berkeley releases. 46; Additional system calls implemented in vendor and other 47; redistributions should be placed in the reserved range at the end 48; of the current calls. 49 500 STD NOHIDE { int nosys(void); } syscall nosys_args int 511 MSTD NOHIDE { void sys_exit(int rval); } exit sys_exit_args void 522 MSTD POSIX { int fork(void); } 533 MSTD POSIX { ssize_t read(int fd, void *buf, size_t nbyte); } 544 MSTD POSIX { ssize_t write(int fd, const void *buf, size_t nbyte); } 555 STD POSIX { int open(char *path, int flags, int mode); } 56; XXX should be { int open(const char *path, int flags, ...); } 57; but we're not ready for `const' or varargs. 58; XXX man page says `mode_t mode'. 596 MSTD POSIX { int close(int fd); } 607 MSTD BSD { int wait4(int pid, int *status, int options, \ 61 struct rusage *rusage); } wait4 wait_args int 628 COMPAT BSD { int creat(char *path, int mode); } 639 STD POSIX { int link(char *path, char *link); } 6410 STD POSIX { int unlink(char *path); } 6511 OBSOL NOHIDE execv 6612 STD POSIX { int chdir(char *path); } 6713 STD BSD { int fchdir(int fd); } 6814 STD POSIX { int mknod(char *path, int mode, int dev); } 6915 STD POSIX { int chmod(char *path, int mode); } 7016 STD POSIX { int chown(char *path, int uid, int gid); } 7117 MSTD BSD { int obreak(char *nsize); } break obreak_args int 7218 STD BSD { int getfsstat(struct statfs *buf, long bufsize, \ 73 int flags); } 7419 COMPAT POSIX { long lseek(int fd, long offset, int whence); } 7520 MSTD POSIX { pid_t getpid(void); } 7621 STD BSD { int mount(char *type, char *path, int flags, \ 77 caddr_t data); } 78; XXX `path' should have type `const char *' but we're not ready for that. 7922 STD BSD { int unmount(char *path, int flags); } 8023 MSTD POSIX { int setuid(uid_t uid); } 8124 MSTD POSIX { uid_t getuid(void); } 8225 MSTD POSIX { uid_t geteuid(void); } 8326 STD BSD { int ptrace(int req, pid_t pid, caddr_t addr, \ 84 int data); } 8527 MSTD BSD { int recvmsg(int s, struct msghdr *msg, int flags); } 8628 MSTD BSD { int sendmsg(int s, caddr_t msg, int flags); } 8729 MSTD BSD { int recvfrom(int s, caddr_t buf, size_t len, \ 88 int flags, caddr_t from, int *fromlenaddr); } 8930 MSTD BSD { int accept(int s, caddr_t name, int *anamelen); } 9031 MSTD BSD { int getpeername(int fdes, caddr_t asa, int *alen); } 9132 MSTD BSD { int getsockname(int fdes, caddr_t asa, int *alen); } 9233 STD POSIX { int access(char *path, int flags); } 9334 STD BSD { int chflags(char *path, int flags); } 9435 STD BSD { int fchflags(int fd, int flags); } 9536 STD BSD { int sync(void); } 9637 MSTD POSIX { int kill(int pid, int signum); } 9738 COMPAT POSIX { int stat(char *path, struct ostat *ub); } 9839 MSTD POSIX { pid_t getppid(void); } 9940 COMPAT POSIX { int lstat(char *path, struct ostat *ub); } 10041 STD POSIX { int dup(u_int fd); } 10142 STD POSIX { int pipe(void); } 10243 MSTD POSIX { gid_t getegid(void); } 10344 MSTD BSD { int profil(caddr_t samples, size_t size, \ 104 size_t offset, u_int scale); } 10545 STD BSD { int ktrace(const char *fname, int ops, int facs, \ 106 int pid); } 10746 MCOMPAT POSIX { int sigaction(int signum, struct osigaction *nsa, \ 108 struct osigaction *osa); } 10947 MSTD POSIX { gid_t getgid(void); } 11048 MCOMPAT POSIX { int sigprocmask(int how, osigset_t mask); } 111; XXX note nonstandard (bogus) calling convention - the libc stub passes 112; us the mask, not a pointer to it, and we return the old mask as the 113; (int) return value. 11449 MSTD BSD { int getlogin(char *namebuf, u_int namelen); } 11550 MSTD BSD { int setlogin(char *namebuf); } 11651 MSTD BSD { int acct(char *path); } 11752 MCOMPAT POSIX { int sigpending(void); } 11853 MSTD BSD { int sigaltstack(stack_t *ss, stack_t *oss); } 11954 MSTD POSIX { int ioctl(int fd, u_long com, caddr_t data); } 12055 MSTD BSD { int reboot(int opt); } 12156 STD POSIX { int revoke(char *path); } 12257 STD POSIX { int symlink(char *path, char *link); } 12358 STD POSIX { int readlink(char *path, char *buf, int count); } 12459 MSTD POSIX { int execve(char *fname, char **argv, char **envv); } 12560 MSTD POSIX { int umask(int newmask); } umask umask_args int 12661 STD BSD { int chroot(char *path); } 12762 MCOMPAT POSIX { int fstat(int fd, struct ostat *sb); } 12863 MCOMPAT BSD { int getkerninfo(int op, char *where, size_t *size, \ 129 int arg); } getkerninfo getkerninfo_args int 13064 MCOMPAT BSD { int getpagesize(void); } \ 131 getpagesize getpagesize_args int 13265 STD BSD { int msync(void *addr, size_t len, int flags); } 13366 MSTD BSD { int vfork(void); } 13467 OBSOL NOHIDE vread 13568 OBSOL NOHIDE vwrite 13669 MSTD BSD { int sbrk(int incr); } 13770 MSTD BSD { int sstk(int incr); } 13871 MCOMPAT BSD { int mmap(void *addr, int len, int prot, \ 139 int flags, int fd, long pos); } 14072 MSTD BSD { int ovadvise(int anom); } vadvise ovadvise_args int 14173 MSTD BSD { int munmap(void *addr, size_t len); } 14274 MSTD BSD { int mprotect(const void *addr, size_t len, int prot); } 14375 MSTD BSD { int madvise(void *addr, size_t len, int behav); } 14476 OBSOL NOHIDE vhangup 14577 OBSOL NOHIDE vlimit 14678 MSTD BSD { int mincore(const void *addr, size_t len, \ 147 char *vec); } 14879 MSTD POSIX { int getgroups(u_int gidsetsize, gid_t *gidset); } 14980 MSTD POSIX { int setgroups(u_int gidsetsize, gid_t *gidset); } 15081 MSTD POSIX { int getpgrp(void); } 15182 MSTD POSIX { int setpgid(int pid, int pgid); } 15283 MSTD BSD { int setitimer(u_int which, struct itimerval *itv, \ 153 struct itimerval *oitv); } 15484 MCOMPAT BSD { int wait(void); } 15585 MSTD BSD { int swapon(char *name); } 15686 MSTD BSD { int getitimer(u_int which, struct itimerval *itv); } 15787 MCOMPAT BSD { int gethostname(char *hostname, u_int len); } \ 158 gethostname gethostname_args int 15988 MCOMPAT BSD { int sethostname(char *hostname, u_int len); } \ 160 sethostname sethostname_args int 16189 MSTD BSD { int getdtablesize(void); } 16290 MSTD POSIX { int dup2(u_int from, u_int to); } 16391 UNIMPL BSD getdopt 16492 MSTD POSIX { int fcntl(int fd, int cmd, long arg); } 165; XXX should be { int fcntl(int fd, int cmd, ...); } 166; but we're not ready for varargs. 16793 MSTD BSD { int select(int nd, fd_set *in, fd_set *ou, \ 168 fd_set *ex, struct timeval *tv); } 16994 UNIMPL BSD setdopt 17095 STD POSIX { int fsync(int fd); } 17196 MSTD BSD { int setpriority(int which, int who, int prio); } 17297 MSTD BSD { int socket(int domain, int type, int protocol); } 17398 MSTD BSD { int connect(int s, caddr_t name, int namelen); } 17499 MCPT_NOA BSD { int accept(int s, caddr_t name, int *anamelen); } \ 175 accept accept_args int 176100 MSTD BSD { int getpriority(int which, int who); } 177101 MCOMPAT BSD { int send(int s, caddr_t buf, int len, int flags); } 178102 MCOMPAT BSD { int recv(int s, caddr_t buf, int len, int flags); } 179103 MSTD BSD { int osigreturn(struct osigcontext *sigcntxp); } 180104 MSTD BSD { int bind(int s, caddr_t name, int namelen); } 181105 MSTD BSD { int setsockopt(int s, int level, int name, \ 182 caddr_t val, int valsize); } 183106 MSTD BSD { int listen(int s, int backlog); } 184107 OBSOL NOHIDE vtimes 185108 MCOMPAT BSD { int sigvec(int signum, struct sigvec *nsv, \ 186 struct sigvec *osv); } 187109 MCOMPAT BSD { int sigblock(int mask); } 188110 MCOMPAT BSD { int sigsetmask(int mask); } 189111 MCOMPAT POSIX { int sigsuspend(osigset_t mask); } 190; XXX note nonstandard (bogus) calling convention - the libc stub passes 191; us the mask, not a pointer to it. 192112 MCOMPAT BSD { int sigstack(struct sigstack *nss, \ 193 struct sigstack *oss); } 194113 MCOMPAT BSD { int recvmsg(int s, struct omsghdr *msg, int flags); } 195114 MCOMPAT BSD { int sendmsg(int s, caddr_t msg, int flags); } 196115 OBSOL NOHIDE vtrace 197116 MSTD BSD { int gettimeofday(struct timeval *tp, \ 198 struct timezone *tzp); } 199117 MSTD BSD { int getrusage(int who, struct rusage *rusage); } 200118 MSTD BSD { int getsockopt(int s, int level, int name, \ 201 caddr_t val, int *avalsize); } 202119 UNIMPL NOHIDE resuba (BSD/OS 2.x) 203120 MSTD BSD { int readv(int fd, struct iovec *iovp, u_int iovcnt); } 204121 MSTD BSD { int writev(int fd, struct iovec *iovp, \ 205 u_int iovcnt); } 206122 MSTD BSD { int settimeofday(struct timeval *tv, \ 207 struct timezone *tzp); } 208123 STD BSD { int fchown(int fd, int uid, int gid); } 209124 STD BSD { int fchmod(int fd, int mode); } 210125 MCPT_NOA BSD { int recvfrom(int s, caddr_t buf, size_t len, \ 211 int flags, caddr_t from, int *fromlenaddr); } \ 212 recvfrom recvfrom_args int 213126 MSTD BSD { int setreuid(int ruid, int euid); } 214127 MSTD BSD { int setregid(int rgid, int egid); } 215128 STD POSIX { int rename(char *from, char *to); } 216129 COMPAT BSD { int truncate(char *path, long length); } 217130 COMPAT BSD { int ftruncate(int fd, long length); } 218131 MSTD BSD { int flock(int fd, int how); } 219132 STD POSIX { int mkfifo(char *path, int mode); } 220133 MSTD BSD { int sendto(int s, caddr_t buf, size_t len, \ 221 int flags, caddr_t to, int tolen); } 222134 MSTD BSD { int shutdown(int s, int how); } 223135 MSTD BSD { int socketpair(int domain, int type, int protocol, \ 224 int *rsv); } 225136 STD POSIX { int mkdir(char *path, int mode); } 226137 STD POSIX { int rmdir(char *path); } 227138 STD BSD { int utimes(char *path, struct timeval *tptr); } 228139 OBSOL NOHIDE 4.2 sigreturn 229140 MSTD BSD { int adjtime(struct timeval *delta, \ 230 struct timeval *olddelta); } 231141 MCOMPAT BSD { int getpeername(int fdes, caddr_t asa, int *alen); } 232142 MCOMPAT BSD { long gethostid(void); } 233143 MCOMPAT BSD { int sethostid(long hostid); } 234144 MCOMPAT BSD { int getrlimit(u_int which, struct orlimit *rlp); } 235145 MCOMPAT BSD { int setrlimit(u_int which, struct orlimit *rlp); } 236146 MCOMPAT BSD { int killpg(int pgid, int signum); } 237147 MSTD POSIX { int setsid(void); } 238148 STD BSD { int quotactl(char *path, int cmd, int uid, \ 239 caddr_t arg); } 240149 MCOMPAT BSD { int quota(void); } 241150 MCPT_NOA BSD { int getsockname(int fdec, caddr_t asa, int *alen); }\ 242 getsockname getsockname_args int 243 244; Syscalls 151-180 inclusive are reserved for vendor-specific 245; system calls. (This includes various calls added for compatibity 246; with other Unix variants.) 247; Some of these calls are now supported by BSD... 248151 UNIMPL NOHIDE sem_lock (BSD/OS 2.x) 249152 UNIMPL NOHIDE sem_wakeup (BSD/OS 2.x) 250153 UNIMPL NOHIDE asyncdaemon (BSD/OS 2.x) 251154 UNIMPL NOHIDE nosys 252; 155 is initialized by the NFS code, if present. 253155 MNOIMPL BSD { int nfssvc(int flag, caddr_t argp); } 254156 COMPAT BSD { int getdirentries(int fd, char *buf, u_int count, \ 255 long *basep); } 256157 STD BSD { int statfs(char *path, struct statfs *buf); } 257158 STD BSD { int fstatfs(int fd, struct statfs *buf); } 258159 UNIMPL NOHIDE nosys 259160 UNIMPL NOHIDE nosys 260161 STD BSD { int getfh(char *fname, struct fhandle *fhp); } 261162 MSTD BSD { int getdomainname(char *domainname, int len); } 262163 MSTD BSD { int setdomainname(char *domainname, int len); } 263164 MSTD BSD { int uname(struct utsname *name); } 264165 STD BSD { int sysarch(int op, char *parms); } 265166 MSTD BSD { int rtprio(int function, pid_t pid, \ 266 struct rtprio *rtp); } 267167 UNIMPL NOHIDE nosys 268168 UNIMPL NOHIDE nosys 269; 169 is initialized by the SYSVSEM code if present or loaded 270169 MNOSTD BSD { int semsys(int which, int a2, int a3, int a4, \ 271 int a5); } 272; 169 is initialized by the SYSVMSG code if present or loaded 273; XXX should be { int semsys(int which, ...); } 274170 MNOSTD BSD { int msgsys(int which, int a2, int a3, int a4, \ 275 int a5, int a6); } 276; 169 is initialized by the SYSVSHM code if present or loaded 277; XXX should be { int msgsys(int which, ...); } 278171 MNOSTD BSD { int shmsys(int which, int a2, int a3, int a4); } 279; XXX should be { int shmsys(int which, ...); } 280172 UNIMPL NOHIDE nosys 281173 MSTD POSIX { ssize_t pread(int fd, void *buf, size_t nbyte, \ 282 int pad, off_t offset); } 283174 MSTD POSIX { ssize_t pwrite(int fd, const void *buf, \ 284 size_t nbyte, int pad, off_t offset); } 285175 UNIMPL NOHIDE nosys 286176 MSTD BSD { int ntp_adjtime(struct timex *tp); } 287177 UNIMPL NOHIDE sfork (BSD/OS 2.x) 288178 UNIMPL NOHIDE getdescriptor (BSD/OS 2.x) 289179 UNIMPL NOHIDE setdescriptor (BSD/OS 2.x) 290180 UNIMPL NOHIDE nosys 291 292; Syscalls 181-199 are used by/reserved for BSD 293181 MSTD POSIX { int setgid(gid_t gid); } 294182 MSTD BSD { int setegid(gid_t egid); } 295183 MSTD BSD { int seteuid(uid_t euid); } 296184 UNIMPL BSD lfs_bmapv 297185 UNIMPL BSD lfs_markv 298186 UNIMPL BSD lfs_segclean 299187 UNIMPL BSD lfs_segwait 300188 STD POSIX { int stat(char *path, struct stat *ub); } 301189 MSTD POSIX { int fstat(int fd, struct stat *sb); } 302190 STD POSIX { int lstat(char *path, struct stat *ub); } 303191 STD POSIX { int pathconf(char *path, int name); } 304192 MSTD POSIX { int fpathconf(int fd, int name); } 305193 UNIMPL NOHIDE nosys 306194 MSTD BSD { int getrlimit(u_int which, \ 307 struct rlimit *rlp); } \ 308 getrlimit __getrlimit_args int 309195 MSTD BSD { int setrlimit(u_int which, \ 310 struct rlimit *rlp); } \ 311 setrlimit __setrlimit_args int 312196 STD BSD { int getdirentries(int fd, char *buf, u_int count, \ 313 long *basep); } 314197 MSTD BSD { caddr_t mmap(caddr_t addr, size_t len, int prot, \ 315 int flags, int fd, int pad, off_t pos); } 316198 STD NOHIDE { int nosys(void); } __syscall __syscall_args int 317199 STD POSIX { off_t lseek(int fd, int pad, off_t offset, \ 318 int whence); } 319200 STD BSD { int truncate(char *path, int pad, off_t length); } 320201 STD BSD { int ftruncate(int fd, int pad, off_t length); } 321202 MSTD BSD { int __sysctl(int *name, u_int namelen, void *old, \ 322 size_t *oldlenp, void *new, size_t newlen); } \ 323 __sysctl sysctl_args int 324; properly, __sysctl should be a NOHIDE, but making an exception 325; here allows to avoid one in libc/sys/Makefile.inc. 326203 MSTD BSD { int mlock(const void *addr, size_t len); } 327204 MSTD BSD { int munlock(const void *addr, size_t len); } 328205 STD BSD { int undelete(char *path); } 329206 STD BSD { int futimes(int fd, struct timeval *tptr); } 330207 MSTD BSD { int getpgid(pid_t pid); } 331208 UNIMPL NOHIDE newreboot (NetBSD) 332209 MSTD BSD { int poll(struct pollfd *fds, u_int nfds, \ 333 int timeout); } 334 335; 336; The following are reserved for loadable syscalls 337; 338210 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 339211 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 340212 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 341213 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 342214 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 343215 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 344216 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 345217 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 346218 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 347219 NODEF NOHIDE lkmnosys lkmnosys nosys_args int 348 349; 350; The following were introduced with NetBSD/4.4Lite-2 351; They are initialized by thier respective modules/sysinits 352220 MNOSTD BSD { int __semctl(int semid, int semnum, int cmd, \ 353 union semun *arg); } 354221 MNOSTD BSD { int semget(key_t key, int nsems, int semflg); } 355222 MNOSTD BSD { int semop(int semid, struct sembuf *sops, \ 356 u_int nsops); } 357223 UNIMPL NOHIDE semconfig 358224 MNOSTD BSD { int msgctl(int msqid, int cmd, \ 359 struct msqid_ds *buf); } 360225 MNOSTD BSD { int msgget(key_t key, int msgflg); } 361226 MNOSTD BSD { int msgsnd(int msqid, void *msgp, size_t msgsz, \ 362 int msgflg); } 363227 MNOSTD BSD { int msgrcv(int msqid, void *msgp, size_t msgsz, \ 364 long msgtyp, int msgflg); } 365228 MNOSTD BSD { int shmat(int shmid, void *shmaddr, int shmflg); } 366229 MNOSTD BSD { int shmctl(int shmid, int cmd, \ 367 struct shmid_ds *buf); } 368230 MNOSTD BSD { int shmdt(void *shmaddr); } 369231 MNOSTD BSD { int shmget(key_t key, int size, int shmflg); } 370; 371232 MSTD POSIX { int clock_gettime(clockid_t clock_id, \ 372 struct timespec *tp); } 373233 MSTD POSIX { int clock_settime(clockid_t clock_id, \ 374 const struct timespec *tp); } 375234 MSTD POSIX { int clock_getres(clockid_t clock_id, \ 376 struct timespec *tp); } 377235 UNIMPL NOHIDE timer_create 378236 UNIMPL NOHIDE timer_delete 379237 UNIMPL NOHIDE timer_settime 380238 UNIMPL NOHIDE timer_gettime 381239 UNIMPL NOHIDE timer_getoverrun 382240 MSTD POSIX { int nanosleep(const struct timespec *rqtp, \ 383 struct timespec *rmtp); } 384241 UNIMPL NOHIDE nosys 385242 UNIMPL NOHIDE nosys 386243 UNIMPL NOHIDE nosys 387244 UNIMPL NOHIDE nosys 388245 UNIMPL NOHIDE nosys 389246 UNIMPL NOHIDE nosys 390247 UNIMPL NOHIDE nosys 391248 UNIMPL NOHIDE nosys 392249 UNIMPL NOHIDE nosys 393; syscall numbers initially used in OpenBSD 394250 MSTD BSD { int minherit(void *addr, size_t len, int inherit); } 395251 MSTD BSD { int rfork(int flags); } 396252 MSTD BSD { int openbsd_poll(struct pollfd *fds, u_int nfds, \ 397 int timeout); } 398253 STD BSD { int issetugid(void); } 399254 STD BSD { int lchown(char *path, int uid, int gid); } 400255 UNIMPL NOHIDE nosys 401256 UNIMPL NOHIDE nosys 402257 UNIMPL NOHIDE nosys 403258 UNIMPL NOHIDE nosys 404259 UNIMPL NOHIDE nosys 405260 UNIMPL NOHIDE nosys 406261 UNIMPL NOHIDE nosys 407262 UNIMPL NOHIDE nosys 408263 UNIMPL NOHIDE nosys 409264 UNIMPL NOHIDE nosys 410265 UNIMPL NOHIDE nosys 411266 UNIMPL NOHIDE nosys 412267 UNIMPL NOHIDE nosys 413268 UNIMPL NOHIDE nosys 414269 UNIMPL NOHIDE nosys 415270 UNIMPL NOHIDE nosys 416271 UNIMPL NOHIDE nosys 417272 STD BSD { int getdents(int fd, char *buf, size_t count); } 418273 UNIMPL NOHIDE nosys 419274 STD BSD { int lchmod(char *path, mode_t mode); } 420275 NOPROTO BSD { int lchown(char *path, uid_t uid, gid_t gid); } netbsd_lchown lchown_args int 421276 STD BSD { int lutimes(char *path, struct timeval *tptr); } 422277 MNOPROTO BSD { int msync(void *addr, size_t len, int flags); } netbsd_msync msync_args int 423278 STD BSD { int nstat(char *path, struct nstat *ub); } 424279 MSTD BSD { int nfstat(int fd, struct nstat *sb); } 425280 STD BSD { int nlstat(char *path, struct nstat *ub); } 426281 UNIMPL NOHIDE nosys 427282 UNIMPL NOHIDE nosys 428283 UNIMPL NOHIDE nosys 429284 UNIMPL NOHIDE nosys 430285 UNIMPL NOHIDE nosys 431286 UNIMPL NOHIDE nosys 432287 UNIMPL NOHIDE nosys 433288 UNIMPL NOHIDE nosys 434289 UNIMPL NOHIDE nosys 435290 UNIMPL NOHIDE nosys 436291 UNIMPL NOHIDE nosys 437292 UNIMPL NOHIDE nosys 438293 UNIMPL NOHIDE nosys 439294 UNIMPL NOHIDE nosys 440295 UNIMPL NOHIDE nosys 441296 UNIMPL NOHIDE nosys 442; XXX 297 is 300 in NetBSD 443297 STD BSD { int fhstatfs(const struct fhandle *u_fhp, struct statfs *buf); } 444298 STD BSD { int fhopen(const struct fhandle *u_fhp, int flags); } 445299 STD BSD { int fhstat(const struct fhandle *u_fhp, struct stat *sb); } 446; syscall numbers for FreeBSD 447300 MSTD BSD { int modnext(int modid); } 448301 MSTD BSD { int modstat(int modid, struct module_stat* stat); } 449302 MSTD BSD { int modfnext(int modid); } 450303 MSTD BSD { int modfind(const char *name); } 451304 MSTD BSD { int kldload(const char *file); } 452305 MSTD BSD { int kldunload(int fileid); } 453306 MSTD BSD { int kldfind(const char *file); } 454307 MSTD BSD { int kldnext(int fileid); } 455308 MSTD BSD { int kldstat(int fileid, struct kld_file_stat* stat); } 456309 MSTD BSD { int kldfirstmod(int fileid); } 457310 MSTD BSD { int getsid(pid_t pid); } 458311 MSTD BSD { int setresuid(uid_t ruid, uid_t euid, uid_t suid); } 459312 MSTD BSD { int setresgid(gid_t rgid, gid_t egid, gid_t sgid); } 460313 OBSOL NOHIDE signanosleep 461314 NOSTD BSD { int aio_return(struct aiocb *aiocbp); } 462315 NOSTD BSD { int aio_suspend(struct aiocb * const * aiocbp, int nent, const struct timespec *timeout); } 463316 NOSTD BSD { int aio_cancel(int fd, struct aiocb *aiocbp); } 464317 NOSTD BSD { int aio_error(struct aiocb *aiocbp); } 465318 NOSTD BSD { int aio_read(struct aiocb *aiocbp); } 466319 NOSTD BSD { int aio_write(struct aiocb *aiocbp); } 467320 NOSTD BSD { int lio_listio(int mode, struct aiocb * const *acb_list, int nent, struct sigevent *sig); } 468321 MSTD BSD { int yield(void); } 469322 OBSOL NOHIDE thr_sleep 470323 OBSOL NOHIDE thr_wakeup 471324 MSTD BSD { int mlockall(int how); } 472325 MSTD BSD { int munlockall(void); } 473326 STD BSD { int __getcwd(u_char *buf, u_int buflen); } 474 475327 MSTD POSIX { int sched_setparam (pid_t pid, const struct sched_param *param); } 476328 MSTD POSIX { int sched_getparam (pid_t pid, struct sched_param *param); } 477 478329 MSTD POSIX { int sched_setscheduler (pid_t pid, int policy, const struct sched_param *param); } 479330 MSTD POSIX { int sched_getscheduler (pid_t pid); } 480 481331 MSTD POSIX { int sched_yield (void); } 482332 MSTD POSIX { int sched_get_priority_max (int policy); } 483333 MSTD POSIX { int sched_get_priority_min (int policy); } 484334 MSTD POSIX { int sched_rr_get_interval (pid_t pid, struct timespec *interval); } 485335 STD BSD { int utrace(const void *addr, size_t len); } 486336 MCOMPAT4 BSD { int sendfile(int fd, int s, off_t offset, size_t nbytes, \ 487 struct sf_hdtr *hdtr, off_t *sbytes, int flags); } 488337 STD BSD { int kldsym(int fileid, int cmd, void *data); } 489338 MSTD BSD { int jail(struct jail *jail); } 490339 UNIMPL BSD pioctl 491340 MSTD POSIX { int sigprocmask(int how, const sigset_t *set, \ 492 sigset_t *oset); } 493341 MSTD POSIX { int sigsuspend(const sigset_t *sigmask); } 494342 MSTD POSIX { int sigaction(int sig, const struct sigaction *act, \ 495 struct sigaction *oact); } 496343 MSTD POSIX { int sigpending(sigset_t *set); } 497344 MSTD BSD { int sigreturn(const struct __ucontext *sigcntxp); } 498345 UNIMPL NOHIDE sigtimedwait 499346 UNIMPL NOHIDE sigwaitinfo 500347 MSTD BSD { int __acl_get_file(const char *path, \ 501 acl_type_t type, struct acl *aclp); } 502348 MSTD BSD { int __acl_set_file(const char *path, \ 503 acl_type_t type, struct acl *aclp); } 504349 MSTD BSD { int __acl_get_fd(int filedes, acl_type_t type, \ 505 struct acl *aclp); } 506350 MSTD BSD { int __acl_set_fd(int filedes, acl_type_t type, \ 507 struct acl *aclp); } 508351 MSTD BSD { int __acl_delete_file(const char *path, \ 509 acl_type_t type); } 510352 MSTD BSD { int __acl_delete_fd(int filedes, acl_type_t type); } 511353 MSTD BSD { int __acl_aclcheck_file(const char *path, \ 512 acl_type_t type, struct acl *aclp); } 513354 MSTD BSD { int __acl_aclcheck_fd(int filedes, acl_type_t type, \ 514 struct acl *aclp); } 515355 STD BSD { int extattrctl(const char *path, int cmd, \ 516 const char *filename, int attrnamespace, \ 517 const char *attrname); } 518356 STD BSD { int extattr_set_file(const char *path, \ 519 int attrnamespace, const char *attrname, \ 520 void *data, size_t nbytes); } 521357 STD BSD { ssize_t extattr_get_file(const char *path, \ 522 int attrnamespace, const char *attrname, \ 523 void *data, size_t nbytes); } 524358 STD BSD { int extattr_delete_file(const char *path, \ 525 int attrnamespace, const char *attrname); } 526359 NOSTD BSD { int aio_waitcomplete(struct aiocb **aiocbp, struct timespec *timeout); } 527360 MSTD BSD { int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid); } 528361 MSTD BSD { int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid); } 529362 MSTD BSD { int kqueue(void); } 530363 MSTD BSD { int kevent(int fd, \ 531 const struct kevent *changelist, int nchanges, \ 532 struct kevent *eventlist, int nevents, \ 533 const struct timespec *timeout); } 534364 UNIMPL BSD __cap_get_proc 535365 UNIMPL BSD __cap_set_proc 536366 UNIMPL BSD __cap_get_fd 537367 UNIMPL BSD __cap_get_file 538368 UNIMPL BSD __cap_set_fd 539369 UNIMPL BSD __cap_set_file 540370 NODEF NOHIDE lkmressys lkmressys nosys_args int 541371 STD BSD { int extattr_set_fd(int fd, int attrnamespace, \ 542 const char *attrname, void *data, \ 543 size_t nbytes); } 544372 STD BSD { ssize_t extattr_get_fd(int fd, int attrnamespace, \ 545 const char *attrname, void *data, size_t nbytes); } 546373 STD BSD { int extattr_delete_fd(int fd, int attrnamespace, \ 547 const char *attrname); } 548374 MSTD BSD { int __setugid(int flag); } 549375 NOIMPL BSD { int nfsclnt(int flag, caddr_t argp); } 550376 STD BSD { int eaccess(char *path, int flags); } 551377 UNIMPL BSD afs_syscall 552378 STD BSD { int nmount(struct iovec *iovp, unsigned int iovcnt, \ 553 int flags); } 554379 STD BSD { int kse_exit(void); } 555380 STD BSD { int kse_wakeup(struct kse_mailbox *mbx); } 556381 STD BSD { int kse_create(struct kse_mailbox *mbx, \ 557 int newgroup); } 558382 STD BSD { int kse_thr_interrupt(struct kse_thr_mailbox *tmbx); } 559383 MSTD BSD { int kse_release(void); } 560384 MSTD BSD { int __mac_get_proc(struct mac *mac_p); } 561385 MSTD BSD { int __mac_set_proc(struct mac *mac_p); } 562386 MSTD BSD { int __mac_get_fd(int fd, struct mac *mac_p); } 563387 MSTD BSD { int __mac_get_file(const char *path_p, \ 564 struct mac *mac_p); } 565388 MSTD BSD { int __mac_set_fd(int fd, struct mac *mac_p); } 566389 MSTD BSD { int __mac_set_file(const char *path_p, \ 567 struct mac *mac_p); } 568390 STD BSD { int kenv(int what, const char *name, char *value, \ 569 int len); } 570391 STD BSD { int lchflags(const char *path, int flags); } 571392 STD BSD { int uuidgen(struct uuid *store, int count); } 572393 MSTD BSD { int sendfile(int fd, int s, off_t offset, size_t nbytes, \ 573 struct sf_hdtr *hdtr, off_t *sbytes, int flags); } 574394 MSTD BSD { int mac_syscall(const char *policy, int call, \ 575 void *arg); } 576395 UNIMPL NOHIDE nosys 577396 UNIMPL NOHIDE nosys 578397 UNIMPL NOHIDE nosys 579398 UNIMPL NOHIDE nosys 580399 UNIMPL NOHIDE nosys 581400 MNOSTD BSD { int ksem_close(semid_t id); } 582401 MNOSTD BSD { int ksem_post(semid_t id); } 583402 MNOSTD BSD { int ksem_wait(semid_t id); } 584403 MNOSTD BSD { int ksem_trywait(semid_t id); } 585404 MNOSTD BSD { int ksem_init(semid_t *idp, unsigned int value); } 586405 MNOSTD BSD { int ksem_open(semid_t *idp, const char *name, \ 587 int oflag, mode_t mode, unsigned int value); } 588406 MNOSTD BSD { int ksem_unlink(const char *name); } 589407 MNOSTD BSD { int ksem_getvalue(semid_t id, int *val); } 590408 MNOSTD BSD { int ksem_destroy(semid_t id); } 591409 UNIMPL BSD __mac_get_pid 592410 UNIMPL BSD __mac_get_link 593411 UNIMPL BSD __mac_set_link 594412 STD BSD { int extattr_set_link(const char *path, \ 595 int attrnamespace, const char *attrname, \ 596 void *data, size_t nbytes); } 597413 STD BSD { ssize_t extattr_get_link(const char *path, \ 598 int attrnamespace, const char *attrname, \ 599 void *data, size_t nbytes); } 600414 STD BSD { int extattr_delete_link(const char *path, \ 601 int attrnamespace, const char *attrname); } 602 603; Please copy any additions and changes to the following compatability tables: 604; sys/ia64/ia32/syscalls.master (take a best guess) 605; [other 64 bit platforms with an alternate 32 bit syscall table go here too] 606