$OpenBSD: syscalls.master,v 1.64 2011/09/19 22:49:37 pirofti Exp $ ; $NetBSD: syscalls.master,v 1.15 1995/12/18 14:35:10 fvdl Exp $ ; @(#)syscalls.master 8.1 (Berkeley) 7/19/93 ; OpenBSD COMPAT_LINUX system call name/number "master" file. ; (See syscalls.conf to see what it is processed into.) ; ; Fields: number type [type-dependent ...] ; number system call number, must be in order ; type one of STD, OBSOL, UNIMPL, NODEF, NOARGS, or one of ; the compatibility options defined in syscalls.conf. ; ; types: ; STD always included ; OBSOL obsolete, not included in system ; UNIMPL unimplemented, not included in system ; NODEF included, but don't define the syscall number ; NOARGS included, but don't define the syscall args structure ; ; The compat options are defined in the syscalls.conf file, and the ; compat option name is prefixed to the syscall name. Other than ; that, they're like NODEF (for 'compat' options), or STD (for ; 'libcompat' options). ; ; The type-dependent arguments are as follows: ; For STD, NODEF, NOARGS, and compat syscalls: ; { pseudo-proto } [alias] ; For other syscalls: ; [comment] ; ; #ifdef's, etc. may be included, and are copied to the output files. ; #include's are copied to the syscall switch definition file only. #include #include #include #include #include #include #include #include #include #include 0 NOARGS { int sys_nosys(void); } syscall 1 NOARGS { int sys_exit(int rval); } 2 NOARGS { int sys_fork(void); } 3 NOARGS { int sys_read(int fd, char *buf, u_int nbyte); } 4 NOARGS { int sys_write(int fd, char *buf, u_int nbyte); } 5 STD { int linux_sys_open(char *path, int flags, int mode); } 6 NOARGS { int sys_close(int fd); } 7 STD { int linux_sys_waitpid(int pid, int *status, \ int options);} 8 STD { int linux_sys_creat(char *path, int mode); } 9 NOARGS { int sys_link(char *path, char *link); } 10 STD { int linux_sys_unlink(char *path); } 11 STD { int linux_sys_execve(char *path, char **argp, \ char **envp); } 12 STD { int linux_sys_chdir(char *path); } 13 STD { int linux_sys_time(linux_time_t *t); } 14 STD { int linux_sys_mknod(char *path, int mode, int dev); } 15 STD { int linux_sys_chmod(char *path, int mode); } 16 STD { int linux_sys_lchown16(char *path, int uid, \ int gid); } 17 STD { int linux_sys_break(char *nsize); } 18 STD { int linux_sys_ostat(void); } 19 STD { long linux_sys_lseek(int fd, long offset, \ int whence); } 20 STD { pid_t linux_sys_getpid(void); } 21 STD { int linux_sys_mount(char *specialfile, char *dir, \ char *filesystemtype, long rwflag, void *data); } 22 STD { int linux_sys_umount(char *specialfile); } 23 NOARGS linux_setuid16 { int sys_setuid(uid_t uid); } 24 STD linux_getuid16 { uid_t linux_sys_getuid(void); } 25 STD { int linux_sys_stime(linux_time_t *t); } #ifdef PTRACE 26 STD { int linux_sys_ptrace(void); } #else 26 UNIMPL ptrace #endif 27 STD { int linux_sys_alarm(unsigned int secs); } 28 STD { int linux_sys_ofstat(void); } 29 STD { int linux_sys_pause(void); } 30 STD { int linux_sys_utime(char *path, \ struct linux_utimbuf *times); } 31 STD { int linux_sys_stty(void); } 32 STD { int linux_sys_gtty(void); } 33 STD { int linux_sys_access(char *path, int flags); } 34 STD { int linux_sys_nice(int incr); } 35 STD { int linux_sys_ftime(void); } 36 NOARGS { int sys_sync(void); } 37 STD { int linux_sys_kill(int pid, int signum); } 38 STD { int linux_sys_rename(char *from, char *to); } 39 STD { int linux_sys_mkdir(char *path, int mode); } 40 STD { int linux_sys_rmdir(char *path); } 41 NOARGS { int sys_dup(u_int fd); } 42 NOARGS { int sys_pipe(int *fdp); } 43 STD { int linux_sys_times(struct times *tms); } 44 STD { int linux_sys_prof(void); } 45 STD { int linux_sys_brk(char *nsize); } 46 NOARGS linux_setgid16 { int sys_setgid(gid_t gid); } 47 STD linux_getgid16 { gid_t linux_sys_getgid(void); } 48 STD { int linux_sys_signal(int sig, \ linux_handler_t handler); } 49 NOARGS linux_geteuid16 { uid_t sys_geteuid(void); } 50 NOARGS linux_getegid16 { gid_t sys_getegid(void); } #ifdef ACCOUNTING 51 NOARGS { int sys_acct(char *path); } #else 51 UNIMPL acct #endif 52 STD { int linux_sys_phys(void); } 53 STD { int linux_sys_lock(void); } 54 STD { int linux_sys_ioctl(int fd, u_long com, \ caddr_t data); } 55 STD { int linux_sys_fcntl(int fd, int cmd, void *arg); } 56 STD { int linux_sys_mpx(void); } 57 NOARGS { int sys_setpgid(int pid, int pgid); } 58 STD { int linux_sys_ulimit(void); } 59 STD { int linux_sys_oldolduname(struct linux_oldold_utsname *up); } 60 NOARGS { int sys_umask(int newmask); } 61 NOARGS { int sys_chroot(char *path); } 62 STD { int linux_sys_ustat(void); } 63 NOARGS { int sys_dup2(u_int from, u_int to); } 64 NOARGS { pid_t sys_getppid(void); } 65 NOARGS { int sys_getpgrp(void); } 66 NOARGS { int sys_setsid(void); } 67 STD { int linux_sys_sigaction(int signum, \ struct linux_old_sigaction *nsa, \ struct linux_old_sigaction *osa); } 68 STD { int linux_sys_siggetmask(void); } 69 STD { int linux_sys_sigsetmask(linux_old_sigset_t mask); } 70 STD { int linux_sys_setreuid16(int ruid, int euid); } 71 STD { int linux_sys_setregid16(int rgid, int egid); } 72 STD { int linux_sys_sigsuspend(caddr_t restart, \ int oldmask, int mask); } 73 STD { int linux_sys_sigpending(linux_old_sigset_t *mask); } 74 STD { int linux_sys_sethostname(char *hostname, u_int len);} 75 STD { int linux_sys_setrlimit(u_int which, \ struct linux_rlimit *rlp); } 76 STD { int linux_sys_getrlimit(u_int which, \ struct linux_rlimit *rlp); } 77 NOARGS { int sys_getrusage(int who, struct rusage *rusage); } 78 NOARGS { int sys_gettimeofday(struct timeval *tp, \ struct timezone *tzp); } 79 NOARGS { int sys_settimeofday(struct timeval *tp, \ struct timezone *tzp); } 80 NOARGS linux_getgroups { int sys_getgroups(u_int gidsetsize, \ gid_t *gidset); } 81 NOARGS linux_setgroups { int sys_setgroups(u_int gidsetsize, \ gid_t *gidset); } 82 STD { int linux_sys_oldselect(struct linux_select *lsp); } 83 STD { int linux_sys_symlink(char *path, char *to); } 84 NOARGS { int linux_sys_lstat(char *path, \ struct linux_stat *up); } olstat 85 STD { int linux_sys_readlink(char *name, char *buf, \ int count); } 86 STD { int linux_sys_uselib(char *path); } 87 STD { int linux_sys_swapon(char *name); } 88 NOARGS { int sys_reboot(int opt); } 89 STD { int linux_sys_readdir(int fd, caddr_t dent, \ unsigned int count); } 90 STD { int linux_sys_mmap(struct linux_mmap *lmp); } 91 NOARGS { int sys_munmap(caddr_t addr, int len); } 92 STD { int linux_sys_truncate(char *path, long length); } 93 STD { int linux_sys_ftruncate(int fd, long length); } 94 NOARGS { int sys_fchmod(int fd, int mode); } 95 STD { int linux_sys_fchown16(int fd, int uid, int gid); } 96 NOARGS { int sys_getpriority(int which, int who); } 97 NOARGS { int sys_setpriority(int which, int who, int prio); } 98 NOARGS { int sys_profil(caddr_t samples, u_int size, \ u_int offset, u_int scale); } 99 STD { int linux_sys_statfs(char *path, \ struct linux_statfs *sp); } 100 STD { int linux_sys_fstatfs(int fd, \ struct linux_statfs *sp); } #ifdef __i386__ 101 STD { int linux_sys_ioperm(unsigned int lo, \ unsigned int hi, int val); } #else 101 STD { int linux_sys_ioperm(void); } #endif 102 STD { int linux_sys_socketcall(int what, void *args); } 103 STD { int linux_sys_klog(void); } 104 NOARGS { int sys_setitimer(u_int which, \ struct itimerval *itv, struct itimerval *oitv); } 105 NOARGS { int sys_getitimer(u_int which, \ struct itimerval *itv); } 106 STD { int linux_sys_stat(char *path, \ struct linux_stat *sp); } 107 STD { int linux_sys_lstat(char *path, \ struct linux_stat *sp); } 108 STD { int linux_sys_fstat(int fd, struct linux_stat *sp); } 109 STD { int linux_sys_olduname(struct linux_old_utsname *up); } #ifdef __i386__ 110 STD { int linux_sys_iopl(int level); } #else 110 STD { int linux_sys_iopl(void); } #endif 111 STD { int linux_sys_vhangup(void); } 112 STD { int linux_sys_idle(void); } 113 STD { int linux_sys_vm86old(void); } 114 STD { int linux_sys_wait4(int pid, int *status, \ int options, struct rusage *rusage); } 115 STD { int linux_sys_swapoff(void); } 116 STD { int linux_sys_sysinfo(struct linux_sys_sysinfo_args *sysinfo); } 117 STD { int linux_sys_ipc(int what, int a1, int a2, int a3, \ caddr_t ptr); } 118 NOARGS { int sys_fsync(int fd); } 119 STD { int linux_sys_sigreturn(struct linux_sigcontext *scp); } 120 STD { int linux_sys_clone(int flags, void *stack, \ void *parent_tidptr, void *tls, void *child_tidptr); } 121 STD { int linux_sys_setdomainname(char *name, int len); } 122 STD { int linux_sys_uname(struct linux_utsname *up); } #ifdef __i386__ 123 STD { int linux_sys_modify_ldt(int func, void *ptr, \ size_t bytecount); } #else 123 STD { int linux_sys_modify_ldt(void); } #endif 124 STD { int linux_sys_adjtimex(void); } 125 STD { int linux_sys_mprotect(caddr_t addr, int len, int prot); } 126 STD { int linux_sys_sigprocmask(int how, \ linux_old_sigset_t *set, linux_old_sigset_t *oset); } 127 STD { int linux_sys_create_module(void); } 128 STD { int linux_sys_init_module(void); } 129 STD { int linux_sys_delete_module(void); } 130 STD { int linux_sys_get_kernel_syms(void); } 131 STD { int linux_sys_quotactl(void); } 132 STD { int linux_sys_getpgid(int pid); } 133 NOARGS { int sys_fchdir(int fd); } 134 STD { int linux_sys_bdflush(void); } 135 STD { int linux_sys_sysfs(void); } 136 STD { int linux_sys_personality(int per); } 137 STD { int linux_sys_afs_syscall(void); } 138 NOARGS linux_setfsuid16 { int linux_sys_setfsuid(uid_t uid); } 139 NOARGS linux_getfsuid16 { int linux_sys_getfsuid(void); } 140 STD { int linux_sys_llseek(int fd, u_int32_t ohigh, \ u_int32_t olow, caddr_t res, int whence); } 141 STD { int linux_sys_getdents(int fd, void *dirent, \ unsigned count); } 142 STD { int linux_sys_select(int nfds, fd_set *readfds, \ fd_set *writefds, fd_set *exceptfds, \ struct timeval *timeout); } 143 NOARGS { int sys_flock(int fd, int how); } 144 NOARGS { int sys_msync(void *addr, int len, int fl); } 145 NOARGS { int sys_readv(int fd, struct iovec *iovp, \ u_int iovcnt); } 146 NOARGS { int sys_writev(int fd, struct iovec *iovp, \ u_int iovcnt); } 147 NOARGS { int sys_getsid(pid_t pid); } 148 STD { int linux_sys_fdatasync(int fd); } 149 STD { int linux_sys___sysctl(struct linux___sysctl *lsp); } 150 NOARGS { int sys_mlock(caddr_t addr, size_t len); } 151 NOARGS { int sys_munlock(caddr_t addr, size_t len); } 152 STD { int linux_sys_mlockall(void); } 153 STD { int linux_sys_munlockall(void); } 154 STD { int linux_sys_sched_setparam(linux_pid_t pid, \ const struct linux_sched_param *sp); } 155 STD { int linux_sys_sched_getparam(linux_pid_t pid, \ struct linux_sched_param *sp); } 156 STD { int linux_sys_sched_setscheduler(linux_pid_t pid, \ int policy, const struct linux_sched_param *sp); } 157 STD { int linux_sys_sched_getscheduler(linux_pid_t pid); } 158 STD { int linux_sys_sched_yield(void); } 159 STD { int linux_sys_sched_get_priority_max(int policy); } 160 STD { int linux_sys_sched_get_priority_min(int policy); } 161 STD { int linux_sys_sched_rr_get_interval(void); } 162 NOARGS { int sys_nanosleep(const struct timespec *rqtp, \ struct timespec *rmtp); } 163 STD { int linux_sys_mremap(void *old_address, \ size_t old_size, size_t new_size, long flags); } 164 STD { int linux_sys_setresuid16(u_int16_t ruid, \ u_int16_t euid, u_int16_t suid); } 165 STD { int linux_sys_getresuid16(u_int16_t *ruid, \ u_int16_t *euid, u_int16_t *suid); } 166 STD { int linux_sys_vm86(void); } 167 STD { int linux_sys_query_module(void); } 168 NOARGS { int sys_poll(struct pollfd *fds, u_int nfds, \ int timeout); } 169 STD { int linux_sys_nfsservctl(void); } 170 STD { int linux_sys_setresgid16(u_int16_t rgid, \ u_int16_t egid, u_int16_t sgid); } 171 STD { int linux_sys_getresgid16(u_int16_t *rgid, \ u_int16_t *egid, u_int16_t *sgid); } 172 STD { int linux_sys_prctl(void); } 173 STD { int linux_sys_rt_sigreturn( \ struct linux_rt_sigframe *sfp); } 174 STD { int linux_sys_rt_sigaction(int signum, \ struct linux_sigaction *nsa, \ struct linux_sigaction *osa, \ size_t sigsetsize); } 175 STD { int linux_sys_rt_sigprocmask(int how, \ const linux_sigset_t *set, \ linux_sigset_t *oset, size_t sigsetsize); } 176 STD { int linux_sys_rt_sigpending(linux_sigset_t *set, \ size_t sigsetsize); } 177 STD { int linux_sys_rt_sigtimedwait(void); } 178 STD { int linux_sys_rt_queueinfo(void); } 179 STD { int linux_sys_rt_sigsuspend(linux_sigset_t *unewset, \ size_t sigsetsize); } 180 STD { int linux_sys_pread(int fd, char *buf, \ size_t nbyte, linux_off_t offset); } 181 STD { int linux_sys_pwrite(int fd, char *buf, \ size_t nbyte, linux_off_t offset); } 182 STD { int linux_sys_chown16(char *path, int uid, \ int gid); } 183 NOARGS { int sys___getcwd(char *bufp, size_t length); } 184 STD { int linux_sys_capget(void); } 185 STD { int linux_sys_capset(void); } 186 STD { int linux_sys_sigaltstack( \ const struct linux_sigaltstack *nss, \ struct linux_sigaltstack *oss); } 187 STD { int linux_sys_sendfile(void); } 188 STD { int linux_sys_getpmsg(void); } 189 STD { int linux_sys_putpmsg(void); } 190 STD { int sys_vfork(void); } 191 STD { int linux_sys_ugetrlimit(u_int which, \ struct linux_rlimit *rlp); } 192 STD { linux_off_t linux_sys_mmap2(unsigned long addr, \ size_t len, int prot, int flags, int fd, \ linux_off_t offset); } 193 STD { int linux_sys_truncate64(char *path, off_t length); } 194 STD { int linux_sys_ftruncate64(int fd, off_t length); } 195 STD { int linux_sys_stat64(char *path, \ struct linux_stat64 *sp); } 196 STD { int linux_sys_lstat64(char *path, \ struct linux_stat64 *sp); } 197 STD { int linux_sys_fstat64(int fd, \ struct linux_stat64 *sp); } 198 NOARGS { int linux_sys_lchown(void); } 199 STD { uid_t linux_sys_getuid(void); } 200 STD { gid_t linux_sys_getgid(void); } 201 NOARGS { uid_t sys_geteuid(void); } 202 NOARGS { gid_t sys_getegid(void); } 203 NOARGS { int sys_setreuid(int ruid, int euid); } 204 NOARGS { int sys_setregid(int rgid, int egid); } 205 NOARGS { int sys_getgroups(u_int gidsetsize, gid_t *gidset); } 206 NOARGS { int sys_setgroups(u_int gidsetsize, gid_t *gidset); } 207 NOARGS { int linux_sys_fchown(void); } 208 NOARGS { int sys_setresuid(uid_t ruid, uid_t euid, \ uid_t suid); } 209 NOARGS { int sys_getresuid(uid_t *ruid, uid_t *euid, \ uid_t *suid); } 210 NOARGS { int sys_setresgid(gid_t rgid, gid_t egid, \ gid_t sgid); } 211 NOARGS { int sys_getresgid(gid_t *rgid, gid_t *egid, \ gid_t *sgid); } 212 NOARGS { int linux_sys_chown(void); } 213 NOARGS { int sys_setuid(uid_t uid); } 214 NOARGS { int sys_setgid(gid_t gid); } 215 STD { int linux_sys_setfsuid(uid_t uid); } 216 NOARGS { int linux_sys_setfsgid(void); } 217 NOARGS { int linux_sys_pivot_root(void); } 218 NOARGS { int linux_sys_mincore(void); } 219 NOARGS { int sys_madvise(void *addr, size_t len, int behav); } 220 STD { int linux_sys_getdents64(int fd, void *dirent, \ unsigned count); } 221 STD { int linux_sys_fcntl64(u_int fd, u_int cmd, \ void *arg); } 222 UNIMPL 223 UNIMPL 224 UNIMPL linux_sys_gettid 225 UNIMPL linux_sys_readahead 226 NOARGS { int linux_sys_setxattr(void); } 227 NOARGS { int linux_sys_lsetxattr(void); } 228 NOARGS { int linux_sys_fsetxattr(void); } 229 NOARGS { int linux_sys_getxattr(void); } 230 NOARGS { int linux_sys_lgetxattr(void); } 231 NOARGS { int linux_sys_fgetxattr(void); } 232 NOARGS { int linux_sys_listxattr(void); } 233 NOARGS { int linux_sys_llistxattr(void); } 234 NOARGS { int linux_sys_flistxattr(void); } 235 NOARGS { int linux_sys_removexattr(void); } 236 NOARGS { int linux_sys_lremovexattr(void); } 237 NOARGS { int linux_sys_fremovexattr(void); } 238 UNIMPL linux_sys_tkill 239 UNIMPL linux_sys_sendfile64 240 STD { int linux_sys_futex(int *uaddr, int op, int val, \ const struct linux_timespec *timeout, \ int *uaddr2, int val3); } 241 UNIMPL linux_sys_sched_setaffinity 242 UNIMPL linux_sys_sched_getaffinity 243 STD { int linux_sys_set_thread_area( \ struct l_segment_descriptor *desc); } 244 STD { int linux_sys_get_thread_area( \ struct l_segment_descriptor *desc); } 245 UNIMPL linux_sys_io_setup 246 UNIMPL linux_sys_io_destroy 247 UNIMPL linux_sys_io_getevents 248 UNIMPL linux_sys_io_submit 249 UNIMPL linux_sys_io_cancel 250 NOARGS { int linux_sys_fadvise64(void); } 251 UNIMPL 252 NOARGS linux_exit_group { int sys_exit(int rval); } 253 UNIMPL linux_sys_lookup_dcookie 254 UNIMPL linux_sys_epoll_create 255 UNIMPL linux_sys_epoll_ctl 256 UNIMPL linux_sys_epoll_wait 257 UNIMPL linux_sys_remap_file_pages 258 STD { int linux_sys_set_tid_address(void *tidptr); } 259 UNIMPL linux_sys_timer_create 260 UNIMPL linux_sys_timer_settime 261 UNIMPL linux_sys_timer_gettime 262 UNIMPL linux_sys_timer_getoverrun 263 UNIMPL linux_sys_timer_delete 264 UNIMPL linux_sys_clock_settime 265 STD { int linux_sys_clock_gettime(clockid_t which, \ struct l_timespec *tp); } 266 STD { int linux_sys_clock_getres(clockid_t which, \ struct l_timespec *tp); } 267 UNIMPL linux_sys_clock_nanosleep 268 UNIMPL linux_sys_statfs64 269 UNIMPL linux_sys_fstatfs64 270 UNIMPL linux_sys_tgkill 271 UNIMPL linux_sys_utimes 272 UNIMPL linux_sys_fadvise64_64 273 UNIMPL linux_sys_vserver 274 UNIMPL linux_sys_mbind 275 UNIMPL linux_sys_get_mempolicy 276 UNIMPL linux_sys_set_mempolicy 277 UNIMPL linux_sys_mq_open 278 UNIMPL linux_sys_mq_unlink 279 UNIMPL linux_sys_mq_timedsend 280 UNIMPL linux_sys_mq_timedreceive 281 UNIMPL linux_sys_mq_notify 282 UNIMPL linux_sys_mq_getsetattr 283 UNIMPL linux_sys_sys_kexec_load 284 UNIMPL linux_sys_waitid 285 UNIMPL /* unused */ 286 UNIMPL linux_sys_add_key 287 UNIMPL linux_sys_request_key 288 UNIMPL linux_sys_keyctl 289 UNIMPL linux_sys_ioprio_set 290 UNIMPL linux_sys_ioprio_get 291 UNIMPL linux_sys_inotify_init 292 UNIMPL linux_sys_inotify_add_watch 293 UNIMPL linux_sys_inotify_rm_watch 294 UNIMPL linux_sys_migrate_pages 295 UNIMPL linux_sys_openalinux_sys_t 296 UNIMPL linux_sys_mkdirat 297 UNIMPL linux_sys_mknodat 298 UNIMPL linux_sys_fchownat 299 UNIMPL linux_sys_futimesat 300 UNIMPL linux_sys_fstatat64 301 UNIMPL linux_sys_unlinkat 302 UNIMPL linux_sys_renameat 303 UNIMPL linux_sys_linkat 304 UNIMPL linux_sys_symlinkat 305 UNIMPL linux_sys_readlinkat 306 UNIMPL linux_sys_fchmodat 307 UNIMPL linux_sys_faccessat 308 UNIMPL linux_sys_pselect6 309 UNIMPL linux_sys_ppoll 310 UNIMPL linux_sys_unshare 311 STD { int linux_sys_set_robust_list( \ struct linux_robust_list_head *head, size_t len); } 312 STD { int linux_sys_get_robust_list(int pid, \ struct linux_robust_list_head **head, \ size_t *len); } 313 UNIMPL splice 314 UNIMPL sync_file_range 315 UNIMPL tee 316 UNIMPL vmsplice 317 UNIMPL move_pages 318 UNIMPL getcpu 319 UNIMPL epoll_wait 320 UNIMPL utimensat 321 UNIMPL signalfd 322 UNIMPL timerfd_create 323 UNIMPL eventfd 324 UNIMPL fallocate 325 UNIMPL timerfd_settime 326 UNIMPL timerfd_gettime 327 UNIMPL signalfd4 328 UNIMPL eventfd2 329 UNIMPL epoll_create1 330 UNIMPL dup3 331 STD { int linux_sys_pipe2(int *fdp, int flags); } 332 UNIMPL inotify_init1 333 UNIMPL preadv 334 UNIMPL pwritev 335 UNIMPL rt_tgsigqueueinfo 336 UNIMPL perf_counter_open 337 UNIMPL recvmmsg