linux_syscall.h revision 1.4
11.1Serh/* $NetBSD: linux_syscall.h,v 1.4 1998/10/07 23:08:26 erh Exp $ */ 21.1Serh 31.1Serh/* 41.1Serh * System call numbers. 51.1Serh * 61.1Serh * DO NOT EDIT-- this file is automatically generated. 71.4Serh * created from NetBSD: syscalls.master,v 1.3 1998/10/07 23:07:30 erh Exp 81.1Serh */ 91.1Serh 101.1Serh/* syscall: "syscall" ret: "int" args: */ 111.1Serh#define LINUX_SYS_syscall 0 121.1Serh 131.1Serh/* syscall: "exit" ret: "int" args: "int" */ 141.1Serh#define LINUX_SYS_exit 1 151.1Serh 161.1Serh/* syscall: "fork" ret: "int" args: */ 171.1Serh#define LINUX_SYS_fork 2 181.1Serh 191.1Serh/* syscall: "read" ret: "int" args: "int" "char *" "u_int" */ 201.1Serh#define LINUX_SYS_read 3 211.1Serh 221.1Serh/* syscall: "write" ret: "int" args: "int" "char *" "u_int" */ 231.1Serh#define LINUX_SYS_write 4 241.1Serh 251.1Serh/* syscall: "close" ret: "int" args: "int" */ 261.1Serh#define LINUX_SYS_close 6 271.1Serh 281.1Serh/* syscall: "creat" ret: "int" args: "char *" "int" */ 291.1Serh#define LINUX_SYS_creat 8 301.1Serh 311.1Serh/* syscall: "link" ret: "int" args: "char *" "char *" */ 321.1Serh#define LINUX_SYS_link 9 331.1Serh 341.1Serh/* syscall: "unlink" ret: "int" args: "char *" */ 351.1Serh#define LINUX_SYS_unlink 10 361.1Serh 371.1Serh/* syscall: "chdir" ret: "int" args: "char *" */ 381.1Serh#define LINUX_SYS_chdir 12 391.1Serh 401.1Serh/* syscall: "fchdir" ret: "int" args: "int" */ 411.1Serh#define LINUX_SYS_fchdir 13 421.1Serh 431.1Serh/* syscall: "mknod" ret: "int" args: "char *" "int" "int" */ 441.1Serh#define LINUX_SYS_mknod 14 451.1Serh 461.1Serh/* syscall: "chmod" ret: "int" args: "char *" "int" */ 471.1Serh#define LINUX_SYS_chmod 15 481.1Serh 491.1Serh/* syscall: "chown" ret: "int" args: "char *" "int" "int" */ 501.1Serh#define LINUX_SYS_chown 16 511.1Serh 521.1Serh/* syscall: "brk" ret: "int" args: "char *" */ 531.1Serh#define LINUX_SYS_brk 17 541.1Serh 551.1Serh/* syscall: "lseek" ret: "long" args: "int" "long" "int" */ 561.1Serh#define LINUX_SYS_lseek 19 571.1Serh 581.1Serh/* syscall: "getpid" ret: "pid_t" args: */ 591.1Serh#define LINUX_SYS_getpid 20 601.1Serh 611.1Serh/* syscall: "setuid" ret: "int" args: "uid_t" */ 621.1Serh#define LINUX_SYS_setuid 23 631.1Serh 641.1Serh/* syscall: "getuid" ret: "uid_t" args: */ 651.1Serh#define LINUX_SYS_getuid 24 661.1Serh 671.1Serh/* syscall: "access" ret: "int" args: "char *" "int" */ 681.1Serh#define LINUX_SYS_access 33 691.1Serh 701.1Serh/* syscall: "sync" ret: "int" args: */ 711.1Serh#define LINUX_SYS_sync 36 721.1Serh 731.1Serh/* syscall: "kill" ret: "int" args: "int" "int" */ 741.1Serh#define LINUX_SYS_kill 37 751.1Serh 761.1Serh/* syscall: "setpgid" ret: "int" args: "int" "int" */ 771.1Serh#define LINUX_SYS_setpgid 39 781.1Serh 791.1Serh/* syscall: "dup" ret: "int" args: "u_int" */ 801.1Serh#define LINUX_SYS_dup 41 811.1Serh 821.1Serh/* syscall: "pipe" ret: "int" args: */ 831.1Serh#define LINUX_SYS_pipe 42 841.1Serh 851.1Serh/* syscall: "open" ret: "int" args: "char *" "int" "int" */ 861.1Serh#define LINUX_SYS_open 45 871.1Serh 881.1Serh/* syscall: "getgid" ret: "gid_t" args: */ 891.1Serh#define LINUX_SYS_getgid 47 901.1Serh 911.1Serh/* syscall: "acct" ret: "int" args: "char *" */ 921.1Serh#define LINUX_SYS_acct 51 931.1Serh 941.1Serh/* syscall: "sigpending" ret: "int" args: "linux_old_sigset_t *" */ 951.1Serh#define LINUX_SYS_sigpending 52 961.1Serh 971.1Serh/* syscall: "ioctl" ret: "int" args: "int" "u_long" "caddr_t" */ 981.1Serh#define LINUX_SYS_ioctl 54 991.1Serh 1001.1Serh/* syscall: "symlink" ret: "int" args: "char *" "char *" */ 1011.1Serh#define LINUX_SYS_symlink 57 1021.1Serh 1031.1Serh/* syscall: "readlink" ret: "int" args: "char *" "char *" "int" */ 1041.1Serh#define LINUX_SYS_readlink 58 1051.1Serh 1061.1Serh/* syscall: "execve" ret: "int" args: "char *" "char **" "char **" */ 1071.1Serh#define LINUX_SYS_execve 59 1081.1Serh 1091.1Serh/* syscall: "umask" ret: "int" args: "int" */ 1101.1Serh#define LINUX_SYS_umask 60 1111.1Serh 1121.1Serh/* syscall: "chroot" ret: "int" args: "char *" */ 1131.1Serh#define LINUX_SYS_chroot 61 1141.1Serh 1151.1Serh/* syscall: "getpgrp" ret: "int" args: */ 1161.1Serh#define LINUX_SYS_getpgrp 63 1171.1Serh 1181.1Serh/* syscall: "getpagesize" ret: "int" args: */ 1191.1Serh#define LINUX_SYS_getpagesize 64 1201.1Serh 1211.1Serh/* syscall: "stat" ret: "int" args: "char *" "struct linux_stat *" */ 1221.1Serh#define LINUX_SYS_stat 67 1231.1Serh 1241.1Serh/* syscall: "lstat" ret: "int" args: "char *" "struct linux_stat *" */ 1251.1Serh#define LINUX_SYS_lstat 68 1261.1Serh 1271.1Serh/* syscall: "mmap" ret: "int" args: "unsigned long" "size_t" "int" "int" "int" "off_t" */ 1281.1Serh#define LINUX_SYS_mmap 71 1291.1Serh 1301.1Serh/* syscall: "munmap" ret: "int" args: "caddr_t" "int" */ 1311.1Serh#define LINUX_SYS_munmap 73 1321.1Serh 1331.1Serh/* syscall: "mprotect" ret: "int" args: "caddr_t" "int" "int" */ 1341.1Serh#define LINUX_SYS_mprotect 74 1351.1Serh 1361.1Serh/* syscall: "getgroups" ret: "int" args: "u_int" "gid_t *" */ 1371.1Serh#define LINUX_SYS_getgroups 79 1381.1Serh 1391.1Serh/* syscall: "setgroups" ret: "int" args: "u_int" "gid_t *" */ 1401.1Serh#define LINUX_SYS_setgroups 80 1411.1Serh 1421.1Serh/* syscall: "gethostname" ret: "int" args: "char *" "u_int" */ 1431.1Serh#define LINUX_SYS_gethostname 87 1441.1Serh 1451.1Serh/* syscall: "sethostname" ret: "int" args: "char *" "u_int" */ 1461.1Serh#define LINUX_SYS_sethostname 88 1471.1Serh 1481.1Serh/* syscall: "dup2" ret: "int" args: "u_int" "u_int" */ 1491.1Serh#define LINUX_SYS_dup2 90 1501.1Serh 1511.1Serh/* syscall: "fstat" ret: "int" args: "int" "struct linux_stat *" */ 1521.1Serh#define LINUX_SYS_fstat 91 1531.1Serh 1541.1Serh/* syscall: "fcntl" ret: "int" args: "int" "int" "void *" */ 1551.1Serh#define LINUX_SYS_fcntl 92 1561.1Serh 1571.1Serh/* syscall: "fsync" ret: "int" args: "int" */ 1581.1Serh#define LINUX_SYS_fsync 95 1591.1Serh 1601.1Serh/* syscall: "setpriority" ret: "int" args: "int" "int" "int" */ 1611.1Serh#define LINUX_SYS_setpriority 96 1621.1Serh 1631.1Serh/* syscall: "socket" ret: "int" args: "int" "int" "int" */ 1641.1Serh#define LINUX_SYS_socket 97 1651.1Serh 1661.1Serh/* syscall: "connect" ret: "int" args: "int" "const struct sockaddr *" "int" */ 1671.1Serh#define LINUX_SYS_connect 98 1681.1Serh 1691.1Serh/* syscall: "accept" ret: "int" args: "int" "caddr_t" "int *" */ 1701.1Serh#define LINUX_SYS_accept 99 1711.1Serh 1721.1Serh/* syscall: "getpriority" ret: "int" args: "int" "int" */ 1731.1Serh#define LINUX_SYS_getpriority 100 1741.1Serh 1751.1Serh/* syscall: "send" ret: "int" args: "int" "caddr_t" "int" "int" */ 1761.1Serh#define LINUX_SYS_send 101 1771.1Serh 1781.1Serh/* syscall: "recv" ret: "int" args: "int" "caddr_t" "int" "int" */ 1791.1Serh#define LINUX_SYS_recv 102 1801.1Serh 1811.1Serh/* syscall: "sigreturn" ret: "int" args: "struct linux_sigframe *" */ 1821.1Serh#define LINUX_SYS_sigreturn 103 1831.1Serh 1841.1Serh/* syscall: "bind" ret: "int" args: "int" "const struct sockaddr *" "int" */ 1851.1Serh#define LINUX_SYS_bind 104 1861.1Serh 1871.1Serh/* syscall: "setsockopt" ret: "int" args: "int" "int" "int" "void *" "int" */ 1881.1Serh#define LINUX_SYS_setsockopt 105 1891.1Serh 1901.1Serh/* syscall: "listen" ret: "int" args: "int" "int" */ 1911.1Serh#define LINUX_SYS_listen 106 1921.1Serh 1931.1Serh/* syscall: "sigsuspend" ret: "int" args: "caddr_t" "int" "int" */ 1941.1Serh#define LINUX_SYS_sigsuspend 111 1951.1Serh 1961.1Serh/* syscall: "recvmsg" ret: "int" args: "int" "struct msghdr *" "u_int" */ 1971.1Serh#define LINUX_SYS_recvmsg 113 1981.1Serh 1991.1Serh/* syscall: "sendmsg" ret: "int" args: "int" "struct msghdr *" "u_int" */ 2001.1Serh#define LINUX_SYS_sendmsg 114 2011.1Serh 2021.1Serh/* syscall: "getsockopt" ret: "int" args: "int" "int" "int" "void *" "int *" */ 2031.1Serh#define LINUX_SYS_getsockopt 118 2041.1Serh 2051.1Serh/* syscall: "readv" ret: "int" args: "int" "struct iovec *" "u_int" */ 2061.1Serh#define LINUX_SYS_readv 120 2071.1Serh 2081.1Serh/* syscall: "writev" ret: "int" args: "int" "struct iovec *" "u_int" */ 2091.1Serh#define LINUX_SYS_writev 121 2101.1Serh 2111.1Serh/* syscall: "fchown" ret: "int" args: "int" "int" "int" */ 2121.1Serh#define LINUX_SYS_fchown 123 2131.1Serh 2141.1Serh/* syscall: "fchmod" ret: "int" args: "int" "int" */ 2151.1Serh#define LINUX_SYS_fchmod 124 2161.1Serh 2171.1Serh/* syscall: "recvfrom" ret: "int" args: "int" "void *" "int" "int" "struct sockaddr *" "int *" */ 2181.1Serh#define LINUX_SYS_recvfrom 125 2191.1Serh 2201.1Serh/* syscall: "setreuid" ret: "int" args: "int" "int" */ 2211.1Serh#define LINUX_SYS_setreuid 126 2221.1Serh 2231.1Serh/* syscall: "setregid" ret: "int" args: "int" "int" */ 2241.1Serh#define LINUX_SYS_setregid 127 2251.1Serh 2261.1Serh/* syscall: "rename" ret: "int" args: "char *" "char *" */ 2271.1Serh#define LINUX_SYS_rename 128 2281.1Serh 2291.1Serh/* syscall: "truncate" ret: "int" args: "char *" "long" */ 2301.1Serh#define LINUX_SYS_truncate 129 2311.1Serh 2321.1Serh/* syscall: "ftruncate" ret: "int" args: "int" "long" */ 2331.1Serh#define LINUX_SYS_ftruncate 130 2341.1Serh 2351.1Serh/* syscall: "flock" ret: "int" args: "int" "int" */ 2361.1Serh#define LINUX_SYS_flock 131 2371.1Serh 2381.1Serh/* syscall: "setgid" ret: "int" args: "gid_t" */ 2391.1Serh#define LINUX_SYS_setgid 132 2401.1Serh 2411.1Serh/* syscall: "sendto" ret: "int" args: "int" "void *" "int" "int" "struct sockaddr *" "int" */ 2421.1Serh#define LINUX_SYS_sendto 133 2431.1Serh 2441.1Serh/* syscall: "shutdown" ret: "int" args: "int" "int" */ 2451.1Serh#define LINUX_SYS_shutdown 134 2461.1Serh 2471.1Serh/* syscall: "socketpair" ret: "int" args: "int" "int" "int" "int *" */ 2481.1Serh#define LINUX_SYS_socketpair 135 2491.1Serh 2501.1Serh/* syscall: "mkdir" ret: "int" args: "char *" "int" */ 2511.1Serh#define LINUX_SYS_mkdir 136 2521.1Serh 2531.1Serh/* syscall: "rmdir" ret: "int" args: "char *" */ 2541.1Serh#define LINUX_SYS_rmdir 137 2551.1Serh 2561.1Serh/* syscall: "getpeername" ret: "int" args: "int" "caddr_t" "int *" */ 2571.1Serh#define LINUX_SYS_getpeername 141 2581.1Serh 2591.1Serh/* syscall: "getrlimit" ret: "int" args: "u_int" "struct orlimit *" */ 2601.1Serh#define LINUX_SYS_getrlimit 144 2611.1Serh 2621.1Serh/* syscall: "setrlimit" ret: "int" args: "u_int" "struct orlimit *" */ 2631.1Serh#define LINUX_SYS_setrlimit 145 2641.1Serh 2651.1Serh/* syscall: "setsid" ret: "int" args: */ 2661.1Serh#define LINUX_SYS_setsid 147 2671.1Serh 2681.1Serh/* syscall: "getsockname" ret: "int" args: "int" "caddr_t" "int *" */ 2691.1Serh#define LINUX_SYS_getsockname 150 2701.1Serh 2711.1Serh/* syscall: "sigaction" ret: "int" args: "int" "const struct linux_old_sigaction *" "struct linux_old_sigaction *" */ 2721.1Serh#define LINUX_SYS_sigaction 156 2731.1Serh 2741.1Serh/* syscall: "msgctl" ret: "int" args: "int" "int" "struct linux_msqid_ds *" */ 2751.1Serh#define LINUX_SYS_msgctl 200 2761.1Serh 2771.1Serh/* syscall: "msgget" ret: "int" args: "key_t" "int" */ 2781.1Serh#define LINUX_SYS_msgget 201 2791.1Serh 2801.1Serh/* syscall: "msgrcv" ret: "int" args: "int" "void *" "size_t" "int" */ 2811.1Serh#define LINUX_SYS_msgrcv 202 2821.1Serh 2831.1Serh/* syscall: "msgsnd" ret: "int" args: "int" "void *" "size_t" "int" */ 2841.1Serh#define LINUX_SYS_msgsnd 203 2851.1Serh 2861.1Serh/* syscall: "semctl" ret: "int" args: "int" "int" "int" "union linux_semun" */ 2871.1Serh#define LINUX_SYS_semctl 204 2881.1Serh 2891.1Serh/* syscall: "semget" ret: "int" args: "key_t" "int" "int" */ 2901.1Serh#define LINUX_SYS_semget 205 2911.1Serh 2921.1Serh/* syscall: "semop" ret: "int" args: "int" "struct sembuf *" "unsigned u_int" */ 2931.1Serh#define LINUX_SYS_semop 206 2941.1Serh 2951.1Serh/* syscall: "olduname" ret: "int" args: "struct linux_old_utsname *" */ 2961.1Serh#define LINUX_SYS_olduname 207 2971.1Serh 2981.1Serh/* syscall: "lchown" ret: "int" args: "char *" "int" "int" */ 2991.1Serh#define LINUX_SYS_lchown 208 3001.1Serh 3011.1Serh/* syscall: "shmat" ret: "int" args: "int" "void *" "int" "u_long *" */ 3021.1Serh#define LINUX_SYS_shmat 209 3031.1Serh 3041.1Serh/* syscall: "shmctl" ret: "int" args: "int" "int" "struct linux_shmid_ds *" */ 3051.1Serh#define LINUX_SYS_shmctl 210 3061.1Serh 3071.1Serh/* syscall: "shmdt" ret: "int" args: "void *" */ 3081.1Serh#define LINUX_SYS_shmdt 211 3091.1Serh 3101.1Serh/* syscall: "shmget" ret: "int" args: "key_t" "int" "int" */ 3111.1Serh#define LINUX_SYS_shmget 212 3121.1Serh 3131.1Serh/* syscall: "msync" ret: "int" args: "caddr_t" "int" "int" */ 3141.1Serh#define LINUX_SYS_msync 217 3151.1Serh 3161.1Serh/* syscall: "getpgid" ret: "int" args: "int" */ 3171.1Serh#define LINUX_SYS_getpgid 233 3181.1Serh 3191.1Serh/* syscall: "getsid" ret: "pid_t" args: "pid_t" */ 3201.1Serh#define LINUX_SYS_getsid 234 3211.1Serh 3221.1Serh/* syscall: "fdatasync" ret: "int" args: "int" */ 3231.1Serh#define LINUX_SYS_fdatasync 261 3241.1Serh 3251.1Serh/* syscall: "getdents" ret: "int" args: "int" "struct linux_dirent *" "unsigned int" */ 3261.1Serh#define LINUX_SYS_getdents 305 3271.1Serh 3281.1Serh/* syscall: "reboot" ret: "int" args: "int" */ 3291.1Serh#define LINUX_SYS_reboot 311 3301.1Serh 3311.1Serh/* syscall: "uselib" ret: "int" args: "char *" */ 3321.1Serh#define LINUX_SYS_uselib 313 3331.1Serh 3341.1Serh/* syscall: "mlock" ret: "int" args: "const void *" "size_t" */ 3351.1Serh#define LINUX_SYS_mlock 314 3361.1Serh 3371.1Serh/* syscall: "munlock" ret: "int" args: "const void *" "size_t" */ 3381.1Serh#define LINUX_SYS_munlock 315 3391.1Serh 3401.1Serh/* syscall: "__sysctl" ret: "int" args: "struct linux___sysctl *" */ 3411.1Serh#define LINUX_SYS___sysctl 319 3421.1Serh 3431.1Serh/* syscall: "swapon" ret: "int" args: "char *" */ 3441.1Serh#define LINUX_SYS_swapon 322 3451.1Serh 3461.1Serh/* syscall: "times" ret: "int" args: "struct times *" */ 3471.1Serh#define LINUX_SYS_times 323 3481.1Serh 3491.1Serh/* syscall: "personality" ret: "int" args: "int" */ 3501.1Serh#define LINUX_SYS_personality 324 3511.1Serh 3521.1Serh/* syscall: "statfs" ret: "int" args: "char *" "struct linux_statfs *" */ 3531.1Serh#define LINUX_SYS_statfs 328 3541.1Serh 3551.1Serh/* syscall: "fstatfs" ret: "int" args: "int" "struct linux_statfs *" */ 3561.1Serh#define LINUX_SYS_fstatfs 329 3571.1Serh 3581.1Serh/* syscall: "uname" ret: "int" args: "struct linux_utsname *" */ 3591.1Serh#define LINUX_SYS_uname 339 3601.1Serh 3611.1Serh/* syscall: "nanosleep" ret: "int" args: "const struct timespec *" "struct timespec *" */ 3621.1Serh#define LINUX_SYS_nanosleep 340 3631.1Serh 3641.1Serh/* syscall: "mremap" ret: "void *" args: "void *" "size_t" "size_t" "u_long" */ 3651.1Serh#define LINUX_SYS_mremap 341 3661.1Serh 3671.1Serh/* syscall: "rt_sigreturn" ret: "int" args: "struct linux_rt_sigframe *" */ 3681.1Serh#define LINUX_SYS_rt_sigreturn 351 3691.1Serh 3701.1Serh/* syscall: "rt_sigaction" ret: "int" args: "int" "const struct linux_sigaction *" "struct linux_sigaction *" "size_t" */ 3711.1Serh#define LINUX_SYS_rt_sigaction 352 3721.1Serh 3731.1Serh/* syscall: "rt_sigprocmask" ret: "int" args: "int" "const linux_sigset_t *" "linux_sigset_t *" "size_t" */ 3741.1Serh#define LINUX_SYS_rt_sigprocmask 353 3751.1Serh 3761.1Serh/* syscall: "rt_sigpending" ret: "int" args: "linux_sigset_t *" "size_t" */ 3771.1Serh#define LINUX_SYS_rt_sigpending 354 3781.1Serh 3791.4Serh/* syscall: "rt_queueinfo" ret: "int" args: "int" "int" "linux_siginfo_t *" */ 3801.1Serh#define LINUX_SYS_rt_queueinfo 356 3811.1Serh 3821.1Serh/* syscall: "rt_sigsuspend" ret: "int" args: "linux_sigset_t *" "size_t" */ 3831.1Serh#define LINUX_SYS_rt_sigsuspend 357 3841.1Serh 3851.1Serh/* syscall: "select" ret: "int" args: "int" "fd_set *" "fd_set *" "fd_set *" "struct timeval *" */ 3861.1Serh#define LINUX_SYS_select 358 3871.1Serh 3881.1Serh/* syscall: "gettimeofday" ret: "int" args: "struct timeval *" "struct timezone *" */ 3891.1Serh#define LINUX_SYS_gettimeofday 359 3901.1Serh 3911.1Serh/* syscall: "settimeofday" ret: "int" args: "struct timeval *" "struct timezone *" */ 3921.1Serh#define LINUX_SYS_settimeofday 360 3931.1Serh 3941.1Serh/* syscall: "getitimer" ret: "int" args: "u_int" "struct itimerval *" */ 3951.1Serh#define LINUX_SYS_getitimer 361 3961.1Serh 3971.1Serh/* syscall: "setitimer" ret: "int" args: "u_int" "struct itimerval *" "struct itimerval *" */ 3981.1Serh#define LINUX_SYS_setitimer 362 3991.1Serh 4001.1Serh/* syscall: "utimes" ret: "int" args: "char *" "struct timecal *" */ 4011.1Serh#define LINUX_SYS_utimes 363 4021.1Serh 4031.1Serh/* syscall: "getrusage" ret: "int" args: "int" "struct rusage *" */ 4041.1Serh#define LINUX_SYS_getrusage 364 4051.1Serh 4061.1Serh/* syscall: "wait4" ret: "int" args: "int" "int *" "int" "struct rusage *" */ 4071.1Serh#define LINUX_SYS_wait4 365 4081.1Serh 4091.1Serh#define LINUX_SYS_MAXSYSCALL 367 410