Training courses

Kernel and Embedded Linux

Bootlin training courses

Embedded Linux, kernel,
Yocto Project, Buildroot, real-time,
graphics, boot time, debugging...

Bootlin logo

Elixir Cross Referencer

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
	$NetBSD: syscalls.master,v 1.67 2017/02/03 16:28:34 christos Exp $

; Derived from sys/compat/linux/arch/*/syscalls.master
; and from Linux 2.4.12 arch/arm/kernel/calls.S

; NetBSD/arm 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
;	INDIR	included, but don't define the syscall args structure
;		and allow it to be "really" varargs.
;
; 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 names and switch definition files only.

#include <sys/param.h>
#include <sys/poll.h>
#include <sys/systm.h>
#include <sys/signal.h>
#include <sys/mount.h>
#include <sys/syscallargs.h>
#include <sys/time.h>

#include <compat/sys/time.h>
#include <compat/linux/common/linux_types.h>
#include <compat/linux/common/linux_mmap.h>
#include <compat/linux/common/linux_signal.h>
#include <compat/linux/common/linux_siginfo.h>
#include <compat/linux/common/linux_machdep.h>

#include <compat/linux/linux_syscallargs.h>

%%
; XXX We have to explicitly declare linux_sys_nosys.
0	NOARGS		{ int|linux_sys||nosys(void); }
1	STD		{ int|linux_sys||exit(int rval); }
2	NOARGS		{ int|sys||fork(void); }
3	NOARGS		{ ssize_t|sys||read(int fd, void *buf, size_t nbyte); }
4	NOARGS		{ ssize_t|sys||write(int fd, const void *buf, \
			    size_t nbyte); }
5	STD		{ int|linux_sys||open(const char *path, int flags, \
			    linux_umode_t 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(const char *path, linux_umode_t mode); }
9	NOARGS		{ int|sys||link(const char *path, const char *link); }
10	STD		{ int|linux_sys||unlink(const char *path); }
11	NOARGS		{ int|sys||execve(const char *path, char **argp, \
			    char **envp); }
12	NOARGS		{ int|sys||chdir(const char *path); }
13	STD		{ int|linux_sys||time(linux_time_t *t); }
14	STD		{ int|linux_sys||mknod(const char *path, linux_umode_t mode, \
			    unsigned dev); }
15	NOARGS		{ int|sys||chmod(const char *path, int mode); }
16	STD		{ int|linux_sys||lchown16(const char *path, \
			    linux_uid16_t uid, linux_gid16_t gid); }
17	OBSOL		break
18	OBSOL		ostat
19	NOARGS		{ long|compat_43_sys||lseek(int fd, long offset, \
			    int whence); }
20	NOARGS 		{ pid_t|sys||getpid(void); }
21	UNIMPL		mount
22	OBSOL		umount
23	NOARGS		{ int|sys||setuid(uid_t uid); }
24	NOARGS		{ uid_t|sys||getuid(void); }
25	STD		{ int|linux_sys||stime(linux_time_t *t); }
26	STD		{ int|linux_sys||ptrace(int request, int pid, \
			    int addr, int data); }
27	STD		{ int|linux_sys||alarm(unsigned int secs); }
28	OBSOL		ofstat
29	STD		{ int|linux_sys||pause(void); }
30	STD		{ int|linux_sys||utime(const char *path, \
			    struct linux_utimbuf *times); }
31	OBSOL		stty
32	OBSOL		gtty
33	NOARGS		{ int|sys||access(const char *path, int flags); }
34	STD		{ int|linux_sys||nice(int incr); }
35	OBSOL		ftime
36	NOARGS		{ int|sys||sync(void); }
37	STD		{ int|linux_sys||kill(int pid, int signum); }
38	NOARGS		{ int|sys||__posix_rename(const char *from, \
			    const char *to); }
39	NOARGS		{ int|sys||mkdir(const char *path, linux_umode_t mode); }
40	NOARGS		{ int|sys||rmdir(const char *path); }
41	NOARGS		{ int|sys||dup(int fd); }
42	STD		{ int|linux_sys||pipe(int *pfds); }
43	STD		{ int|linux_sys||times(struct times *tms); }
44	OBSOL		prof
45	STD		{ int|linux_sys||brk(char *nsize); }
46	NOARGS		{ int|sys||setgid(gid_t gid); }
47	NOARGS		{ gid_t|sys||getgid(void); }
48	STD		{ int|linux_sys||signal(int signum, \
			    linux_handler_t handler); }
49	NOARGS		{ uid_t|sys||geteuid(void); }
50	NOARGS		{ gid_t|sys||getegid(void); }
51	NOARGS		{ int|sys||acct(char *path); }
52	UNIMPL		umount
53	OBSOL		lock
54	STD		{ int|linux_sys||ioctl(int fd, u_long com, \
			    void *data); }
55	STD		{ int|linux_sys||fcntl(int fd, int cmd, void *arg); }
56	OBSOL		mpx
57	NOARGS		{ int|sys||setpgid(int pid, int pgid); }
58	OBSOL		ulimit
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	UNIMPL		ustat
63	NOARGS		{ int|sys||dup2(int from, 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, \
			    const 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(linux_uid16_t ruid, \
			    linux_uid16_t euid); }
71	STD		{ int|linux_sys||setregid16(linux_gid16_t rgid, \
			    linux_gid16_t egid); }
72	STD		{ int|linux_sys||sigsuspend(void *restart, \
			    int oldmask, int mask); }
73	STD		{ int|linux_sys||sigpending(linux_old_sigset_t *set); }
74	NOARGS		{ int|compat_43_sys||sethostname(char *hostname, \
			    u_int len);}
75	STD		{ int|linux_sys||setrlimit(u_int which, \
			    struct orlimit *rlp); }
76	STD		{ int|linux_sys||getrlimit(u_int which, \
			    struct orlimit *rlp); }
77	NOARGS		{ int|compat_50_sys||getrusage(int who, struct rusage50 *rusage); }
78	STD		{ int|linux_sys||gettimeofday(struct timeval50 *tp, \
			    struct timezone *tzp); }
79	STD		{ int|linux_sys||settimeofday(struct timeval50 *tp, \
			    struct timezone *tzp); }
80	STD		{ int|linux_sys||getgroups16(int gidsetsize, \
			    linux_gid16_t *gidset); }
81	STD		{ int|linux_sys||setgroups16(int gidsetsize, \
			    linux_gid16_t *gidset); }
82	STD		{ int|linux_sys||oldselect(struct linux_oldselect *lsp); }
83	NOARGS		{ int|sys||symlink(const char *path, const char *link); }
84	NOARGS		{ int|compat_43_sys||lstat(const char *path, \
			    struct stat43 *ub); } oolstat
85	NOARGS		{ ssize_t|sys||readlink(const char *path, char *buf, \
			    int count); }
#ifdef EXEC_AOUT
86	STD		{ int|linux_sys||uselib(const char *path); }
#else
86	EXCL		uselib
#endif
87	STD		{ int|linux_sys||swapon(char *name); }
88	STD		{ int|linux_sys||reboot(int magic1, int magic2, \
			    int cmd, void *arg); }
89	STD		{ int|linux_sys||readdir(int fd, void *dent, \
			    unsigned int count); }
90	STD		{ int|linux_sys||old_mmap(struct linux_oldmmap *lmp); }
91	NOARGS		{ int|sys||munmap(void *addr, size_t len); }
92	NOARGS		{ int|compat_43_sys||truncate(const char *path, \
			    long length); }
93	NOARGS		{ int|compat_43_sys||ftruncate(int fd, long length); }
94	NOARGS		{ int|sys||fchmod(int fd, linux_umode_t mode); }
95	STD		{ int|linux_sys||fchown16(int fd, linux_uid16_t uid, \
			    linux_gid16_t gid); }
96	STD		{ int|linux_sys||getpriority(int which, int who); }
97	NOARGS		{ int|sys||setpriority(int which, int who, int prio); }
98	NOARGS		{ int|sys||profil(void *samples, u_int size, \
			    u_int offset, u_int scale); }
99	STD		{ int|linux_sys||statfs(const char *path, \
			    struct linux_statfs *sp); }
100	STD		{ int|linux_sys||fstatfs(int fd, \
			    struct linux_statfs *sp); }
101	UNIMPL
102	STD		{ int|linux_sys||socketcall(int what, void *args); }
103	UNIMPL		syslog
104	NOARGS		{ int|compat_50_sys||setitimer(int which, \
			    struct itimerval50 *itv, \
			    struct itimerval50 *oitv); }
105	NOARGS		{ int|compat_50_sys||getitimer(int which, \
			    struct itimerval50 *itv); }
106	STD		{ int|linux_sys||stat(const char *path, \
			    struct linux_stat *sp); }
107	STD		{ int|linux_sys||lstat(const 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_oldutsname *up); }
110	UNIMPL
111	UNIMPL		vhangup
112	UNIMPL		idle
113	UNIMPL		syscall
114	STD		{ int|linux_sys||wait4(int pid, int *status, \
			    int options, struct rusage50 *rusage); }
115	STD		{ int|linux_sys||swapoff(const char *path); }
116	STD		{ int|linux_sys||sysinfo(struct linux_sysinfo *arg); }
117	STD		{ int|linux_sys||ipc(int what, int a1, int a2, int a3, \
			    void *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 *domainname, \
			    int len); }
122	STD		{ int|linux_sys||uname(struct linux_utsname *up); }
123	UNIMPL		modify_ldt
124	UNIMPL		adjtimex
125	STD		{ int|linux_sys||mprotect(const void *start, \
			    unsigned long len, int prot); }
126	STD		{ int|linux_sys||sigprocmask(int how, \
			    const linux_old_sigset_t *set, \
			    linux_old_sigset_t *oset); }
127	UNIMPL		create_module
128	UNIMPL		init_module
129	UNIMPL		delete_module
130	UNIMPL		get_kernel_syms
131	UNIMPL		quotactl
132	NOARGS		{ pid_t|sys||getpgid(pid_t pid); }
133	NOARGS		{ int|sys||fchdir(int fd); }
134	UNIMPL		bdflush
135	UNIMPL		sysfs
136	STD		{ int|linux_sys||personality(unsigned long per); }
137	UNIMPL		afs_syscall
138	STD		{ int|linux_sys||setfsuid(uid_t uid); }
139	STD		{ int|linux_sys||setfsgid(gid_t gid); }
140	STD		{ int|linux_sys||llseek(int fd, u_int32_t ohigh, \
			    u_int32_t olow, void *res, int whence); }
141	STD		{ int|linux_sys||getdents(int fd, \
			    struct linux_dirent *dent, unsigned int count); }
142	STD		{ int|linux_sys||select(int nfds, fd_set *readfds, \
			    fd_set *writefds, fd_set *exceptfds, \
			    struct timeval50 *timeout); }
143	NOARGS		{ int|sys||flock(int fd, int how); }
144	NOARGS		{ int|sys|13|msync(void *addr, size_t len, int flags); }
145	NOARGS		{ ssize_t|sys||readv(int fd, \
			    const struct iovec *iovp, int iovcnt); }
146	NOARGS		{ ssize_t|sys||writev(int fd, \
			    const struct iovec *iovp, int iovcnt); }
147	NOARGS		{ pid_t|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(void *addr, size_t len); }
151	NOARGS		{ int|sys||munlock(void *addr, size_t len); }
152	NOARGS		{ int|sys||mlockall(int flags); }
153	NOARGS		{ int|sys||munlockall(void); }
154	STD		{ int|linux_sys||sched_setparam(pid_t pid, \
			    const struct linux_sched_param *sp); }
155	STD		{ int|linux_sys||sched_getparam(pid_t pid, \
			    struct linux_sched_param *sp); }
156	STD		{ int|linux_sys||sched_setscheduler(pid_t pid, \
			    int policy, const struct linux_sched_param *sp); }
157	STD		{ int|linux_sys||sched_getscheduler(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	UNIMPL		sched_rr_get_interval
162	STD		{ int|linux_sys||nanosleep( \
			    const struct linux_timespec *rqtp, \
			    struct linux_timespec *rmtp); }
163	STD		{ void *|linux_sys||mremap(void *old_address, \
			    size_t old_size, size_t new_size, u_long flags); }
164	STD		{ int|linux_sys||setresuid16(linux_uid16_t ruid, \
			    linux_uid16_t euid, linux_uid16_t suid); }
165	STD		{ int|linux_sys||getresuid16(linux_uid16_t *ruid, \
			    linux_uid16_t *euid, linux_uid16_t *suid); }
166	UNIMPL
167	UNIMPL		query_module
168	NOARGS		{ int|sys||poll(struct pollfd *fds, u_int nfds, \
			    int timeout); }
169	UNIMPL		nfsservctl
170	STD		{ int|linux_sys||setresgid16(linux_gid16_t rgid, \
			    linux_gid16_t egid, linux_gid16_t sgid); }
171	STD		{ int|linux_sys||getresgid16(linux_gid16_t *rgid, \
			    linux_gid16_t *egid, linux_gid16_t *sgid); }
172	UNIMPL		prctl
173	UNIMPL		rt_sigreturn
;173	STD		{ int|linux_sys||rt_sigreturn( \
;			    struct linux_rt_sigframe *sfp); }
174	STD		{ int|linux_sys||rt_sigaction(int signum, \
			    const 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( \
			    const linux_sigset_t *set, \
			    linux_siginfo_t *info, \
			    const struct linux_timespec *timeout); }
178	STD		{ int|linux_sys||rt_queueinfo(int pid, int signum, \
			    linux_siginfo_t *uinfo); }
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, off_t offset); }
181	STD		{ int|linux_sys||pwrite(int fd, char *buf, \
			    size_t nbyte, off_t offset); }
182	STD		{ int|linux_sys||chown16(const char *path, \
			    linux_uid16_t uid, linux_gid16_t gid); }
183	NOARGS		{ int|sys||__getcwd(char *bufp, size_t length); }
184	UNIMPL		capget
185	UNIMPL		capset
186	STD		{ int|linux_sys||sigaltstack( \
			    const struct linux_sigaltstack *ss, \
			    struct linux_sigaltstack *oss); }
187	UNIMPL		sendfile
188	UNIMPL		getpmsg
189	UNIMPL		putpmsg
190	NOARGS		vfork { int|sys|14|vfork(void); }
191	STD		{ int|linux_sys||ugetrlimit(int which, \
			    struct rlimit *rlp); }
#define linux_sys_mmap2_args linux_sys_mmap_args
192	NOARGS		{ 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(const char *path, \
				off_t length); }
194	STD		{ int|linux_sys||ftruncate64(unsigned int fd, \
				off_t length); }
195	STD		{ int|linux_sys||stat64(const char *path, \
				struct linux_stat64 *sp); }
196	STD		{ int|linux_sys||lstat64(const char *path, \
				struct linux_stat64 *sp); }
197	STD		{ int|linux_sys||fstat64(int fd, \
				struct linux_stat64 *sp); }
198	NOARGS		{ int|sys||__posix_lchown(const char *path, uid_t uid, \
				gid_t gid); }
199	NOARGS		getuid32 { uid_t|sys||getuid(void); }
200	NOARGS		getgid32 { gid_t|sys||getgid(void); }
201	NOARGS		geteuid32 { uid_t|sys||geteuid(void); }
202	NOARGS		getegid32 { gid_t|sys||getegid(void); }
203	NOARGS		setreuid32 { int|sys||setreuid(uid_t ruid, \
				uid_t euid); }
204	NOARGS		setregid32 { int|sys||setregid(gid_t rgid, \
				gid_t egid); }
205	NOARGS		getgroups32 { int|sys||getgroups(int gidsetsize, \
				gid_t *gidset); }
206	NOARGS		setgroups32 { int|sys||setgroups(int gidsetsize, \
				gid_t *gidset); }
207	NOARGS		fchown32 { int|sys||__posix_fchown(int fd, uid_t uid, \
				gid_t gid); }
208	STD		setresuid32 { int|linux_sys||setresuid(uid_t ruid, \
				uid_t euid, uid_t suid); }
209	STD		getresuid32 { int|linux_sys||getresuid(uid_t *ruid, \
				uid_t *euid, uid_t *suid); }
210	STD		setresgid32 { int|linux_sys||setresgid(gid_t rgid, \
				gid_t egid, gid_t sgid); }
211	STD		getresgid32 { int|linux_sys||getresgid(gid_t *rgid, \
				gid_t *egid, gid_t *sgid); }
212	NOARGS		chown32 { int|sys||__posix_chown(const char *path, \
				uid_t uid, gid_t gid); }
213	NOARGS		setuid32 { int|sys||setuid(uid_t uid); }
214	NOARGS		setgid32 { int|sys||setgid(gid_t gid); }
215	NOARGS		setfsuid32 { int|linux_sys||setfsuid(uid_t uid); }
216	NOARGS		setfsgid32 { int|linux_sys||setfsgid(gid_t gid); }
217	STD		{ int|linux_sys||getdents64(int fd, \
			    struct linux_dirent64 *dent, unsigned int count); }
218	UNIMPL		pivot_root
219	NOARGS		{ int|sys||mincore(void *addr, size_t len, char *vec); }
220	NOARGS		{ int|sys||madvise(void *addr, size_t len, int behav); }
221	STD		{ int|linux_sys||fcntl64(int fd, int cmd, void *arg); }
222	UNIMPL		/* for tux */
223	UNIMPL		/* unused */
224	NOARGS		{ pid_t|linux_sys||gettid(void); }
225	UNIMPL		readahead
226	STD		{ int|linux_sys||setxattr(char *path, char *name, \
			    void *value, size_t size, int flags); }
227	STD		{ int|linux_sys||lsetxattr(char *path, char *name, \
			    void *value, size_t size, int flags); }
228	STD		{ int|linux_sys||fsetxattr(int fd, char *name, \
			    void *value, size_t size, int flags); }
229	STD		{ ssize_t|linux_sys||getxattr(char *path, char *name, \
			    void *value, size_t size); }
230	STD		{ ssize_t|linux_sys||lgetxattr(char *path, char *name, \
			    void *value, size_t size); }
231	STD		{ ssize_t|linux_sys||fgetxattr(int fd, char *name, \
			    void *value, size_t size); }
232	STD		{ ssize_t|linux_sys||listxattr(char *path, char *list, \
			    size_t size); }
233	STD		{ ssize_t|linux_sys||llistxattr(char *path, char *list, \
			    size_t size); }
234	STD		{ ssize_t|linux_sys||flistxattr(int fd, char *list, \
			    size_t size); }
235	STD		{ int|linux_sys||removexattr(char *path, char *name); }
236	STD		{ int|linux_sys||lremovexattr(char *path, char *name); }
237	STD		{ int|linux_sys||fremovexattr(int fd, char *name); }
238	STD		{ int|linux_sys||tkill(int tid, int sig); }
239	UNIMPL		sendfile64
240	STD		{ int|linux_sys||futex(int *uaddr, int op, int val, \
			    const struct linux_timespec *timeout, int *uaddr2, \
			    int val3); }
241	STD		{ int|linux_sys||sched_setaffinity(pid_t pid, \
			    unsigned int len, unsigned long *mask); }
242	STD		{ int|linux_sys||sched_getaffinity(pid_t pid, \
			    unsigned int len, unsigned long *mask); }
243	UNIMPL		io_setup
244	UNIMPL		io_destroy
245	UNIMPL		io_getevents
246	UNIMPL		io_submit
247	UNIMPL		io_cancel
248	STD		{ int|linux_sys||exit_group(int error_code); }
249	UNIMPL		lookup_dcookie
250	UNIMPL		epoll_create
251	UNIMPL		epoll_ctl
252	UNIMPL		epoll_wait
253	UNIMPL		remap_file_pages
254	UNIMPL		set_thread_area
255	UNIMPL		get_thread_area
256	STD		{ int|linux_sys||set_tid_address(int *tid); }
257	UNIMPL		timer_create
258	UNIMPL		timer_settime
259	UNIMPL		timer_gettime
260	UNIMPL		timer_getoverrun
261	UNIMPL		timer_delete
262	STD		{ int|linux_sys||clock_settime(clockid_t which, \
			    struct linux_timespec *tp); }
263	STD		{ int|linux_sys||clock_gettime(clockid_t which, \
			    struct linux_timespec *tp); }
264	STD		{ int|linux_sys||clock_getres(clockid_t which, \
			    struct linux_timespec *tp); }
265	STD		{ int|linux_sys||clock_nanosleep(clockid_t which, \
			    int flags, struct linux_timespec *rqtp, \
			    struct linux_timespec *rmtp); }
266	STD		{ int|linux_sys||statfs64(const char *path, \
			    size_t sz, struct linux_statfs64 *sp); }
267	STD		{ int|linux_sys||fstatfs64(int fd, \
			    size_t sz, struct linux_statfs64 *sp); }
268	STD		{ int|linux_sys||tgkill(int tgid, int tid, int sig); }
269	NOARGS		{ int|compat_50_sys||utimes(const char *path, \
			    const struct timeval50 *tptr); }
270	STD		{ int|linux_sys||fadvise64_64(int fd, off_t offset, \
			    off_t len, int advice); }
271	UNIMPL		pciconfig_iobase
272	UNIMPL		pciconfig_read
273	UNIMPL		pciconfig_write
274	UNIMPL		mq_open
275	UNIMPL		mq_unlink
276	UNIMPL		mq_timedsend
277	UNIMPL		mq_timedreceive
278	UNIMPL		mq_notify
279	UNIMPL		mq_getsetattr
280	UNIMPL		waitid
281	UNIMPL		socket
282	UNIMPL		bind
283	UNIMPL		connect
284	UNIMPL		listen
285	UNIMPL		accept
286	UNIMPL		getsockname
287	UNIMPL		getpeername
288	UNIMPL		socketpair
289	UNIMPL		send
290	UNIMPL		sendto
291	UNIMPL		recv
292	UNIMPL		recvfrom
293	UNIMPL		shutdown
294	UNIMPL		setsockopt
295	UNIMPL		getsockopt
296	UNIMPL		sendmsg
297	UNIMPL		recvmsg
298	UNIMPL		semop
299	UNIMPL		semget
300	UNIMPL		semctl
301	UNIMPL		msgsnd
302	UNIMPL		msgrcv
303	UNIMPL		msgget
304	UNIMPL		msgctl
305	UNIMPL		shmat
306	UNIMPL		shmdt
307	UNIMPL		shmget
308	UNIMPL		shmctl
309	UNIMPL		add_key
310	UNIMPL		request_key
311	UNIMPL		keyctl
312	UNIMPL		semtimedop
313	UNIMPL		vserver
314	UNIMPL		ioptio_set
315	UNIMPL		ioptio_get
316	UNIMPL		inotify_init
317	UNIMPL		inotify_add_watch
318	UNIMPL		inotify_rm_watch
319	UNIMPL		mbind
320	UNIMPL		get_mempolicy
321	UNIMPL		set_mempolicy
322	STD 		{ int|linux_sys||openat(int fd, const char *path, \
			    int flags, ... linux_umode_t mode); }
323	NOARGS		{ int|sys||mkdirat(int fd, const char *path, \
			    linux_umode_t mode); }
324	STD		{ int|linux_sys||mknodat(int fd, const char *path, \
			    linux_umode_t mode, unsigned dev); }
325	STD		{ int|linux_sys||fchownat(int fd, const char *path, \
			    uid_t owner, gid_t group, int flag); }
326	UNIMPL		futimesat
327	STD		{ int|linux_sys||fstatat64(int fd, const char *path, \
			    struct linux_stat64 *sp, int flag); }
328	STD		{ int|linux_sys||unlinkat(int fd, const char *path, \
			    int flag); }
329	NOARGS		{ int|sys||renameat(int fromfd, const char *from, \
			    int tofd, const char *to); }
330	STD		{ int|linux_sys||linkat(int fd1, const char *name1, \
			    int fd2, const char *name2, int flags); }
331	NOARGS		{ int|sys||symlinkat(const char *path1, int fd, \
			    const char *path2); }
332	NOARGS		{ ssize_t|sys||readlinkat(int fd, const char *path, \
			    char *buf, size_t bufsize); }
333	STD		{ int|linux_sys||fchmodat(int fd, const char *path, \
			    linux_umode_t mode); }
334	STD		{ int|linux_sys||faccessat(int fd, const char *path, \
			    int amode); }
335	STD		{ int|linux_sys||pselect6(int nfds, fd_set *readfds, \
			   fd_set *writefds, fd_set *exceptfds, \
			   struct linux_timespec *timeout, \
			   linux_sized_sigset_t *ss); }
336	STD		{ int|linux_sys||ppoll(struct pollfd *fds, u_int nfds, \
			    struct linux_timespec *timeout, \
			    linux_sigset_t *sigset); }
337	UNIMPL		unshare
338	STD		{ int|linux_sys||set_robust_list( \
			    struct linux_robust_list_head *head, size_t len); }
339	STD		{ int|linux_sys||get_robust_list(int pid, \
			    struct linux_robust_list_head **head, \
			    size_t *len); }
340	UNIMPL		splice
341	UNIMPL		sync_file_range2
342	UNIMPL		tee
343	UNIMPL		vmsplice
344	UNIMPL		move_pages
345	UNIMPL		getcpu
346	UNIMPL		epoll_wait
347	UNIMPL		kexec_load
348	STD		{ int|linux_sys||utimensat(int fd, const char *path, \
			    struct linux_timespec *times, int flag); }
349	UNIMPL		signalfd
350	UNIMPL		timerfd_create
351	UNIMPL		eventfd
352	UNIMPL		fallocate
353	UNIMPL		timerfd_settime
354	UNIMPL		timerfd_gettime
355	UNIMPL		signalfd4
356	UNIMPL		eventfd2
357	UNIMPL		epoll_create1
358	STD		{ int|linux_sys||dup3(int from, int to, int flags); }
359	STD		{ int|linux_sys||pipe2(int *pfds, int flags); }
360	UNIMPL		inotify_init1
361	UNIMPL		preadv
362	UNIMPL		pwritev
363	UNIMPL		rt_tgsigqueueinfo
364	UNIMPL		perf_counter_open
365	STD		{ int|linux_sys||recvmmsg(int s, \
			    struct linux_mmsghdr *msgvec, unsigned int vlen, \
			    unsigned int flags, struct timespec *timeout); }
366	STD		{ int|linux_sys||accept4(int s, \
			    struct osockaddr *name, \
			    int *anamelen, int flags); }
367	UNIMPL		fanotify_init
368	UNIMPL		fanotify_mark
369	UNIMPL		prlimit64
370	UNIMPL		name_to_handle_at
371	UNIMPL		open_by_handle_at
372	UNIMPL		clock_adjtime
373	UNIMPL		syncfs
374	STD		{ int|linux_sys||sendmmsg(int s, \
			    struct linux_mmsghdr *msgvec, unsigned int vlen, \
			    unsigned int flags); }
375	UNIMPL		setns
376	UNIMPL		process_vm_readv
377	UNIMPL		process_vm_writev
378	UNIMPL		kcmp
379	UNIMPL		finit_module
380	UNIMPL		sched_setattr
381	UNIMPL		sched_getattr
382	UNIMPL		renameat2
383	UNIMPL		seccomp
; XXX FIX-me?
; 384	UNIMPL		getrandom
; 385	UNIMPL		memfd_create

; ARMLinux actually has two ranges of syscalls.  Normal syscalls use
; SWI numbers starting at 0x900000 (__NR_SYSCALL_BASE).  Special
; ARM-specific syscalls use SWI numbers starting at 0x9f0000
; (__ARM_NR_BASE).  linux_syscall() (in arch/arm/arm/linux_syscall.c)
; remaps these down to 0x900180 so that we can use one linux_sysent
; array for the whole lot.

384	UNIMPL		/* base */
385	STD		{ int|linux_sys||breakpoint(void); }
386	STD		{ int|linux_sys||cacheflush(uintptr_t from, \
				intptr_t to, int flags); }
387	UNIMPL		usr26
388	UNIMPL		usr32
389	STD		{ int|linux_sys||set_tls(void *tls); }