1/*	$OpenBSD: src/sys/sys/syscallargs.h,v 1.163 2014/12/08 20:56:34 guenther Exp $	*/
2
3/*
4 * System call argument lists.
5 *
6 * DO NOT EDIT-- this file is automatically generated.
7 * created from;	OpenBSD: syscalls.master,v 1.149 2014/12/08 20:56:11 guenther Exp
8 */
9
10#ifdef	syscallarg
11#undef	syscallarg
12#endif
13
14#define	syscallarg(x)							\
15	union {								\
16		register_t pad;						\
17		struct { x datum; } le;					\
18		struct {						\
19			int8_t pad[ (sizeof (register_t) < sizeof (x))	\
20				? 0					\
21				: sizeof (register_t) - sizeof (x)];	\
22			x datum;					\
23		} be;							\
24	}
25
26struct sys_exit_args {
27	syscallarg(int) rval;
28};
29
30struct sys_read_args {
31	syscallarg(int) fd;
32	syscallarg(void *) buf;
33	syscallarg(size_t) nbyte;
34};
35
36struct sys_write_args {
37	syscallarg(int) fd;
38	syscallarg(const void *) buf;
39	syscallarg(size_t) nbyte;
40};
41
42struct sys_open_args {
43	syscallarg(const char *) path;
44	syscallarg(int) flags;
45	syscallarg(mode_t) mode;
46};
47
48struct sys_close_args {
49	syscallarg(int) fd;
50};
51
52struct sys_getentropy_args {
53	syscallarg(void *) buf;
54	syscallarg(size_t) nbyte;
55};
56
57struct sys___tfork_args {
58	syscallarg(const struct __tfork *) param;
59	syscallarg(size_t) psize;
60};
61
62struct sys_link_args {
63	syscallarg(const char *) path;
64	syscallarg(const char *) link;
65};
66
67struct sys_unlink_args {
68	syscallarg(const char *) path;
69};
70
71struct sys_wait4_args {
72	syscallarg(pid_t) pid;
73	syscallarg(int *) status;
74	syscallarg(int) options;
75	syscallarg(struct rusage *) rusage;
76};
77
78struct sys_chdir_args {
79	syscallarg(const char *) path;
80};
81
82struct sys_fchdir_args {
83	syscallarg(int) fd;
84};
85
86struct sys_mknod_args {
87	syscallarg(const char *) path;
88	syscallarg(mode_t) mode;
89	syscallarg(dev_t) dev;
90};
91
92struct sys_chmod_args {
93	syscallarg(const char *) path;
94	syscallarg(mode_t) mode;
95};
96
97struct sys_chown_args {
98	syscallarg(const char *) path;
99	syscallarg(uid_t) uid;
100	syscallarg(gid_t) gid;
101};
102
103struct sys_obreak_args {
104	syscallarg(char *) nsize;
105};
106
107struct sys_getrusage_args {
108	syscallarg(int) who;
109	syscallarg(struct rusage *) rusage;
110};
111
112struct sys_mount_args {
113	syscallarg(const char *) type;
114	syscallarg(const char *) path;
115	syscallarg(int) flags;
116	syscallarg(void *) data;
117};
118
119struct sys_unmount_args {
120	syscallarg(const char *) path;
121	syscallarg(int) flags;
122};
123
124struct sys_setuid_args {
125	syscallarg(uid_t) uid;
126};
127
128struct sys_ptrace_args {
129	syscallarg(int) req;
130	syscallarg(pid_t) pid;
131	syscallarg(caddr_t) addr;
132	syscallarg(int) data;
133};
134
135struct sys_recvmsg_args {
136	syscallarg(int) s;
137	syscallarg(struct msghdr *) msg;
138	syscallarg(int) flags;
139};
140
141struct sys_sendmsg_args {
142	syscallarg(int) s;
143	syscallarg(const struct msghdr *) msg;
144	syscallarg(int) flags;
145};
146
147struct sys_recvfrom_args {
148	syscallarg(int) s;
149	syscallarg(void *) buf;
150	syscallarg(size_t) len;
151	syscallarg(int) flags;
152	syscallarg(struct sockaddr *) from;
153	syscallarg(socklen_t *) fromlenaddr;
154};
155
156struct sys_accept_args {
157	syscallarg(int) s;
158	syscallarg(struct sockaddr *) name;
159	syscallarg(socklen_t *) anamelen;
160};
161
162struct sys_getpeername_args {
163	syscallarg(int) fdes;
164	syscallarg(struct sockaddr *) asa;
165	syscallarg(socklen_t *) alen;
166};
167
168struct sys_getsockname_args {
169	syscallarg(int) fdes;
170	syscallarg(struct sockaddr *) asa;
171	syscallarg(socklen_t *) alen;
172};
173
174struct sys_access_args {
175	syscallarg(const char *) path;
176	syscallarg(int) amode;
177};
178
179struct sys_chflags_args {
180	syscallarg(const char *) path;
181	syscallarg(u_int) flags;
182};
183
184struct sys_fchflags_args {
185	syscallarg(int) fd;
186	syscallarg(u_int) flags;
187};
188
189struct sys_kill_args {
190	syscallarg(int) pid;
191	syscallarg(int) signum;
192};
193
194struct sys_stat_args {
195	syscallarg(const char *) path;
196	syscallarg(struct stat *) ub;
197};
198
199struct sys_lstat_args {
200	syscallarg(const char *) path;
201	syscallarg(struct stat *) ub;
202};
203
204struct sys_dup_args {
205	syscallarg(int) fd;
206};
207
208struct sys_fstatat_args {
209	syscallarg(int) fd;
210	syscallarg(const char *) path;
211	syscallarg(struct stat *) buf;
212	syscallarg(int) flag;
213};
214
215struct sys_profil_args {
216	syscallarg(caddr_t) samples;
217	syscallarg(size_t) size;
218	syscallarg(u_long) offset;
219	syscallarg(u_int) scale;
220};
221
222struct sys_ktrace_args {
223	syscallarg(const char *) fname;
224	syscallarg(int) ops;
225	syscallarg(int) facs;
226	syscallarg(pid_t) pid;
227};
228
229struct sys_sigaction_args {
230	syscallarg(int) signum;
231	syscallarg(const struct sigaction *) nsa;
232	syscallarg(struct sigaction *) osa;
233};
234
235struct sys_sigprocmask_args {
236	syscallarg(int) how;
237	syscallarg(sigset_t) mask;
238};
239
240struct sys_getlogin_args {
241	syscallarg(char *) namebuf;
242	syscallarg(u_int) namelen;
243};
244
245struct sys_setlogin_args {
246	syscallarg(const char *) namebuf;
247};
248
249struct sys_acct_args {
250	syscallarg(const char *) path;
251};
252
253struct sys_fstat_args {
254	syscallarg(int) fd;
255	syscallarg(struct stat *) sb;
256};
257
258struct sys_ioctl_args {
259	syscallarg(int) fd;
260	syscallarg(u_long) com;
261	syscallarg(void *) data;
262};
263
264struct sys_reboot_args {
265	syscallarg(int) opt;
266};
267
268struct sys_revoke_args {
269	syscallarg(const char *) path;
270};
271
272struct sys_symlink_args {
273	syscallarg(const char *) path;
274	syscallarg(const char *) link;
275};
276
277struct sys_readlink_args {
278	syscallarg(const char *) path;
279	syscallarg(char *) buf;
280	syscallarg(size_t) count;
281};
282
283struct sys_execve_args {
284	syscallarg(const char *) path;
285	syscallarg(char *const *) argp;
286	syscallarg(char *const *) envp;
287};
288
289struct sys_umask_args {
290	syscallarg(mode_t) newmask;
291};
292
293struct sys_chroot_args {
294	syscallarg(const char *) path;
295};
296
297struct sys_getfsstat_args {
298	syscallarg(struct statfs *) buf;
299	syscallarg(size_t) bufsize;
300	syscallarg(int) flags;
301};
302
303struct sys_statfs_args {
304	syscallarg(const char *) path;
305	syscallarg(struct statfs *) buf;
306};
307
308struct sys_fstatfs_args {
309	syscallarg(int) fd;
310	syscallarg(struct statfs *) buf;
311};
312
313struct sys_fhstatfs_args {
314	syscallarg(const fhandle_t *) fhp;
315	syscallarg(struct statfs *) buf;
316};
317
318struct sys_gettimeofday_args {
319	syscallarg(struct timeval *) tp;
320	syscallarg(struct timezone *) tzp;
321};
322
323struct sys_settimeofday_args {
324	syscallarg(const struct timeval *) tv;
325	syscallarg(const struct timezone *) tzp;
326};
327
328struct sys_setitimer_args {
329	syscallarg(int) which;
330	syscallarg(const struct itimerval *) itv;
331	syscallarg(struct itimerval *) oitv;
332};
333
334struct sys_getitimer_args {
335	syscallarg(int) which;
336	syscallarg(struct itimerval *) itv;
337};
338
339struct sys_select_args {
340	syscallarg(int) nd;
341	syscallarg(fd_set *) in;
342	syscallarg(fd_set *) ou;
343	syscallarg(fd_set *) ex;
344	syscallarg(struct timeval *) tv;
345};
346
347struct sys_kevent_args {
348	syscallarg(int) fd;
349	syscallarg(const struct kevent *) changelist;
350	syscallarg(int) nchanges;
351	syscallarg(struct kevent *) eventlist;
352	syscallarg(int) nevents;
353	syscallarg(const struct timespec *) timeout;
354};
355
356struct sys_munmap_args {
357	syscallarg(void *) addr;
358	syscallarg(size_t) len;
359};
360
361struct sys_mprotect_args {
362	syscallarg(void *) addr;
363	syscallarg(size_t) len;
364	syscallarg(int) prot;
365};
366
367struct sys_madvise_args {
368	syscallarg(void *) addr;
369	syscallarg(size_t) len;
370	syscallarg(int) behav;
371};
372
373struct sys_utimes_args {
374	syscallarg(const char *) path;
375	syscallarg(const struct timeval *) tptr;
376};
377
378struct sys_futimes_args {
379	syscallarg(int) fd;
380	syscallarg(const struct timeval *) tptr;
381};
382
383struct sys_mincore_args {
384	syscallarg(void *) addr;
385	syscallarg(size_t) len;
386	syscallarg(char *) vec;
387};
388
389struct sys_getgroups_args {
390	syscallarg(int) gidsetsize;
391	syscallarg(gid_t *) gidset;
392};
393
394struct sys_setgroups_args {
395	syscallarg(int) gidsetsize;
396	syscallarg(const gid_t *) gidset;
397};
398
399struct sys_setpgid_args {
400	syscallarg(pid_t) pid;
401	syscallarg(pid_t) pgid;
402};
403
404struct sys_sendsyslog_args {
405	syscallarg(const void *) buf;
406	syscallarg(size_t) nbyte;
407};
408
409struct sys_utimensat_args {
410	syscallarg(int) fd;
411	syscallarg(const char *) path;
412	syscallarg(const struct timespec *) times;
413	syscallarg(int) flag;
414};
415
416struct sys_futimens_args {
417	syscallarg(int) fd;
418	syscallarg(const struct timespec *) times;
419};
420
421struct sys_clock_gettime_args {
422	syscallarg(clockid_t) clock_id;
423	syscallarg(struct timespec *) tp;
424};
425
426struct sys_clock_settime_args {
427	syscallarg(clockid_t) clock_id;
428	syscallarg(const struct timespec *) tp;
429};
430
431struct sys_clock_getres_args {
432	syscallarg(clockid_t) clock_id;
433	syscallarg(struct timespec *) tp;
434};
435
436struct sys_dup2_args {
437	syscallarg(int) from;
438	syscallarg(int) to;
439};
440
441struct sys_nanosleep_args {
442	syscallarg(const struct timespec *) rqtp;
443	syscallarg(struct timespec *) rmtp;
444};
445
446struct sys_fcntl_args {
447	syscallarg(int) fd;
448	syscallarg(int) cmd;
449	syscallarg(void *) arg;
450};
451
452struct sys_accept4_args {
453	syscallarg(int) s;
454	syscallarg(struct sockaddr *) name;
455	syscallarg(socklen_t *) anamelen;
456	syscallarg(int) flags;
457};
458
459struct sys___thrsleep_args {
460	syscallarg(const volatile void *) ident;
461	syscallarg(clockid_t) clock_id;
462	syscallarg(const struct timespec *) tp;
463	syscallarg(void *) lock;
464	syscallarg(const int *) abort;
465};
466
467struct sys_fsync_args {
468	syscallarg(int) fd;
469};
470
471struct sys_setpriority_args {
472	syscallarg(int) which;
473	syscallarg(id_t) who;
474	syscallarg(int) prio;
475};
476
477struct sys_socket_args {
478	syscallarg(int) domain;
479	syscallarg(int) type;
480	syscallarg(int) protocol;
481};
482
483struct sys_connect_args {
484	syscallarg(int) s;
485	syscallarg(const struct sockaddr *) name;
486	syscallarg(socklen_t) namelen;
487};
488
489struct sys_getdents_args {
490	syscallarg(int) fd;
491	syscallarg(void *) buf;
492	syscallarg(size_t) buflen;
493};
494
495struct sys_getpriority_args {
496	syscallarg(int) which;
497	syscallarg(id_t) who;
498};
499
500struct sys_pipe2_args {
501	syscallarg(int *) fdp;
502	syscallarg(int) flags;
503};
504
505struct sys_dup3_args {
506	syscallarg(int) from;
507	syscallarg(int) to;
508	syscallarg(int) flags;
509};
510
511struct sys_sigreturn_args {
512	syscallarg(struct sigcontext *) sigcntxp;
513};
514
515struct sys_bind_args {
516	syscallarg(int) s;
517	syscallarg(const struct sockaddr *) name;
518	syscallarg(socklen_t) namelen;
519};
520
521struct sys_setsockopt_args {
522	syscallarg(int) s;
523	syscallarg(int) level;
524	syscallarg(int) name;
525	syscallarg(const void *) val;
526	syscallarg(socklen_t) valsize;
527};
528
529struct sys_listen_args {
530	syscallarg(int) s;
531	syscallarg(int) backlog;
532};
533
534struct sys_chflagsat_args {
535	syscallarg(int) fd;
536	syscallarg(const char *) path;
537	syscallarg(u_int) flags;
538	syscallarg(int) atflags;
539};
540
541struct sys_ppoll_args {
542	syscallarg(struct pollfd *) fds;
543	syscallarg(u_int) nfds;
544	syscallarg(const struct timespec *) ts;
545	syscallarg(const sigset_t *) mask;
546};
547
548struct sys_pselect_args {
549	syscallarg(int) nd;
550	syscallarg(fd_set *) in;
551	syscallarg(fd_set *) ou;
552	syscallarg(fd_set *) ex;
553	syscallarg(const struct timespec *) ts;
554	syscallarg(const sigset_t *) mask;
555};
556
557struct sys_sigsuspend_args {
558	syscallarg(int) mask;
559};
560
561struct sys_getsockopt_args {
562	syscallarg(int) s;
563	syscallarg(int) level;
564	syscallarg(int) name;
565	syscallarg(void *) val;
566	syscallarg(socklen_t *) avalsize;
567};
568
569struct sys_readv_args {
570	syscallarg(int) fd;
571	syscallarg(const struct iovec *) iovp;
572	syscallarg(int) iovcnt;
573};
574
575struct sys_writev_args {
576	syscallarg(int) fd;
577	syscallarg(const struct iovec *) iovp;
578	syscallarg(int) iovcnt;
579};
580
581struct sys_fchown_args {
582	syscallarg(int) fd;
583	syscallarg(uid_t) uid;
584	syscallarg(gid_t) gid;
585};
586
587struct sys_fchmod_args {
588	syscallarg(int) fd;
589	syscallarg(mode_t) mode;
590};
591
592struct sys_setreuid_args {
593	syscallarg(uid_t) ruid;
594	syscallarg(uid_t) euid;
595};
596
597struct sys_setregid_args {
598	syscallarg(gid_t) rgid;
599	syscallarg(gid_t) egid;
600};
601
602struct sys_rename_args {
603	syscallarg(const char *) from;
604	syscallarg(const char *) to;
605};
606
607struct sys_flock_args {
608	syscallarg(int) fd;
609	syscallarg(int) how;
610};
611
612struct sys_mkfifo_args {
613	syscallarg(const char *) path;
614	syscallarg(mode_t) mode;
615};
616
617struct sys_sendto_args {
618	syscallarg(int) s;
619	syscallarg(const void *) buf;
620	syscallarg(size_t) len;
621	syscallarg(int) flags;
622	syscallarg(const struct sockaddr *) to;
623	syscallarg(socklen_t) tolen;
624};
625
626struct sys_shutdown_args {
627	syscallarg(int) s;
628	syscallarg(int) how;
629};
630
631struct sys_socketpair_args {
632	syscallarg(int) domain;
633	syscallarg(int) type;
634	syscallarg(int) protocol;
635	syscallarg(int *) rsv;
636};
637
638struct sys_mkdir_args {
639	syscallarg(const char *) path;
640	syscallarg(mode_t) mode;
641};
642
643struct sys_rmdir_args {
644	syscallarg(const char *) path;
645};
646
647struct sys_adjtime_args {
648	syscallarg(const struct timeval *) delta;
649	syscallarg(struct timeval *) olddelta;
650};
651
652struct sys_quotactl_args {
653	syscallarg(const char *) path;
654	syscallarg(int) cmd;
655	syscallarg(int) uid;
656	syscallarg(char *) arg;
657};
658
659struct sys_nfssvc_args {
660	syscallarg(int) flag;
661	syscallarg(void *) argp;
662};
663
664struct sys_getfh_args {
665	syscallarg(const char *) fname;
666	syscallarg(fhandle_t *) fhp;
667};
668
669struct sys_sysarch_args {
670	syscallarg(int) op;
671	syscallarg(void *) parms;
672};
673
674struct sys_pread_args {
675	syscallarg(int) fd;
676	syscallarg(void *) buf;
677	syscallarg(size_t) nbyte;
678	syscallarg(int) pad;
679	syscallarg(off_t) offset;
680};
681
682struct sys_pwrite_args {
683	syscallarg(int) fd;
684	syscallarg(const void *) buf;
685	syscallarg(size_t) nbyte;
686	syscallarg(int) pad;
687	syscallarg(off_t) offset;
688};
689
690struct sys_setgid_args {
691	syscallarg(gid_t) gid;
692};
693
694struct sys_setegid_args {
695	syscallarg(gid_t) egid;
696};
697
698struct sys_seteuid_args {
699	syscallarg(uid_t) euid;
700};
701
702struct sys_pathconf_args {
703	syscallarg(const char *) path;
704	syscallarg(int) name;
705};
706
707struct sys_fpathconf_args {
708	syscallarg(int) fd;
709	syscallarg(int) name;
710};
711
712struct sys_swapctl_args {
713	syscallarg(int) cmd;
714	syscallarg(const void *) arg;
715	syscallarg(int) misc;
716};
717
718struct sys_getrlimit_args {
719	syscallarg(int) which;
720	syscallarg(struct rlimit *) rlp;
721};
722
723struct sys_setrlimit_args {
724	syscallarg(int) which;
725	syscallarg(const struct rlimit *) rlp;
726};
727
728struct sys_mmap_args {
729	syscallarg(void *) addr;
730	syscallarg(size_t) len;
731	syscallarg(int) prot;
732	syscallarg(int) flags;
733	syscallarg(int) fd;
734	syscallarg(long) pad;
735	syscallarg(off_t) pos;
736};
737
738struct sys_lseek_args {
739	syscallarg(int) fd;
740	syscallarg(int) pad;
741	syscallarg(off_t) offset;
742	syscallarg(int) whence;
743};
744
745struct sys_truncate_args {
746	syscallarg(const char *) path;
747	syscallarg(int) pad;
748	syscallarg(off_t) length;
749};
750
751struct sys_ftruncate_args {
752	syscallarg(int) fd;
753	syscallarg(int) pad;
754	syscallarg(off_t) length;
755};
756
757struct sys___sysctl_args {
758	syscallarg(const int *) name;
759	syscallarg(u_int) namelen;
760	syscallarg(void *) old;
761	syscallarg(size_t *) oldlenp;
762	syscallarg(void *) new;
763	syscallarg(size_t) newlen;
764};
765
766struct sys_mlock_args {
767	syscallarg(const void *) addr;
768	syscallarg(size_t) len;
769};
770
771struct sys_munlock_args {
772	syscallarg(const void *) addr;
773	syscallarg(size_t) len;
774};
775
776struct sys_getpgid_args {
777	syscallarg(pid_t) pid;
778};
779
780struct sys_utrace_args {
781	syscallarg(const char *) label;
782	syscallarg(const void *) addr;
783	syscallarg(size_t) len;
784};
785
786struct sys_semget_args {
787	syscallarg(key_t) key;
788	syscallarg(int) nsems;
789	syscallarg(int) semflg;
790};
791
792struct sys_msgget_args {
793	syscallarg(key_t) key;
794	syscallarg(int) msgflg;
795};
796
797struct sys_msgsnd_args {
798	syscallarg(int) msqid;
799	syscallarg(const void *) msgp;
800	syscallarg(size_t) msgsz;
801	syscallarg(int) msgflg;
802};
803
804struct sys_msgrcv_args {
805	syscallarg(int) msqid;
806	syscallarg(void *) msgp;
807	syscallarg(size_t) msgsz;
808	syscallarg(long) msgtyp;
809	syscallarg(int) msgflg;
810};
811
812struct sys_shmat_args {
813	syscallarg(int) shmid;
814	syscallarg(const void *) shmaddr;
815	syscallarg(int) shmflg;
816};
817
818struct sys_shmdt_args {
819	syscallarg(const void *) shmaddr;
820};
821
822struct sys_minherit_args {
823	syscallarg(void *) addr;
824	syscallarg(size_t) len;
825	syscallarg(int) inherit;
826};
827
828struct sys_poll_args {
829	syscallarg(struct pollfd *) fds;
830	syscallarg(u_int) nfds;
831	syscallarg(int) timeout;
832};
833
834struct sys_lchown_args {
835	syscallarg(const char *) path;
836	syscallarg(uid_t) uid;
837	syscallarg(gid_t) gid;
838};
839
840struct sys_getsid_args {
841	syscallarg(pid_t) pid;
842};
843
844struct sys_msync_args {
845	syscallarg(void *) addr;
846	syscallarg(size_t) len;
847	syscallarg(int) flags;
848};
849
850struct sys_pipe_args {
851	syscallarg(int *) fdp;
852};
853
854struct sys_fhopen_args {
855	syscallarg(const fhandle_t *) fhp;
856	syscallarg(int) flags;
857};
858
859struct sys_preadv_args {
860	syscallarg(int) fd;
861	syscallarg(const struct iovec *) iovp;
862	syscallarg(int) iovcnt;
863	syscallarg(int) pad;
864	syscallarg(off_t) offset;
865};
866
867struct sys_pwritev_args {
868	syscallarg(int) fd;
869	syscallarg(const struct iovec *) iovp;
870	syscallarg(int) iovcnt;
871	syscallarg(int) pad;
872	syscallarg(off_t) offset;
873};
874
875struct sys_mlockall_args {
876	syscallarg(int) flags;
877};
878
879struct sys_getresuid_args {
880	syscallarg(uid_t *) ruid;
881	syscallarg(uid_t *) euid;
882	syscallarg(uid_t *) suid;
883};
884
885struct sys_setresuid_args {
886	syscallarg(uid_t) ruid;
887	syscallarg(uid_t) euid;
888	syscallarg(uid_t) suid;
889};
890
891struct sys_getresgid_args {
892	syscallarg(gid_t *) rgid;
893	syscallarg(gid_t *) egid;
894	syscallarg(gid_t *) sgid;
895};
896
897struct sys_setresgid_args {
898	syscallarg(gid_t) rgid;
899	syscallarg(gid_t) egid;
900	syscallarg(gid_t) sgid;
901};
902
903struct sys_mquery_args {
904	syscallarg(void *) addr;
905	syscallarg(size_t) len;
906	syscallarg(int) prot;
907	syscallarg(int) flags;
908	syscallarg(int) fd;
909	syscallarg(long) pad;
910	syscallarg(off_t) pos;
911};
912
913struct sys_closefrom_args {
914	syscallarg(int) fd;
915};
916
917struct sys_sigaltstack_args {
918	syscallarg(const struct sigaltstack *) nss;
919	syscallarg(struct sigaltstack *) oss;
920};
921
922struct sys_shmget_args {
923	syscallarg(key_t) key;
924	syscallarg(size_t) size;
925	syscallarg(int) shmflg;
926};
927
928struct sys_semop_args {
929	syscallarg(int) semid;
930	syscallarg(struct sembuf *) sops;
931	syscallarg(size_t) nsops;
932};
933
934struct sys_fhstat_args {
935	syscallarg(const fhandle_t *) fhp;
936	syscallarg(struct stat *) sb;
937};
938
939struct sys___semctl_args {
940	syscallarg(int) semid;
941	syscallarg(int) semnum;
942	syscallarg(int) cmd;
943	syscallarg(union semun *) arg;
944};
945
946struct sys_shmctl_args {
947	syscallarg(int) shmid;
948	syscallarg(int) cmd;
949	syscallarg(struct shmid_ds *) buf;
950};
951
952struct sys_msgctl_args {
953	syscallarg(int) msqid;
954	syscallarg(int) cmd;
955	syscallarg(struct msqid_ds *) buf;
956};
957
958struct sys___thrwakeup_args {
959	syscallarg(const volatile void *) ident;
960	syscallarg(int) n;
961};
962
963struct sys___threxit_args {
964	syscallarg(pid_t *) notdead;
965};
966
967struct sys___thrsigdivert_args {
968	syscallarg(sigset_t) sigmask;
969	syscallarg(siginfo_t *) info;
970	syscallarg(const struct timespec *) timeout;
971};
972
973struct sys___getcwd_args {
974	syscallarg(char *) buf;
975	syscallarg(size_t) len;
976};
977
978struct sys_adjfreq_args {
979	syscallarg(const int64_t *) freq;
980	syscallarg(int64_t *) oldfreq;
981};
982
983struct sys_setrtable_args {
984	syscallarg(int) rtableid;
985};
986
987struct sys_faccessat_args {
988	syscallarg(int) fd;
989	syscallarg(const char *) path;
990	syscallarg(int) amode;
991	syscallarg(int) flag;
992};
993
994struct sys_fchmodat_args {
995	syscallarg(int) fd;
996	syscallarg(const char *) path;
997	syscallarg(mode_t) mode;
998	syscallarg(int) flag;
999};
1000
1001struct sys_fchownat_args {
1002	syscallarg(int) fd;
1003	syscallarg(const char *) path;
1004	syscallarg(uid_t) uid;
1005	syscallarg(gid_t) gid;
1006	syscallarg(int) flag;
1007};
1008
1009struct sys_linkat_args {
1010	syscallarg(int) fd1;
1011	syscallarg(const char *) path1;
1012	syscallarg(int) fd2;
1013	syscallarg(const char *) path2;
1014	syscallarg(int) flag;
1015};
1016
1017struct sys_mkdirat_args {
1018	syscallarg(int) fd;
1019	syscallarg(const char *) path;
1020	syscallarg(mode_t) mode;
1021};
1022
1023struct sys_mkfifoat_args {
1024	syscallarg(int) fd;
1025	syscallarg(const char *) path;
1026	syscallarg(mode_t) mode;
1027};
1028
1029struct sys_mknodat_args {
1030	syscallarg(int) fd;
1031	syscallarg(const char *) path;
1032	syscallarg(mode_t) mode;
1033	syscallarg(dev_t) dev;
1034};
1035
1036struct sys_openat_args {
1037	syscallarg(int) fd;
1038	syscallarg(const char *) path;
1039	syscallarg(int) flags;
1040	syscallarg(mode_t) mode;
1041};
1042
1043struct sys_readlinkat_args {
1044	syscallarg(int) fd;
1045	syscallarg(const char *) path;
1046	syscallarg(char *) buf;
1047	syscallarg(size_t) count;
1048};
1049
1050struct sys_renameat_args {
1051	syscallarg(int) fromfd;
1052	syscallarg(const char *) from;
1053	syscallarg(int) tofd;
1054	syscallarg(const char *) to;
1055};
1056
1057struct sys_symlinkat_args {
1058	syscallarg(const char *) path;
1059	syscallarg(int) fd;
1060	syscallarg(const char *) link;
1061};
1062
1063struct sys_unlinkat_args {
1064	syscallarg(int) fd;
1065	syscallarg(const char *) path;
1066	syscallarg(int) flag;
1067};
1068
1069struct sys___set_tcb_args {
1070	syscallarg(void *) tcb;
1071};
1072
1073/*
1074 * System call prototypes.
1075 */
1076
1077int	sys_exit(struct proc *, void *, register_t *);
1078int	sys_fork(struct proc *, void *, register_t *);
1079int	sys_read(struct proc *, void *, register_t *);
1080int	sys_write(struct proc *, void *, register_t *);
1081int	sys_open(struct proc *, void *, register_t *);
1082int	sys_close(struct proc *, void *, register_t *);
1083int	sys_getentropy(struct proc *, void *, register_t *);
1084int	sys___tfork(struct proc *, void *, register_t *);
1085int	sys_link(struct proc *, void *, register_t *);
1086int	sys_unlink(struct proc *, void *, register_t *);
1087int	sys_wait4(struct proc *, void *, register_t *);
1088int	sys_chdir(struct proc *, void *, register_t *);
1089int	sys_fchdir(struct proc *, void *, register_t *);
1090int	sys_mknod(struct proc *, void *, register_t *);
1091int	sys_chmod(struct proc *, void *, register_t *);
1092int	sys_chown(struct proc *, void *, register_t *);
1093int	sys_obreak(struct proc *, void *, register_t *);
1094int	sys_getdtablecount(struct proc *, void *, register_t *);
1095int	sys_getrusage(struct proc *, void *, register_t *);
1096int	sys_getpid(struct proc *, void *, register_t *);
1097int	sys_mount(struct proc *, void *, register_t *);
1098int	sys_unmount(struct proc *, void *, register_t *);
1099int	sys_setuid(struct proc *, void *, register_t *);
1100int	sys_getuid(struct proc *, void *, register_t *);
1101int	sys_geteuid(struct proc *, void *, register_t *);
1102#ifdef PTRACE
1103int	sys_ptrace(struct proc *, void *, register_t *);
1104#else
1105#endif
1106int	sys_recvmsg(struct proc *, void *, register_t *);
1107int	sys_sendmsg(struct proc *, void *, register_t *);
1108int	sys_recvfrom(struct proc *, void *, register_t *);
1109int	sys_accept(struct proc *, void *, register_t *);
1110int	sys_getpeername(struct proc *, void *, register_t *);
1111int	sys_getsockname(struct proc *, void *, register_t *);
1112int	sys_access(struct proc *, void *, register_t *);
1113int	sys_chflags(struct proc *, void *, register_t *);
1114int	sys_fchflags(struct proc *, void *, register_t *);
1115int	sys_sync(struct proc *, void *, register_t *);
1116int	sys_kill(struct proc *, void *, register_t *);
1117int	sys_stat(struct proc *, void *, register_t *);
1118int	sys_getppid(struct proc *, void *, register_t *);
1119int	sys_lstat(struct proc *, void *, register_t *);
1120int	sys_dup(struct proc *, void *, register_t *);
1121int	sys_fstatat(struct proc *, void *, register_t *);
1122int	sys_getegid(struct proc *, void *, register_t *);
1123int	sys_profil(struct proc *, void *, register_t *);
1124#ifdef KTRACE
1125int	sys_ktrace(struct proc *, void *, register_t *);
1126#else
1127#endif
1128int	sys_sigaction(struct proc *, void *, register_t *);
1129int	sys_getgid(struct proc *, void *, register_t *);
1130int	sys_sigprocmask(struct proc *, void *, register_t *);
1131int	sys_getlogin(struct proc *, void *, register_t *);
1132int	sys_setlogin(struct proc *, void *, register_t *);
1133#ifdef ACCOUNTING
1134int	sys_acct(struct proc *, void *, register_t *);
1135#else
1136#endif
1137int	sys_sigpending(struct proc *, void *, register_t *);
1138int	sys_fstat(struct proc *, void *, register_t *);
1139int	sys_ioctl(struct proc *, void *, register_t *);
1140int	sys_reboot(struct proc *, void *, register_t *);
1141int	sys_revoke(struct proc *, void *, register_t *);
1142int	sys_symlink(struct proc *, void *, register_t *);
1143int	sys_readlink(struct proc *, void *, register_t *);
1144int	sys_execve(struct proc *, void *, register_t *);
1145int	sys_umask(struct proc *, void *, register_t *);
1146int	sys_chroot(struct proc *, void *, register_t *);
1147int	sys_getfsstat(struct proc *, void *, register_t *);
1148int	sys_statfs(struct proc *, void *, register_t *);
1149int	sys_fstatfs(struct proc *, void *, register_t *);
1150int	sys_fhstatfs(struct proc *, void *, register_t *);
1151int	sys_vfork(struct proc *, void *, register_t *);
1152int	sys_gettimeofday(struct proc *, void *, register_t *);
1153int	sys_settimeofday(struct proc *, void *, register_t *);
1154int	sys_setitimer(struct proc *, void *, register_t *);
1155int	sys_getitimer(struct proc *, void *, register_t *);
1156int	sys_select(struct proc *, void *, register_t *);
1157int	sys_kevent(struct proc *, void *, register_t *);
1158int	sys_munmap(struct proc *, void *, register_t *);
1159int	sys_mprotect(struct proc *, void *, register_t *);
1160int	sys_madvise(struct proc *, void *, register_t *);
1161int	sys_utimes(struct proc *, void *, register_t *);
1162int	sys_futimes(struct proc *, void *, register_t *);
1163int	sys_mincore(struct proc *, void *, register_t *);
1164int	sys_getgroups(struct proc *, void *, register_t *);
1165int	sys_setgroups(struct proc *, void *, register_t *);
1166int	sys_getpgrp(struct proc *, void *, register_t *);
1167int	sys_setpgid(struct proc *, void *, register_t *);
1168int	sys_sendsyslog(struct proc *, void *, register_t *);
1169int	sys_utimensat(struct proc *, void *, register_t *);
1170int	sys_futimens(struct proc *, void *, register_t *);
1171int	sys_clock_gettime(struct proc *, void *, register_t *);
1172int	sys_clock_settime(struct proc *, void *, register_t *);
1173int	sys_clock_getres(struct proc *, void *, register_t *);
1174int	sys_dup2(struct proc *, void *, register_t *);
1175int	sys_nanosleep(struct proc *, void *, register_t *);
1176int	sys_fcntl(struct proc *, void *, register_t *);
1177int	sys_accept4(struct proc *, void *, register_t *);
1178int	sys___thrsleep(struct proc *, void *, register_t *);
1179int	sys_fsync(struct proc *, void *, register_t *);
1180int	sys_setpriority(struct proc *, void *, register_t *);
1181int	sys_socket(struct proc *, void *, register_t *);
1182int	sys_connect(struct proc *, void *, register_t *);
1183int	sys_getdents(struct proc *, void *, register_t *);
1184int	sys_getpriority(struct proc *, void *, register_t *);
1185int	sys_pipe2(struct proc *, void *, register_t *);
1186int	sys_dup3(struct proc *, void *, register_t *);
1187int	sys_sigreturn(struct proc *, void *, register_t *);
1188int	sys_bind(struct proc *, void *, register_t *);
1189int	sys_setsockopt(struct proc *, void *, register_t *);
1190int	sys_listen(struct proc *, void *, register_t *);
1191int	sys_chflagsat(struct proc *, void *, register_t *);
1192int	sys_ppoll(struct proc *, void *, register_t *);
1193int	sys_pselect(struct proc *, void *, register_t *);
1194int	sys_sigsuspend(struct proc *, void *, register_t *);
1195int	sys_getsockopt(struct proc *, void *, register_t *);
1196int	sys_readv(struct proc *, void *, register_t *);
1197int	sys_writev(struct proc *, void *, register_t *);
1198int	sys_fchown(struct proc *, void *, register_t *);
1199int	sys_fchmod(struct proc *, void *, register_t *);
1200int	sys_setreuid(struct proc *, void *, register_t *);
1201int	sys_setregid(struct proc *, void *, register_t *);
1202int	sys_rename(struct proc *, void *, register_t *);
1203int	sys_flock(struct proc *, void *, register_t *);
1204int	sys_mkfifo(struct proc *, void *, register_t *);
1205int	sys_sendto(struct proc *, void *, register_t *);
1206int	sys_shutdown(struct proc *, void *, register_t *);
1207int	sys_socketpair(struct proc *, void *, register_t *);
1208int	sys_mkdir(struct proc *, void *, register_t *);
1209int	sys_rmdir(struct proc *, void *, register_t *);
1210int	sys_adjtime(struct proc *, void *, register_t *);
1211int	sys_setsid(struct proc *, void *, register_t *);
1212int	sys_quotactl(struct proc *, void *, register_t *);
1213#if defined(NFSCLIENT) || defined(NFSSERVER)
1214int	sys_nfssvc(struct proc *, void *, register_t *);
1215#else
1216#endif
1217int	sys_getfh(struct proc *, void *, register_t *);
1218int	sys_sysarch(struct proc *, void *, register_t *);
1219int	sys_pread(struct proc *, void *, register_t *);
1220int	sys_pwrite(struct proc *, void *, register_t *);
1221int	sys_setgid(struct proc *, void *, register_t *);
1222int	sys_setegid(struct proc *, void *, register_t *);
1223int	sys_seteuid(struct proc *, void *, register_t *);
1224int	sys_pathconf(struct proc *, void *, register_t *);
1225int	sys_fpathconf(struct proc *, void *, register_t *);
1226int	sys_swapctl(struct proc *, void *, register_t *);
1227int	sys_getrlimit(struct proc *, void *, register_t *);
1228int	sys_setrlimit(struct proc *, void *, register_t *);
1229int	sys_mmap(struct proc *, void *, register_t *);
1230int	sys_lseek(struct proc *, void *, register_t *);
1231int	sys_truncate(struct proc *, void *, register_t *);
1232int	sys_ftruncate(struct proc *, void *, register_t *);
1233int	sys___sysctl(struct proc *, void *, register_t *);
1234int	sys_mlock(struct proc *, void *, register_t *);
1235int	sys_munlock(struct proc *, void *, register_t *);
1236int	sys_getpgid(struct proc *, void *, register_t *);
1237int	sys_utrace(struct proc *, void *, register_t *);
1238#ifdef SYSVSEM
1239int	sys_semget(struct proc *, void *, register_t *);
1240#else
1241#endif
1242#ifdef SYSVMSG
1243int	sys_msgget(struct proc *, void *, register_t *);
1244int	sys_msgsnd(struct proc *, void *, register_t *);
1245int	sys_msgrcv(struct proc *, void *, register_t *);
1246#else
1247#endif
1248#ifdef SYSVSHM
1249int	sys_shmat(struct proc *, void *, register_t *);
1250int	sys_shmdt(struct proc *, void *, register_t *);
1251#else
1252#endif
1253int	sys_minherit(struct proc *, void *, register_t *);
1254int	sys_poll(struct proc *, void *, register_t *);
1255int	sys_issetugid(struct proc *, void *, register_t *);
1256int	sys_lchown(struct proc *, void *, register_t *);
1257int	sys_getsid(struct proc *, void *, register_t *);
1258int	sys_msync(struct proc *, void *, register_t *);
1259int	sys_pipe(struct proc *, void *, register_t *);
1260int	sys_fhopen(struct proc *, void *, register_t *);
1261int	sys_preadv(struct proc *, void *, register_t *);
1262int	sys_pwritev(struct proc *, void *, register_t *);
1263int	sys_kqueue(struct proc *, void *, register_t *);
1264int	sys_mlockall(struct proc *, void *, register_t *);
1265int	sys_munlockall(struct proc *, void *, register_t *);
1266int	sys_getresuid(struct proc *, void *, register_t *);
1267int	sys_setresuid(struct proc *, void *, register_t *);
1268int	sys_getresgid(struct proc *, void *, register_t *);
1269int	sys_setresgid(struct proc *, void *, register_t *);
1270int	sys_mquery(struct proc *, void *, register_t *);
1271int	sys_closefrom(struct proc *, void *, register_t *);
1272int	sys_sigaltstack(struct proc *, void *, register_t *);
1273#ifdef SYSVSHM
1274int	sys_shmget(struct proc *, void *, register_t *);
1275#else
1276#endif
1277#ifdef SYSVSEM
1278int	sys_semop(struct proc *, void *, register_t *);
1279#else
1280#endif
1281int	sys_fhstat(struct proc *, void *, register_t *);
1282#ifdef SYSVSEM
1283int	sys___semctl(struct proc *, void *, register_t *);
1284#else
1285#endif
1286#ifdef SYSVSHM
1287int	sys_shmctl(struct proc *, void *, register_t *);
1288#else
1289#endif
1290#ifdef SYSVMSG
1291int	sys_msgctl(struct proc *, void *, register_t *);
1292#else
1293#endif
1294int	sys_sched_yield(struct proc *, void *, register_t *);
1295int	sys_getthrid(struct proc *, void *, register_t *);
1296int	sys___thrwakeup(struct proc *, void *, register_t *);
1297int	sys___threxit(struct proc *, void *, register_t *);
1298int	sys___thrsigdivert(struct proc *, void *, register_t *);
1299int	sys___getcwd(struct proc *, void *, register_t *);
1300int	sys_adjfreq(struct proc *, void *, register_t *);
1301int	sys_setrtable(struct proc *, void *, register_t *);
1302int	sys_getrtable(struct proc *, void *, register_t *);
1303int	sys_faccessat(struct proc *, void *, register_t *);
1304int	sys_fchmodat(struct proc *, void *, register_t *);
1305int	sys_fchownat(struct proc *, void *, register_t *);
1306int	sys_linkat(struct proc *, void *, register_t *);
1307int	sys_mkdirat(struct proc *, void *, register_t *);
1308int	sys_mkfifoat(struct proc *, void *, register_t *);
1309int	sys_mknodat(struct proc *, void *, register_t *);
1310int	sys_openat(struct proc *, void *, register_t *);
1311int	sys_readlinkat(struct proc *, void *, register_t *);
1312int	sys_renameat(struct proc *, void *, register_t *);
1313int	sys_symlinkat(struct proc *, void *, register_t *);
1314int	sys_unlinkat(struct proc *, void *, register_t *);
1315int	sys___set_tcb(struct proc *, void *, register_t *);
1316int	sys___get_tcb(struct proc *, void *, register_t *);
1317