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