linux_syscalls.c revision 1.67 1 1.60 njoly /* $NetBSD: linux_syscalls.c,v 1.67 2008/06/18 12:23:06 tsutsui Exp $ */
2 1.1 itohy
3 1.1 itohy /*
4 1.1 itohy * System call names.
5 1.1 itohy *
6 1.1 itohy * DO NOT EDIT-- this file is automatically generated.
7 1.67 tsutsui * created from NetBSD: syscalls.master,v 1.62 2008/06/18 12:21:20 tsutsui Exp
8 1.1 itohy */
9 1.38 lukem
10 1.38 lukem #include <sys/cdefs.h>
11 1.60 njoly __KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.67 2008/06/18 12:23:06 tsutsui Exp $");
12 1.1 itohy
13 1.37 mrg #if defined(_KERNEL_OPT)
14 1.37 mrg #if defined(_KERNEL_OPT)
15 1.1 itohy #include "opt_compat_netbsd.h"
16 1.1 itohy #include "opt_compat_43.h"
17 1.22 mycroft #endif
18 1.1 itohy #include <sys/param.h>
19 1.5 tron #include <sys/poll.h>
20 1.1 itohy #include <sys/systm.h>
21 1.1 itohy #include <sys/signal.h>
22 1.1 itohy #include <sys/mount.h>
23 1.67 tsutsui #include <sys/sched.h>
24 1.1 itohy #include <sys/syscallargs.h>
25 1.1 itohy #include <compat/linux/common/linux_types.h>
26 1.1 itohy #include <compat/linux/common/linux_signal.h>
27 1.1 itohy #include <compat/linux/common/linux_siginfo.h>
28 1.1 itohy #include <compat/linux/common/linux_machdep.h>
29 1.47 thorpej #include <compat/linux/common/linux_mmap.h>
30 1.1 itohy #include <compat/linux/linux_syscallargs.h>
31 1.37 mrg #endif /* _KERNEL_OPT */
32 1.1 itohy
33 1.22 mycroft const char *const linux_syscallnames[] = {
34 1.60 njoly /* 0 */ "syscall",
35 1.60 njoly /* 1 */ "exit",
36 1.60 njoly /* 2 */ "fork",
37 1.60 njoly /* 3 */ "read",
38 1.60 njoly /* 4 */ "write",
39 1.60 njoly /* 5 */ "open",
40 1.60 njoly /* 6 */ "close",
41 1.60 njoly /* 7 */ "waitpid",
42 1.60 njoly /* 8 */ "creat",
43 1.60 njoly /* 9 */ "link",
44 1.60 njoly /* 10 */ "unlink",
45 1.60 njoly /* 11 */ "execve",
46 1.60 njoly /* 12 */ "chdir",
47 1.60 njoly /* 13 */ "time",
48 1.60 njoly /* 14 */ "mknod",
49 1.60 njoly /* 15 */ "chmod",
50 1.60 njoly /* 16 */ "chown16",
51 1.60 njoly /* 17 */ "#17 (obsolete break)",
52 1.60 njoly /* 18 */ "#18 (obsolete ostat)",
53 1.1 itohy #if !defined(_KERNEL) || defined(COMPAT_43)
54 1.60 njoly /* 19 */ "lseek",
55 1.1 itohy #else
56 1.60 njoly /* 19 */ "#19 (unimplemented compat_43_sys_lseek)",
57 1.1 itohy #endif
58 1.60 njoly /* 20 */ "getpid",
59 1.60 njoly /* 21 */ "#21 (unimplemented mount)",
60 1.60 njoly /* 22 */ "#22 (obsolete umount)",
61 1.60 njoly /* 23 */ "linux_setuid16",
62 1.60 njoly /* 24 */ "linux_getuid16",
63 1.60 njoly /* 25 */ "stime",
64 1.60 njoly /* 26 */ "ptrace",
65 1.60 njoly /* 27 */ "alarm",
66 1.60 njoly /* 28 */ "#28 (obsolete ofstat)",
67 1.60 njoly /* 29 */ "pause",
68 1.60 njoly /* 30 */ "utime",
69 1.60 njoly /* 31 */ "#31 (obsolete stty)",
70 1.60 njoly /* 32 */ "#32 (obsolete gtty)",
71 1.60 njoly /* 33 */ "access",
72 1.60 njoly /* 34 */ "nice",
73 1.60 njoly /* 35 */ "#35 (obsolete ftime)",
74 1.60 njoly /* 36 */ "sync",
75 1.60 njoly /* 37 */ "kill",
76 1.60 njoly /* 38 */ "__posix_rename",
77 1.60 njoly /* 39 */ "mkdir",
78 1.60 njoly /* 40 */ "rmdir",
79 1.60 njoly /* 41 */ "dup",
80 1.60 njoly /* 42 */ "pipe",
81 1.60 njoly /* 43 */ "times",
82 1.60 njoly /* 44 */ "#44 (obsolete prof)",
83 1.60 njoly /* 45 */ "brk",
84 1.60 njoly /* 46 */ "linux_setgid16",
85 1.60 njoly /* 47 */ "linux_getgid16",
86 1.60 njoly /* 48 */ "signal",
87 1.60 njoly /* 49 */ "linux_geteuid16",
88 1.60 njoly /* 50 */ "linux_getegid16",
89 1.60 njoly /* 51 */ "acct",
90 1.60 njoly /* 52 */ "#52 (unimplemented umount)",
91 1.60 njoly /* 53 */ "#53 (obsolete lock)",
92 1.60 njoly /* 54 */ "ioctl",
93 1.60 njoly /* 55 */ "fcntl",
94 1.60 njoly /* 56 */ "#56 (obsolete mpx)",
95 1.60 njoly /* 57 */ "setpgid",
96 1.60 njoly /* 58 */ "#58 (obsolete ulimit)",
97 1.60 njoly /* 59 */ "#59 (unimplemented oldolduname)",
98 1.60 njoly /* 60 */ "umask",
99 1.60 njoly /* 61 */ "chroot",
100 1.60 njoly /* 62 */ "#62 (unimplemented ustat)",
101 1.60 njoly /* 63 */ "dup2",
102 1.60 njoly /* 64 */ "getppid",
103 1.60 njoly /* 65 */ "getpgrp",
104 1.60 njoly /* 66 */ "setsid",
105 1.60 njoly /* 67 */ "sigaction",
106 1.60 njoly /* 68 */ "siggetmask",
107 1.60 njoly /* 69 */ "sigsetmask",
108 1.60 njoly /* 70 */ "setreuid16",
109 1.60 njoly /* 71 */ "setregid16",
110 1.60 njoly /* 72 */ "sigsuspend",
111 1.60 njoly /* 73 */ "sigpending",
112 1.1 itohy #if !defined(_KERNEL) || defined(COMPAT_43)
113 1.60 njoly /* 74 */ "sethostname",
114 1.1 itohy #else
115 1.60 njoly /* 74 */ "#74 (unimplemented compat_43_sys_sethostname)",
116 1.1 itohy #endif
117 1.60 njoly /* 75 */ "setrlimit",
118 1.60 njoly /* 76 */ "getrlimit",
119 1.60 njoly /* 77 */ "getrusage",
120 1.60 njoly /* 78 */ "gettimeofday",
121 1.60 njoly /* 79 */ "settimeofday",
122 1.60 njoly /* 80 */ "getgroups16",
123 1.60 njoly /* 81 */ "setgroups16",
124 1.60 njoly /* 82 */ "oldselect",
125 1.60 njoly /* 83 */ "symlink",
126 1.1 itohy #if !defined(_KERNEL) || defined(COMPAT_43)
127 1.60 njoly /* 84 */ "oolstat",
128 1.1 itohy #else
129 1.60 njoly /* 84 */ "#84 (unimplemented compat_43_sys_lstat)",
130 1.1 itohy #endif
131 1.60 njoly /* 85 */ "readlink",
132 1.53 joerg #ifdef EXEC_AOUT
133 1.60 njoly /* 86 */ "uselib",
134 1.53 joerg #else
135 1.60 njoly /* 86 */ "#86 (unimplemented sys_uselib)",
136 1.53 joerg #endif
137 1.60 njoly /* 87 */ "swapon",
138 1.60 njoly /* 88 */ "reboot",
139 1.60 njoly /* 89 */ "readdir",
140 1.60 njoly /* 90 */ "old_mmap",
141 1.60 njoly /* 91 */ "munmap",
142 1.60 njoly /* 92 */ "truncate",
143 1.1 itohy #if !defined(_KERNEL) || defined(COMPAT_43)
144 1.60 njoly /* 93 */ "ftruncate",
145 1.1 itohy #else
146 1.60 njoly /* 93 */ "#93 (unimplemented compat_43_sys_ftruncate)",
147 1.1 itohy #endif
148 1.60 njoly /* 94 */ "fchmod",
149 1.60 njoly /* 95 */ "fchown16",
150 1.60 njoly /* 96 */ "getpriority",
151 1.60 njoly /* 97 */ "setpriority",
152 1.60 njoly /* 98 */ "profil",
153 1.60 njoly /* 99 */ "statfs",
154 1.60 njoly /* 100 */ "fstatfs",
155 1.60 njoly /* 101 */ "#101 (unimplemented ioperm)",
156 1.60 njoly /* 102 */ "socketcall",
157 1.60 njoly /* 103 */ "#103 (unimplemented syslog)",
158 1.60 njoly /* 104 */ "setitimer",
159 1.60 njoly /* 105 */ "getitimer",
160 1.60 njoly /* 106 */ "stat",
161 1.60 njoly /* 107 */ "lstat",
162 1.60 njoly /* 108 */ "fstat",
163 1.60 njoly /* 109 */ "#109 (unimplemented olduname)",
164 1.60 njoly /* 110 */ "#110 (unimplemented iopl)",
165 1.60 njoly /* 111 */ "#111 (unimplemented vhangup)",
166 1.60 njoly /* 112 */ "#112 (unimplemented idle)",
167 1.60 njoly /* 113 */ "#113 (unimplemented vm86old)",
168 1.60 njoly /* 114 */ "wait4",
169 1.60 njoly /* 115 */ "swapoff",
170 1.60 njoly /* 116 */ "sysinfo",
171 1.60 njoly /* 117 */ "ipc",
172 1.60 njoly /* 118 */ "fsync",
173 1.60 njoly /* 119 */ "sigreturn",
174 1.60 njoly /* 120 */ "clone",
175 1.60 njoly /* 121 */ "setdomainname",
176 1.60 njoly /* 122 */ "uname",
177 1.60 njoly /* 123 */ "cacheflush",
178 1.60 njoly /* 124 */ "#124 (unimplemented adjtimex)",
179 1.60 njoly /* 125 */ "mprotect",
180 1.60 njoly /* 126 */ "sigprocmask",
181 1.60 njoly /* 127 */ "#127 (unimplemented create_module)",
182 1.60 njoly /* 128 */ "#128 (unimplemented init_module)",
183 1.60 njoly /* 129 */ "#129 (unimplemented delete_module)",
184 1.60 njoly /* 130 */ "#130 (unimplemented get_kernel_syms)",
185 1.60 njoly /* 131 */ "#131 (unimplemented quotactl)",
186 1.60 njoly /* 132 */ "getpgid",
187 1.60 njoly /* 133 */ "fchdir",
188 1.60 njoly /* 134 */ "#134 (unimplemented bdflush)",
189 1.60 njoly /* 135 */ "#135 (unimplemented sysfs)",
190 1.60 njoly /* 136 */ "personality",
191 1.60 njoly /* 137 */ "#137 (unimplemented afs_syscall)",
192 1.60 njoly /* 138 */ "linux_setfsuid16",
193 1.62 njoly /* 139 */ "linux_setfsgid16",
194 1.60 njoly /* 140 */ "llseek",
195 1.60 njoly /* 141 */ "getdents",
196 1.60 njoly /* 142 */ "select",
197 1.60 njoly /* 143 */ "flock",
198 1.65 njoly /* 144 */ "__msync13",
199 1.60 njoly /* 145 */ "readv",
200 1.60 njoly /* 146 */ "writev",
201 1.60 njoly /* 147 */ "getsid",
202 1.60 njoly /* 148 */ "fdatasync",
203 1.60 njoly /* 149 */ "__sysctl",
204 1.60 njoly /* 150 */ "mlock",
205 1.60 njoly /* 151 */ "munlock",
206 1.60 njoly /* 152 */ "mlockall",
207 1.60 njoly /* 153 */ "munlockall",
208 1.60 njoly /* 154 */ "sched_setparam",
209 1.60 njoly /* 155 */ "sched_getparam",
210 1.60 njoly /* 156 */ "sched_setscheduler",
211 1.60 njoly /* 157 */ "sched_getscheduler",
212 1.60 njoly /* 158 */ "sched_yield",
213 1.60 njoly /* 159 */ "sched_get_priority_max",
214 1.60 njoly /* 160 */ "sched_get_priority_min",
215 1.60 njoly /* 161 */ "#161 (unimplemented sched_rr_get_interval)",
216 1.60 njoly /* 162 */ "nanosleep",
217 1.60 njoly /* 163 */ "mremap",
218 1.60 njoly /* 164 */ "setresuid16",
219 1.64 njoly /* 165 */ "getresuid16",
220 1.60 njoly /* 166 */ "#166 (unimplemented vm86)",
221 1.60 njoly /* 167 */ "#167 (unimplemented query_module)",
222 1.60 njoly /* 168 */ "poll",
223 1.60 njoly /* 169 */ "#169 (unimplemented nfsservctl)",
224 1.60 njoly /* 170 */ "setresgid16",
225 1.64 njoly /* 171 */ "getresgid16",
226 1.60 njoly /* 172 */ "#172 (unimplemented prctl)",
227 1.60 njoly /* 173 */ "rt_sigreturn",
228 1.60 njoly /* 174 */ "rt_sigaction",
229 1.60 njoly /* 175 */ "rt_sigprocmask",
230 1.60 njoly /* 176 */ "rt_sigpending",
231 1.60 njoly /* 177 */ "#177 (unimplemented rt_sigtimedwait)",
232 1.60 njoly /* 178 */ "rt_queueinfo",
233 1.60 njoly /* 179 */ "rt_sigsuspend",
234 1.60 njoly /* 180 */ "pread",
235 1.60 njoly /* 181 */ "pwrite",
236 1.60 njoly /* 182 */ "lchown16",
237 1.60 njoly /* 183 */ "__getcwd",
238 1.60 njoly /* 184 */ "#184 (unimplemented capget)",
239 1.60 njoly /* 185 */ "#185 (unimplemented capset)",
240 1.60 njoly /* 186 */ "sigaltstack",
241 1.60 njoly /* 187 */ "#187 (unimplemented sendfile)",
242 1.60 njoly /* 188 */ "#188 (unimplemented getpmsg)",
243 1.60 njoly /* 189 */ "#189 (unimplemented putpmsg)",
244 1.60 njoly /* 190 */ "__vfork14",
245 1.60 njoly /* 191 */ "ugetrlimit",
246 1.61 dsl #define linux_sys_mmap2_args linux_sys_mmap_args
247 1.60 njoly /* 192 */ "mmap2",
248 1.60 njoly /* 193 */ "truncate64",
249 1.60 njoly /* 194 */ "ftruncate64",
250 1.60 njoly /* 195 */ "stat64",
251 1.60 njoly /* 196 */ "lstat64",
252 1.60 njoly /* 197 */ "fstat64",
253 1.60 njoly /* 198 */ "__posix_chown",
254 1.60 njoly /* 199 */ "getuid",
255 1.60 njoly /* 200 */ "getgid",
256 1.60 njoly /* 201 */ "geteuid",
257 1.60 njoly /* 202 */ "getegid",
258 1.60 njoly /* 203 */ "setreuid",
259 1.60 njoly /* 204 */ "setregid",
260 1.60 njoly /* 205 */ "getgroups",
261 1.60 njoly /* 206 */ "setgroups",
262 1.60 njoly /* 207 */ "__posix_fchown",
263 1.60 njoly /* 208 */ "setresuid",
264 1.60 njoly /* 209 */ "getresuid",
265 1.60 njoly /* 210 */ "setresgid",
266 1.60 njoly /* 211 */ "getresgid",
267 1.60 njoly /* 212 */ "__posix_lchown",
268 1.60 njoly /* 213 */ "setuid",
269 1.60 njoly /* 214 */ "setgid",
270 1.60 njoly /* 215 */ "setfsuid",
271 1.62 njoly /* 216 */ "setfsgid",
272 1.60 njoly /* 217 */ "#217 (unimplemented / * unused * /)",
273 1.60 njoly /* 218 */ "#218 (unimplemented / * unused * /)",
274 1.60 njoly /* 219 */ "#219 (unimplemented / * unused * /)",
275 1.60 njoly /* 220 */ "getdents64",
276 1.60 njoly /* 221 */ "#221 (unimplemented gettid)",
277 1.60 njoly /* 222 */ "#222 (unimplemented tkill)",
278 1.60 njoly /* 223 */ "setxattr",
279 1.60 njoly /* 224 */ "lsetxattr",
280 1.60 njoly /* 225 */ "fsetxattr",
281 1.60 njoly /* 226 */ "getxattr",
282 1.60 njoly /* 227 */ "lgetxattr",
283 1.60 njoly /* 228 */ "fgetxattr",
284 1.60 njoly /* 229 */ "listxattr",
285 1.60 njoly /* 230 */ "llistxattr",
286 1.60 njoly /* 231 */ "flistxattr",
287 1.60 njoly /* 232 */ "removexattr",
288 1.60 njoly /* 233 */ "lremovexattr",
289 1.60 njoly /* 234 */ "fremovexattr",
290 1.60 njoly /* 235 */ "#235 (unimplemented futex)",
291 1.60 njoly /* 236 */ "#236 (unimplemented sendfile64)",
292 1.60 njoly /* 237 */ "#237 (unimplemented mincore)",
293 1.60 njoly /* 238 */ "#238 (unimplemented madvise)",
294 1.60 njoly /* 239 */ "#239 (unimplemented fcntl64)",
295 1.60 njoly /* 240 */ "#240 (unimplemented readahead)",
296 1.60 njoly /* 241 */ "#241 (unimplemented io_setup)",
297 1.60 njoly /* 242 */ "#242 (unimplemented io_destroy)",
298 1.60 njoly /* 243 */ "#243 (unimplemented io_getevents)",
299 1.60 njoly /* 244 */ "#244 (unimplemented io_submit)",
300 1.60 njoly /* 245 */ "#245 (unimplemented io_cancel)",
301 1.60 njoly /* 246 */ "#246 (unimplemented fadvise64)",
302 1.60 njoly /* 247 */ "#247 (unimplemented exit_group)",
303 1.60 njoly /* 248 */ "#248 (unimplemented lookup_dcookie)",
304 1.60 njoly /* 249 */ "#249 (unimplemented epoll_create)",
305 1.60 njoly /* 250 */ "#250 (unimplemented epoll_ctl)",
306 1.60 njoly /* 251 */ "#251 (unimplemented epoll_wait)",
307 1.60 njoly /* 252 */ "#252 (unimplemented remap_file_pages)",
308 1.60 njoly /* 253 */ "#253 (unimplemented set_tid_address)",
309 1.60 njoly /* 254 */ "#254 (unimplemented timer_create)",
310 1.60 njoly /* 255 */ "#255 (unimplemented timer_settime)",
311 1.60 njoly /* 256 */ "#256 (unimplemented timer_gettime)",
312 1.60 njoly /* 257 */ "#257 (unimplemented timer_getoverrun)",
313 1.60 njoly /* 258 */ "#258 (unimplemented timer_delete)",
314 1.60 njoly /* 259 */ "clock_settime",
315 1.60 njoly /* 260 */ "clock_gettime",
316 1.60 njoly /* 261 */ "clock_getres",
317 1.60 njoly /* 262 */ "clock_nanosleep",
318 1.1 itohy };
319