1/*	$OpenBSD: syscallargs.h,v 1.281 2024/05/18 05:21:02 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.264 2024/05/18 05:20:22 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_stat_args {
190	syscallarg(const char *) path;
191	syscallarg(struct stat *) ub;
192};
193
194struct sys_lstat_args {
195	syscallarg(const char *) path;
196	syscallarg(struct stat *) ub;
197};
198
199struct sys_dup_args {
200	syscallarg(int) fd;
201};
202
203struct sys_fstatat_args {
204	syscallarg(int) fd;
205	syscallarg(const char *) path;
206	syscallarg(struct stat *) buf;
207	syscallarg(int) flag;
208};
209
210struct sys_profil_args {
211	syscallarg(caddr_t) samples;
212	syscallarg(size_t) size;
213	syscallarg(u_long) offset;
214	syscallarg(u_int) scale;
215};
216
217struct sys_ktrace_args {
218	syscallarg(const char *) fname;
219	syscallarg(int) ops;
220	syscallarg(int) facs;
221	syscallarg(pid_t) pid;
222};
223
224struct sys_sigaction_args {
225	syscallarg(int) signum;
226	syscallarg(const struct sigaction *) nsa;
227	syscallarg(struct sigaction *) osa;
228};
229
230struct sys_sigprocmask_args {
231	syscallarg(int) how;
232	syscallarg(sigset_t) mask;
233};
234
235struct sys_mmap_args {
236	syscallarg(void *) addr;
237	syscallarg(size_t) len;
238	syscallarg(int) prot;
239	syscallarg(int) flags;
240	syscallarg(int) fd;
241	syscallarg(off_t) pos;
242};
243
244struct sys_setlogin_args {
245	syscallarg(const char *) namebuf;
246};
247
248struct sys_acct_args {
249	syscallarg(const char *) path;
250};
251
252struct sys_fstat_args {
253	syscallarg(int) fd;
254	syscallarg(struct stat *) sb;
255};
256
257struct sys_ioctl_args {
258	syscallarg(int) fd;
259	syscallarg(u_long) com;
260	syscallarg(void *) data;
261};
262
263struct sys_reboot_args {
264	syscallarg(int) opt;
265};
266
267struct sys_revoke_args {
268	syscallarg(const char *) path;
269};
270
271struct sys_symlink_args {
272	syscallarg(const char *) path;
273	syscallarg(const char *) link;
274};
275
276struct sys_readlink_args {
277	syscallarg(const char *) path;
278	syscallarg(char *) buf;
279	syscallarg(size_t) count;
280};
281
282struct sys_execve_args {
283	syscallarg(const char *) path;
284	syscallarg(char *const *) argp;
285	syscallarg(char *const *) envp;
286};
287
288struct sys_umask_args {
289	syscallarg(mode_t) newmask;
290};
291
292struct sys_chroot_args {
293	syscallarg(const char *) path;
294};
295
296struct sys_getfsstat_args {
297	syscallarg(struct statfs *) buf;
298	syscallarg(size_t) bufsize;
299	syscallarg(int) flags;
300};
301
302struct sys_statfs_args {
303	syscallarg(const char *) path;
304	syscallarg(struct statfs *) buf;
305};
306
307struct sys_fstatfs_args {
308	syscallarg(int) fd;
309	syscallarg(struct statfs *) buf;
310};
311
312struct sys_fhstatfs_args {
313	syscallarg(const fhandle_t *) fhp;
314	syscallarg(struct statfs *) buf;
315};
316
317struct sys_gettimeofday_args {
318	syscallarg(struct timeval *) tp;
319	syscallarg(struct timezone *) tzp;
320};
321
322struct sys_settimeofday_args {
323	syscallarg(const struct timeval *) tv;
324	syscallarg(const struct timezone *) tzp;
325};
326
327struct sys_setitimer_args {
328	syscallarg(int) which;
329	syscallarg(const struct itimerval *) itv;
330	syscallarg(struct itimerval *) oitv;
331};
332
333struct sys_getitimer_args {
334	syscallarg(int) which;
335	syscallarg(struct itimerval *) itv;
336};
337
338struct sys_select_args {
339	syscallarg(int) nd;
340	syscallarg(fd_set *) in;
341	syscallarg(fd_set *) ou;
342	syscallarg(fd_set *) ex;
343	syscallarg(struct timeval *) tv;
344};
345
346struct sys_kevent_args {
347	syscallarg(int) fd;
348	syscallarg(const struct kevent *) changelist;
349	syscallarg(int) nchanges;
350	syscallarg(struct kevent *) eventlist;
351	syscallarg(int) nevents;
352	syscallarg(const struct timespec *) timeout;
353};
354
355struct sys_munmap_args {
356	syscallarg(void *) addr;
357	syscallarg(size_t) len;
358};
359
360struct sys_mprotect_args {
361	syscallarg(void *) addr;
362	syscallarg(size_t) len;
363	syscallarg(int) prot;
364};
365
366struct sys_madvise_args {
367	syscallarg(void *) addr;
368	syscallarg(size_t) len;
369	syscallarg(int) behav;
370};
371
372struct sys_utimes_args {
373	syscallarg(const char *) path;
374	syscallarg(const struct timeval *) tptr;
375};
376
377struct sys_futimes_args {
378	syscallarg(int) fd;
379	syscallarg(const struct timeval *) tptr;
380};
381
382struct sys_mquery_args {
383	syscallarg(void *) addr;
384	syscallarg(size_t) len;
385	syscallarg(int) prot;
386	syscallarg(int) flags;
387	syscallarg(int) fd;
388	syscallarg(off_t) pos;
389};
390
391struct sys_getgroups_args {
392	syscallarg(int) gidsetsize;
393	syscallarg(gid_t *) gidset;
394};
395
396struct sys_setgroups_args {
397	syscallarg(int) gidsetsize;
398	syscallarg(const gid_t *) gidset;
399};
400
401struct sys_setpgid_args {
402	syscallarg(pid_t) pid;
403	syscallarg(pid_t) pgid;
404};
405
406struct sys_futex_args {
407	syscallarg(uint32_t *) f;
408	syscallarg(int) op;
409	syscallarg(int) val;
410	syscallarg(const struct timespec *) timeout;
411	syscallarg(uint32_t *) g;
412};
413
414struct sys_utimensat_args {
415	syscallarg(int) fd;
416	syscallarg(const char *) path;
417	syscallarg(const struct timespec *) times;
418	syscallarg(int) flag;
419};
420
421struct sys_futimens_args {
422	syscallarg(int) fd;
423	syscallarg(const struct timespec *) times;
424};
425
426struct sys_kbind_args {
427	syscallarg(const struct __kbind *) param;
428	syscallarg(size_t) psize;
429	syscallarg(int64_t) proc_cookie;
430};
431
432struct sys_clock_gettime_args {
433	syscallarg(clockid_t) clock_id;
434	syscallarg(struct timespec *) tp;
435};
436
437struct sys_clock_settime_args {
438	syscallarg(clockid_t) clock_id;
439	syscallarg(const struct timespec *) tp;
440};
441
442struct sys_clock_getres_args {
443	syscallarg(clockid_t) clock_id;
444	syscallarg(struct timespec *) tp;
445};
446
447struct sys_dup2_args {
448	syscallarg(int) from;
449	syscallarg(int) to;
450};
451
452struct sys_nanosleep_args {
453	syscallarg(const struct timespec *) rqtp;
454	syscallarg(struct timespec *) rmtp;
455};
456
457struct sys_fcntl_args {
458	syscallarg(int) fd;
459	syscallarg(int) cmd;
460	syscallarg(void *) arg;
461};
462
463struct sys_accept4_args {
464	syscallarg(int) s;
465	syscallarg(struct sockaddr *) name;
466	syscallarg(socklen_t *) anamelen;
467	syscallarg(int) flags;
468};
469
470struct sys___thrsleep_args {
471	syscallarg(const volatile void *) ident;
472	syscallarg(clockid_t) clock_id;
473	syscallarg(const struct timespec *) tp;
474	syscallarg(void *) lock;
475	syscallarg(const int *) abort;
476};
477
478struct sys_fsync_args {
479	syscallarg(int) fd;
480};
481
482struct sys_setpriority_args {
483	syscallarg(int) which;
484	syscallarg(id_t) who;
485	syscallarg(int) prio;
486};
487
488struct sys_socket_args {
489	syscallarg(int) domain;
490	syscallarg(int) type;
491	syscallarg(int) protocol;
492};
493
494struct sys_connect_args {
495	syscallarg(int) s;
496	syscallarg(const struct sockaddr *) name;
497	syscallarg(socklen_t) namelen;
498};
499
500struct sys_getdents_args {
501	syscallarg(int) fd;
502	syscallarg(void *) buf;
503	syscallarg(size_t) buflen;
504};
505
506struct sys_getpriority_args {
507	syscallarg(int) which;
508	syscallarg(id_t) who;
509};
510
511struct sys_pipe2_args {
512	syscallarg(int *) fdp;
513	syscallarg(int) flags;
514};
515
516struct sys_dup3_args {
517	syscallarg(int) from;
518	syscallarg(int) to;
519	syscallarg(int) flags;
520};
521
522struct sys_sigreturn_args {
523	syscallarg(struct sigcontext *) sigcntxp;
524};
525
526struct sys_bind_args {
527	syscallarg(int) s;
528	syscallarg(const struct sockaddr *) name;
529	syscallarg(socklen_t) namelen;
530};
531
532struct sys_setsockopt_args {
533	syscallarg(int) s;
534	syscallarg(int) level;
535	syscallarg(int) name;
536	syscallarg(const void *) val;
537	syscallarg(socklen_t) valsize;
538};
539
540struct sys_listen_args {
541	syscallarg(int) s;
542	syscallarg(int) backlog;
543};
544
545struct sys_chflagsat_args {
546	syscallarg(int) fd;
547	syscallarg(const char *) path;
548	syscallarg(u_int) flags;
549	syscallarg(int) atflags;
550};
551
552struct sys_pledge_args {
553	syscallarg(const char *) promises;
554	syscallarg(const char *) execpromises;
555};
556
557struct sys_ppoll_args {
558	syscallarg(struct pollfd *) fds;
559	syscallarg(u_int) nfds;
560	syscallarg(const struct timespec *) ts;
561	syscallarg(const sigset_t *) mask;
562};
563
564struct sys_pselect_args {
565	syscallarg(int) nd;
566	syscallarg(fd_set *) in;
567	syscallarg(fd_set *) ou;
568	syscallarg(fd_set *) ex;
569	syscallarg(const struct timespec *) ts;
570	syscallarg(const sigset_t *) mask;
571};
572
573struct sys_sigsuspend_args {
574	syscallarg(int) mask;
575};
576
577struct sys_sendsyslog_args {
578	syscallarg(const char *) buf;
579	syscallarg(size_t) nbyte;
580	syscallarg(int) flags;
581};
582
583struct sys_unveil_args {
584	syscallarg(const char *) path;
585	syscallarg(const char *) permissions;
586};
587
588struct sys___realpath_args {
589	syscallarg(const char *) pathname;
590	syscallarg(char *) resolved;
591};
592
593struct sys_recvmmsg_args {
594	syscallarg(int) s;
595	syscallarg(struct mmsghdr *) mmsg;
596	syscallarg(unsigned int) vlen;
597	syscallarg(int) flags;
598	syscallarg(struct timespec *) timeout;
599};
600
601struct sys_sendmmsg_args {
602	syscallarg(int) s;
603	syscallarg(struct mmsghdr *) mmsg;
604	syscallarg(unsigned int) vlen;
605	syscallarg(int) flags;
606};
607
608struct sys_getsockopt_args {
609	syscallarg(int) s;
610	syscallarg(int) level;
611	syscallarg(int) name;
612	syscallarg(void *) val;
613	syscallarg(socklen_t *) avalsize;
614};
615
616struct sys_thrkill_args {
617	syscallarg(pid_t) tid;
618	syscallarg(int) signum;
619	syscallarg(void *) tcb;
620};
621
622struct sys_readv_args {
623	syscallarg(int) fd;
624	syscallarg(const struct iovec *) iovp;
625	syscallarg(int) iovcnt;
626};
627
628struct sys_writev_args {
629	syscallarg(int) fd;
630	syscallarg(const struct iovec *) iovp;
631	syscallarg(int) iovcnt;
632};
633
634struct sys_kill_args {
635	syscallarg(int) pid;
636	syscallarg(int) signum;
637};
638
639struct sys_fchown_args {
640	syscallarg(int) fd;
641	syscallarg(uid_t) uid;
642	syscallarg(gid_t) gid;
643};
644
645struct sys_fchmod_args {
646	syscallarg(int) fd;
647	syscallarg(mode_t) mode;
648};
649
650struct sys_setreuid_args {
651	syscallarg(uid_t) ruid;
652	syscallarg(uid_t) euid;
653};
654
655struct sys_setregid_args {
656	syscallarg(gid_t) rgid;
657	syscallarg(gid_t) egid;
658};
659
660struct sys_rename_args {
661	syscallarg(const char *) from;
662	syscallarg(const char *) to;
663};
664
665struct sys_flock_args {
666	syscallarg(int) fd;
667	syscallarg(int) how;
668};
669
670struct sys_mkfifo_args {
671	syscallarg(const char *) path;
672	syscallarg(mode_t) mode;
673};
674
675struct sys_sendto_args {
676	syscallarg(int) s;
677	syscallarg(const void *) buf;
678	syscallarg(size_t) len;
679	syscallarg(int) flags;
680	syscallarg(const struct sockaddr *) to;
681	syscallarg(socklen_t) tolen;
682};
683
684struct sys_shutdown_args {
685	syscallarg(int) s;
686	syscallarg(int) how;
687};
688
689struct sys_socketpair_args {
690	syscallarg(int) domain;
691	syscallarg(int) type;
692	syscallarg(int) protocol;
693	syscallarg(int *) rsv;
694};
695
696struct sys_mkdir_args {
697	syscallarg(const char *) path;
698	syscallarg(mode_t) mode;
699};
700
701struct sys_rmdir_args {
702	syscallarg(const char *) path;
703};
704
705struct sys_adjtime_args {
706	syscallarg(const struct timeval *) delta;
707	syscallarg(struct timeval *) olddelta;
708};
709
710struct sys_getlogin_r_args {
711	syscallarg(char *) namebuf;
712	syscallarg(size_t) namelen;
713};
714
715struct sys_getthrname_args {
716	syscallarg(pid_t) tid;
717	syscallarg(char *) name;
718	syscallarg(size_t) len;
719};
720
721struct sys_setthrname_args {
722	syscallarg(pid_t) tid;
723	syscallarg(const char *) name;
724};
725
726struct sys_quotactl_args {
727	syscallarg(const char *) path;
728	syscallarg(int) cmd;
729	syscallarg(int) uid;
730	syscallarg(char *) arg;
731};
732
733struct sys_ypconnect_args {
734	syscallarg(int) type;
735};
736
737struct sys_nfssvc_args {
738	syscallarg(int) flag;
739	syscallarg(void *) argp;
740};
741
742struct sys_pinsyscalls_args {
743	syscallarg(void *) base;
744	syscallarg(size_t) len;
745	syscallarg(u_int *) pins;
746	syscallarg(int) npins;
747};
748
749struct sys_mimmutable_args {
750	syscallarg(void *) addr;
751	syscallarg(size_t) len;
752};
753
754struct sys_waitid_args {
755	syscallarg(int) idtype;
756	syscallarg(id_t) id;
757	syscallarg(siginfo_t *) info;
758	syscallarg(int) options;
759};
760
761struct sys_getfh_args {
762	syscallarg(const char *) fname;
763	syscallarg(fhandle_t *) fhp;
764};
765
766struct sys___tmpfd_args {
767	syscallarg(int) flags;
768};
769
770struct sys_sysarch_args {
771	syscallarg(int) op;
772	syscallarg(void *) parms;
773};
774
775struct sys_lseek_args {
776	syscallarg(int) fd;
777	syscallarg(off_t) offset;
778	syscallarg(int) whence;
779};
780
781struct sys_truncate_args {
782	syscallarg(const char *) path;
783	syscallarg(off_t) length;
784};
785
786struct sys_ftruncate_args {
787	syscallarg(int) fd;
788	syscallarg(off_t) length;
789};
790
791struct sys_pread_args {
792	syscallarg(int) fd;
793	syscallarg(void *) buf;
794	syscallarg(size_t) nbyte;
795	syscallarg(off_t) offset;
796};
797
798struct sys_pwrite_args {
799	syscallarg(int) fd;
800	syscallarg(const void *) buf;
801	syscallarg(size_t) nbyte;
802	syscallarg(off_t) offset;
803};
804
805struct sys_preadv_args {
806	syscallarg(int) fd;
807	syscallarg(const struct iovec *) iovp;
808	syscallarg(int) iovcnt;
809	syscallarg(off_t) offset;
810};
811
812struct sys_pwritev_args {
813	syscallarg(int) fd;
814	syscallarg(const struct iovec *) iovp;
815	syscallarg(int) iovcnt;
816	syscallarg(off_t) offset;
817};
818
819struct sys_setgid_args {
820	syscallarg(gid_t) gid;
821};
822
823struct sys_setegid_args {
824	syscallarg(gid_t) egid;
825};
826
827struct sys_seteuid_args {
828	syscallarg(uid_t) euid;
829};
830
831struct sys_pathconfat_args {
832	syscallarg(int) fd;
833	syscallarg(const char *) path;
834	syscallarg(int) name;
835	syscallarg(int) flag;
836};
837
838struct sys_pathconf_args {
839	syscallarg(const char *) path;
840	syscallarg(int) name;
841};
842
843struct sys_fpathconf_args {
844	syscallarg(int) fd;
845	syscallarg(int) name;
846};
847
848struct sys_swapctl_args {
849	syscallarg(int) cmd;
850	syscallarg(const void *) arg;
851	syscallarg(int) misc;
852};
853
854struct sys_getrlimit_args {
855	syscallarg(int) which;
856	syscallarg(struct rlimit *) rlp;
857};
858
859struct sys_setrlimit_args {
860	syscallarg(int) which;
861	syscallarg(const struct rlimit *) rlp;
862};
863
864struct sys_sysctl_args {
865	syscallarg(const int *) name;
866	syscallarg(u_int) namelen;
867	syscallarg(void *) old;
868	syscallarg(size_t *) oldlenp;
869	syscallarg(void *) new;
870	syscallarg(size_t) newlen;
871};
872
873struct sys_mlock_args {
874	syscallarg(const void *) addr;
875	syscallarg(size_t) len;
876};
877
878struct sys_munlock_args {
879	syscallarg(const void *) addr;
880	syscallarg(size_t) len;
881};
882
883struct sys_getpgid_args {
884	syscallarg(pid_t) pid;
885};
886
887struct sys_utrace_args {
888	syscallarg(const char *) label;
889	syscallarg(const void *) addr;
890	syscallarg(size_t) len;
891};
892
893struct sys_semget_args {
894	syscallarg(key_t) key;
895	syscallarg(int) nsems;
896	syscallarg(int) semflg;
897};
898
899struct sys_msgget_args {
900	syscallarg(key_t) key;
901	syscallarg(int) msgflg;
902};
903
904struct sys_msgsnd_args {
905	syscallarg(int) msqid;
906	syscallarg(const void *) msgp;
907	syscallarg(size_t) msgsz;
908	syscallarg(int) msgflg;
909};
910
911struct sys_msgrcv_args {
912	syscallarg(int) msqid;
913	syscallarg(void *) msgp;
914	syscallarg(size_t) msgsz;
915	syscallarg(long) msgtyp;
916	syscallarg(int) msgflg;
917};
918
919struct sys_shmat_args {
920	syscallarg(int) shmid;
921	syscallarg(const void *) shmaddr;
922	syscallarg(int) shmflg;
923};
924
925struct sys_shmdt_args {
926	syscallarg(const void *) shmaddr;
927};
928
929struct sys_minherit_args {
930	syscallarg(void *) addr;
931	syscallarg(size_t) len;
932	syscallarg(int) inherit;
933};
934
935struct sys_poll_args {
936	syscallarg(struct pollfd *) fds;
937	syscallarg(u_int) nfds;
938	syscallarg(int) timeout;
939};
940
941struct sys_lchown_args {
942	syscallarg(const char *) path;
943	syscallarg(uid_t) uid;
944	syscallarg(gid_t) gid;
945};
946
947struct sys_getsid_args {
948	syscallarg(pid_t) pid;
949};
950
951struct sys_msync_args {
952	syscallarg(void *) addr;
953	syscallarg(size_t) len;
954	syscallarg(int) flags;
955};
956
957struct sys_pipe_args {
958	syscallarg(int *) fdp;
959};
960
961struct sys_fhopen_args {
962	syscallarg(const fhandle_t *) fhp;
963	syscallarg(int) flags;
964};
965
966struct sys_kqueue1_args {
967	syscallarg(int) flags;
968};
969
970struct sys_mlockall_args {
971	syscallarg(int) flags;
972};
973
974struct sys_getresuid_args {
975	syscallarg(uid_t *) ruid;
976	syscallarg(uid_t *) euid;
977	syscallarg(uid_t *) suid;
978};
979
980struct sys_setresuid_args {
981	syscallarg(uid_t) ruid;
982	syscallarg(uid_t) euid;
983	syscallarg(uid_t) suid;
984};
985
986struct sys_getresgid_args {
987	syscallarg(gid_t *) rgid;
988	syscallarg(gid_t *) egid;
989	syscallarg(gid_t *) sgid;
990};
991
992struct sys_setresgid_args {
993	syscallarg(gid_t) rgid;
994	syscallarg(gid_t) egid;
995	syscallarg(gid_t) sgid;
996};
997
998struct sys_closefrom_args {
999	syscallarg(int) fd;
1000};
1001
1002struct sys_sigaltstack_args {
1003	syscallarg(const struct sigaltstack *) nss;
1004	syscallarg(struct sigaltstack *) oss;
1005};
1006
1007struct sys_shmget_args {
1008	syscallarg(key_t) key;
1009	syscallarg(size_t) size;
1010	syscallarg(int) shmflg;
1011};
1012
1013struct sys_semop_args {
1014	syscallarg(int) semid;
1015	syscallarg(struct sembuf *) sops;
1016	syscallarg(size_t) nsops;
1017};
1018
1019struct sys_fhstat_args {
1020	syscallarg(const fhandle_t *) fhp;
1021	syscallarg(struct stat *) sb;
1022};
1023
1024struct sys___semctl_args {
1025	syscallarg(int) semid;
1026	syscallarg(int) semnum;
1027	syscallarg(int) cmd;
1028	syscallarg(union semun *) arg;
1029};
1030
1031struct sys_shmctl_args {
1032	syscallarg(int) shmid;
1033	syscallarg(int) cmd;
1034	syscallarg(struct shmid_ds *) buf;
1035};
1036
1037struct sys_msgctl_args {
1038	syscallarg(int) msqid;
1039	syscallarg(int) cmd;
1040	syscallarg(struct msqid_ds *) buf;
1041};
1042
1043struct sys___thrwakeup_args {
1044	syscallarg(const volatile void *) ident;
1045	syscallarg(int) n;
1046};
1047
1048struct sys___threxit_args {
1049	syscallarg(pid_t *) notdead;
1050};
1051
1052struct sys___thrsigdivert_args {
1053	syscallarg(sigset_t) sigmask;
1054	syscallarg(siginfo_t *) info;
1055	syscallarg(const struct timespec *) timeout;
1056};
1057
1058struct sys___getcwd_args {
1059	syscallarg(char *) buf;
1060	syscallarg(size_t) len;
1061};
1062
1063struct sys_adjfreq_args {
1064	syscallarg(const int64_t *) freq;
1065	syscallarg(int64_t *) oldfreq;
1066};
1067
1068struct sys_setrtable_args {
1069	syscallarg(int) rtableid;
1070};
1071
1072struct sys_faccessat_args {
1073	syscallarg(int) fd;
1074	syscallarg(const char *) path;
1075	syscallarg(int) amode;
1076	syscallarg(int) flag;
1077};
1078
1079struct sys_fchmodat_args {
1080	syscallarg(int) fd;
1081	syscallarg(const char *) path;
1082	syscallarg(mode_t) mode;
1083	syscallarg(int) flag;
1084};
1085
1086struct sys_fchownat_args {
1087	syscallarg(int) fd;
1088	syscallarg(const char *) path;
1089	syscallarg(uid_t) uid;
1090	syscallarg(gid_t) gid;
1091	syscallarg(int) flag;
1092};
1093
1094struct sys_linkat_args {
1095	syscallarg(int) fd1;
1096	syscallarg(const char *) path1;
1097	syscallarg(int) fd2;
1098	syscallarg(const char *) path2;
1099	syscallarg(int) flag;
1100};
1101
1102struct sys_mkdirat_args {
1103	syscallarg(int) fd;
1104	syscallarg(const char *) path;
1105	syscallarg(mode_t) mode;
1106};
1107
1108struct sys_mkfifoat_args {
1109	syscallarg(int) fd;
1110	syscallarg(const char *) path;
1111	syscallarg(mode_t) mode;
1112};
1113
1114struct sys_mknodat_args {
1115	syscallarg(int) fd;
1116	syscallarg(const char *) path;
1117	syscallarg(mode_t) mode;
1118	syscallarg(dev_t) dev;
1119};
1120
1121struct sys_openat_args {
1122	syscallarg(int) fd;
1123	syscallarg(const char *) path;
1124	syscallarg(int) flags;
1125	syscallarg(mode_t) mode;
1126};
1127
1128struct sys_readlinkat_args {
1129	syscallarg(int) fd;
1130	syscallarg(const char *) path;
1131	syscallarg(char *) buf;
1132	syscallarg(size_t) count;
1133};
1134
1135struct sys_renameat_args {
1136	syscallarg(int) fromfd;
1137	syscallarg(const char *) from;
1138	syscallarg(int) tofd;
1139	syscallarg(const char *) to;
1140};
1141
1142struct sys_symlinkat_args {
1143	syscallarg(const char *) path;
1144	syscallarg(int) fd;
1145	syscallarg(const char *) link;
1146};
1147
1148struct sys_unlinkat_args {
1149	syscallarg(int) fd;
1150	syscallarg(const char *) path;
1151	syscallarg(int) flag;
1152};
1153
1154struct sys___set_tcb_args {
1155	syscallarg(void *) tcb;
1156};
1157
1158/*
1159 * System call prototypes.
1160 */
1161
1162int	sys_exit(struct proc *, void *, register_t *);
1163int	sys_fork(struct proc *, void *, register_t *);
1164int	sys_read(struct proc *, void *, register_t *);
1165int	sys_write(struct proc *, void *, register_t *);
1166int	sys_open(struct proc *, void *, register_t *);
1167int	sys_close(struct proc *, void *, register_t *);
1168int	sys_getentropy(struct proc *, void *, register_t *);
1169int	sys___tfork(struct proc *, void *, register_t *);
1170int	sys_link(struct proc *, void *, register_t *);
1171int	sys_unlink(struct proc *, void *, register_t *);
1172int	sys_wait4(struct proc *, void *, register_t *);
1173int	sys_chdir(struct proc *, void *, register_t *);
1174int	sys_fchdir(struct proc *, void *, register_t *);
1175int	sys_mknod(struct proc *, void *, register_t *);
1176int	sys_chmod(struct proc *, void *, register_t *);
1177int	sys_chown(struct proc *, void *, register_t *);
1178int	sys_obreak(struct proc *, void *, register_t *);
1179int	sys_getdtablecount(struct proc *, void *, register_t *);
1180int	sys_getrusage(struct proc *, void *, register_t *);
1181int	sys_getpid(struct proc *, void *, register_t *);
1182int	sys_mount(struct proc *, void *, register_t *);
1183int	sys_unmount(struct proc *, void *, register_t *);
1184int	sys_setuid(struct proc *, void *, register_t *);
1185int	sys_getuid(struct proc *, void *, register_t *);
1186int	sys_geteuid(struct proc *, void *, register_t *);
1187#ifdef PTRACE
1188int	sys_ptrace(struct proc *, void *, register_t *);
1189#else
1190#endif
1191int	sys_recvmsg(struct proc *, void *, register_t *);
1192int	sys_sendmsg(struct proc *, void *, register_t *);
1193int	sys_recvfrom(struct proc *, void *, register_t *);
1194int	sys_accept(struct proc *, void *, register_t *);
1195int	sys_getpeername(struct proc *, void *, register_t *);
1196int	sys_getsockname(struct proc *, void *, register_t *);
1197int	sys_access(struct proc *, void *, register_t *);
1198int	sys_chflags(struct proc *, void *, register_t *);
1199int	sys_fchflags(struct proc *, void *, register_t *);
1200int	sys_sync(struct proc *, void *, register_t *);
1201int	sys_stat(struct proc *, void *, register_t *);
1202int	sys_getppid(struct proc *, void *, register_t *);
1203int	sys_lstat(struct proc *, void *, register_t *);
1204int	sys_dup(struct proc *, void *, register_t *);
1205int	sys_fstatat(struct proc *, void *, register_t *);
1206int	sys_getegid(struct proc *, void *, register_t *);
1207int	sys_profil(struct proc *, void *, register_t *);
1208#ifdef KTRACE
1209int	sys_ktrace(struct proc *, void *, register_t *);
1210#else
1211#endif
1212int	sys_sigaction(struct proc *, void *, register_t *);
1213int	sys_getgid(struct proc *, void *, register_t *);
1214int	sys_sigprocmask(struct proc *, void *, register_t *);
1215int	sys_mmap(struct proc *, void *, register_t *);
1216int	sys_setlogin(struct proc *, void *, register_t *);
1217#ifdef ACCOUNTING
1218int	sys_acct(struct proc *, void *, register_t *);
1219#else
1220#endif
1221int	sys_sigpending(struct proc *, void *, register_t *);
1222int	sys_fstat(struct proc *, void *, register_t *);
1223int	sys_ioctl(struct proc *, void *, register_t *);
1224int	sys_reboot(struct proc *, void *, register_t *);
1225int	sys_revoke(struct proc *, void *, register_t *);
1226int	sys_symlink(struct proc *, void *, register_t *);
1227int	sys_readlink(struct proc *, void *, register_t *);
1228int	sys_execve(struct proc *, void *, register_t *);
1229int	sys_umask(struct proc *, void *, register_t *);
1230int	sys_chroot(struct proc *, void *, register_t *);
1231int	sys_getfsstat(struct proc *, void *, register_t *);
1232int	sys_statfs(struct proc *, void *, register_t *);
1233int	sys_fstatfs(struct proc *, void *, register_t *);
1234int	sys_fhstatfs(struct proc *, void *, register_t *);
1235int	sys_vfork(struct proc *, void *, register_t *);
1236int	sys_gettimeofday(struct proc *, void *, register_t *);
1237int	sys_settimeofday(struct proc *, void *, register_t *);
1238int	sys_setitimer(struct proc *, void *, register_t *);
1239int	sys_getitimer(struct proc *, void *, register_t *);
1240int	sys_select(struct proc *, void *, register_t *);
1241int	sys_kevent(struct proc *, void *, register_t *);
1242int	sys_munmap(struct proc *, void *, register_t *);
1243int	sys_mprotect(struct proc *, void *, register_t *);
1244int	sys_madvise(struct proc *, void *, register_t *);
1245int	sys_utimes(struct proc *, void *, register_t *);
1246int	sys_futimes(struct proc *, void *, register_t *);
1247int	sys_mquery(struct proc *, void *, register_t *);
1248int	sys_getgroups(struct proc *, void *, register_t *);
1249int	sys_setgroups(struct proc *, void *, register_t *);
1250int	sys_getpgrp(struct proc *, void *, register_t *);
1251int	sys_setpgid(struct proc *, void *, register_t *);
1252int	sys_futex(struct proc *, void *, register_t *);
1253int	sys_utimensat(struct proc *, void *, register_t *);
1254int	sys_futimens(struct proc *, void *, register_t *);
1255int	sys_kbind(struct proc *, void *, register_t *);
1256int	sys_clock_gettime(struct proc *, void *, register_t *);
1257int	sys_clock_settime(struct proc *, void *, register_t *);
1258int	sys_clock_getres(struct proc *, void *, register_t *);
1259int	sys_dup2(struct proc *, void *, register_t *);
1260int	sys_nanosleep(struct proc *, void *, register_t *);
1261int	sys_fcntl(struct proc *, void *, register_t *);
1262int	sys_accept4(struct proc *, void *, register_t *);
1263int	sys___thrsleep(struct proc *, void *, register_t *);
1264int	sys_fsync(struct proc *, void *, register_t *);
1265int	sys_setpriority(struct proc *, void *, register_t *);
1266int	sys_socket(struct proc *, void *, register_t *);
1267int	sys_connect(struct proc *, void *, register_t *);
1268int	sys_getdents(struct proc *, void *, register_t *);
1269int	sys_getpriority(struct proc *, void *, register_t *);
1270int	sys_pipe2(struct proc *, void *, register_t *);
1271int	sys_dup3(struct proc *, void *, register_t *);
1272int	sys_sigreturn(struct proc *, void *, register_t *);
1273int	sys_bind(struct proc *, void *, register_t *);
1274int	sys_setsockopt(struct proc *, void *, register_t *);
1275int	sys_listen(struct proc *, void *, register_t *);
1276int	sys_chflagsat(struct proc *, void *, register_t *);
1277int	sys_pledge(struct proc *, void *, register_t *);
1278int	sys_ppoll(struct proc *, void *, register_t *);
1279int	sys_pselect(struct proc *, void *, register_t *);
1280int	sys_sigsuspend(struct proc *, void *, register_t *);
1281int	sys_sendsyslog(struct proc *, void *, register_t *);
1282int	sys_unveil(struct proc *, void *, register_t *);
1283int	sys___realpath(struct proc *, void *, register_t *);
1284int	sys_recvmmsg(struct proc *, void *, register_t *);
1285int	sys_sendmmsg(struct proc *, void *, register_t *);
1286int	sys_getsockopt(struct proc *, void *, register_t *);
1287int	sys_thrkill(struct proc *, void *, register_t *);
1288int	sys_readv(struct proc *, void *, register_t *);
1289int	sys_writev(struct proc *, void *, register_t *);
1290int	sys_kill(struct proc *, void *, register_t *);
1291int	sys_fchown(struct proc *, void *, register_t *);
1292int	sys_fchmod(struct proc *, void *, register_t *);
1293int	sys_setreuid(struct proc *, void *, register_t *);
1294int	sys_setregid(struct proc *, void *, register_t *);
1295int	sys_rename(struct proc *, void *, register_t *);
1296int	sys_flock(struct proc *, void *, register_t *);
1297int	sys_mkfifo(struct proc *, void *, register_t *);
1298int	sys_sendto(struct proc *, void *, register_t *);
1299int	sys_shutdown(struct proc *, void *, register_t *);
1300int	sys_socketpair(struct proc *, void *, register_t *);
1301int	sys_mkdir(struct proc *, void *, register_t *);
1302int	sys_rmdir(struct proc *, void *, register_t *);
1303int	sys_adjtime(struct proc *, void *, register_t *);
1304int	sys_getlogin_r(struct proc *, void *, register_t *);
1305int	sys_getthrname(struct proc *, void *, register_t *);
1306int	sys_setthrname(struct proc *, void *, register_t *);
1307int	sys_setsid(struct proc *, void *, register_t *);
1308int	sys_quotactl(struct proc *, void *, register_t *);
1309int	sys_ypconnect(struct proc *, void *, register_t *);
1310#if defined(NFSCLIENT) || defined(NFSSERVER)
1311int	sys_nfssvc(struct proc *, void *, register_t *);
1312#else
1313#endif
1314int	sys_pinsyscalls(struct proc *, void *, register_t *);
1315int	sys_mimmutable(struct proc *, void *, register_t *);
1316int	sys_waitid(struct proc *, void *, register_t *);
1317int	sys_getfh(struct proc *, void *, register_t *);
1318int	sys___tmpfd(struct proc *, void *, register_t *);
1319int	sys_sysarch(struct proc *, void *, register_t *);
1320int	sys_lseek(struct proc *, void *, register_t *);
1321int	sys_truncate(struct proc *, void *, register_t *);
1322int	sys_ftruncate(struct proc *, void *, register_t *);
1323int	sys_pread(struct proc *, void *, register_t *);
1324int	sys_pwrite(struct proc *, void *, register_t *);
1325int	sys_preadv(struct proc *, void *, register_t *);
1326int	sys_pwritev(struct proc *, void *, register_t *);
1327int	sys_setgid(struct proc *, void *, register_t *);
1328int	sys_setegid(struct proc *, void *, register_t *);
1329int	sys_seteuid(struct proc *, void *, register_t *);
1330int	sys_pathconfat(struct proc *, void *, register_t *);
1331int	sys_pathconf(struct proc *, void *, register_t *);
1332int	sys_fpathconf(struct proc *, void *, register_t *);
1333int	sys_swapctl(struct proc *, void *, register_t *);
1334int	sys_getrlimit(struct proc *, void *, register_t *);
1335int	sys_setrlimit(struct proc *, void *, register_t *);
1336int	sys_sysctl(struct proc *, void *, register_t *);
1337int	sys_mlock(struct proc *, void *, register_t *);
1338int	sys_munlock(struct proc *, void *, register_t *);
1339int	sys_getpgid(struct proc *, void *, register_t *);
1340int	sys_utrace(struct proc *, void *, register_t *);
1341#ifdef SYSVSEM
1342int	sys_semget(struct proc *, void *, register_t *);
1343#else
1344#endif
1345#ifdef SYSVMSG
1346int	sys_msgget(struct proc *, void *, register_t *);
1347int	sys_msgsnd(struct proc *, void *, register_t *);
1348int	sys_msgrcv(struct proc *, void *, register_t *);
1349#else
1350#endif
1351#ifdef SYSVSHM
1352int	sys_shmat(struct proc *, void *, register_t *);
1353int	sys_shmdt(struct proc *, void *, register_t *);
1354#else
1355#endif
1356int	sys_minherit(struct proc *, void *, register_t *);
1357int	sys_poll(struct proc *, void *, register_t *);
1358int	sys_issetugid(struct proc *, void *, register_t *);
1359int	sys_lchown(struct proc *, void *, register_t *);
1360int	sys_getsid(struct proc *, void *, register_t *);
1361int	sys_msync(struct proc *, void *, register_t *);
1362int	sys_pipe(struct proc *, void *, register_t *);
1363int	sys_fhopen(struct proc *, void *, register_t *);
1364int	sys_kqueue(struct proc *, void *, register_t *);
1365int	sys_kqueue1(struct proc *, void *, register_t *);
1366int	sys_mlockall(struct proc *, void *, register_t *);
1367int	sys_munlockall(struct proc *, void *, register_t *);
1368int	sys_getresuid(struct proc *, void *, register_t *);
1369int	sys_setresuid(struct proc *, void *, register_t *);
1370int	sys_getresgid(struct proc *, void *, register_t *);
1371int	sys_setresgid(struct proc *, void *, register_t *);
1372int	sys_closefrom(struct proc *, void *, register_t *);
1373int	sys_sigaltstack(struct proc *, void *, register_t *);
1374#ifdef SYSVSHM
1375int	sys_shmget(struct proc *, void *, register_t *);
1376#else
1377#endif
1378#ifdef SYSVSEM
1379int	sys_semop(struct proc *, void *, register_t *);
1380#else
1381#endif
1382int	sys_fhstat(struct proc *, void *, register_t *);
1383#ifdef SYSVSEM
1384int	sys___semctl(struct proc *, void *, register_t *);
1385#else
1386#endif
1387#ifdef SYSVSHM
1388int	sys_shmctl(struct proc *, void *, register_t *);
1389#else
1390#endif
1391#ifdef SYSVMSG
1392int	sys_msgctl(struct proc *, void *, register_t *);
1393#else
1394#endif
1395int	sys_sched_yield(struct proc *, void *, register_t *);
1396int	sys_getthrid(struct proc *, void *, register_t *);
1397int	sys___thrwakeup(struct proc *, void *, register_t *);
1398int	sys___threxit(struct proc *, void *, register_t *);
1399int	sys___thrsigdivert(struct proc *, void *, register_t *);
1400int	sys___getcwd(struct proc *, void *, register_t *);
1401int	sys_adjfreq(struct proc *, void *, register_t *);
1402int	sys_setrtable(struct proc *, void *, register_t *);
1403int	sys_getrtable(struct proc *, void *, register_t *);
1404int	sys_faccessat(struct proc *, void *, register_t *);
1405int	sys_fchmodat(struct proc *, void *, register_t *);
1406int	sys_fchownat(struct proc *, void *, register_t *);
1407int	sys_linkat(struct proc *, void *, register_t *);
1408int	sys_mkdirat(struct proc *, void *, register_t *);
1409int	sys_mkfifoat(struct proc *, void *, register_t *);
1410int	sys_mknodat(struct proc *, void *, register_t *);
1411int	sys_openat(struct proc *, void *, register_t *);
1412int	sys_readlinkat(struct proc *, void *, register_t *);
1413int	sys_renameat(struct proc *, void *, register_t *);
1414int	sys_symlinkat(struct proc *, void *, register_t *);
1415int	sys_unlinkat(struct proc *, void *, register_t *);
1416int	sys___set_tcb(struct proc *, void *, register_t *);
1417int	sys___get_tcb(struct proc *, void *, register_t *);
1418