1 #ifndef _host_priv_user_ 2 #define _host_priv_user_ 3 4 /* Module host_priv */ 5 6 #include <string.h> 7 #include <mach/ndr.h> 8 #include <mach/boolean.h> 9 #include <mach/kern_return.h> 10 #include <mach/notify.h> 11 #include <mach/mach_types.h> 12 #include <mach/message.h> 13 #include <mach/mig_errors.h> 14 #include <mach/port.h> 15 16 /* BEGIN MIG_STRNCPY_ZEROFILL CODE */ 17 18 #if defined(__has_include) 19 #if __has_include(<mach/mig_strncpy_zerofill_support.h>) 20 #ifndef USING_MIG_STRNCPY_ZEROFILL 21 #define USING_MIG_STRNCPY_ZEROFILL 22 #endif 23 #ifndef __MIG_STRNCPY_ZEROFILL_FORWARD_TYPE_DECLS__ 24 #define __MIG_STRNCPY_ZEROFILL_FORWARD_TYPE_DECLS__ 25 #ifdef __cplusplus 26 extern "C" { 27 #endif 28 extern int mig_strncpy_zerofill(char *dest, const char *src, int len) __attribute__((weak_import)); 29 #ifdef __cplusplus 30 } 31 #endif 32 #endif /* __MIG_STRNCPY_ZEROFILL_FORWARD_TYPE_DECLS__ */ 33 #endif /* __has_include(<mach/mig_strncpy_zerofill_support.h>) */ 34 #endif /* __has_include */ 35 36 /* END MIG_STRNCPY_ZEROFILL CODE */ 37 38 39 #ifdef AUTOTEST 40 #ifndef FUNCTION_PTR_T 41 #define FUNCTION_PTR_T 42 typedef void (*function_ptr_t)(mach_port_t, char *, mach_msg_type_number_t); 43 typedef struct { 44 char *name; 45 function_ptr_t function; 46 } function_table_entry; 47 typedef function_table_entry *function_table_t; 48 #endif /* FUNCTION_PTR_T */ 49 #endif /* AUTOTEST */ 50 51 #ifndef host_priv_MSG_COUNT 52 #define host_priv_MSG_COUNT 26 53 #endif /* host_priv_MSG_COUNT */ 54 55 #include <Availability.h> 56 #include <mach/std_types.h> 57 #include <mach/mig.h> 58 #include <mach/mig.h> 59 #include <mach/mach_types.h> 60 #include <mach/mach_types.h> 61 #include <mach_debug/mach_debug_types.h> 62 63 #ifdef __BeforeMigUserHeader 64 __BeforeMigUserHeader 65 #endif /* __BeforeMigUserHeader */ 66 67 #include <sys/cdefs.h> 68 __BEGIN_DECLS 69 70 71 /* Routine host_get_boot_info */ 72 #ifdef mig_external 73 mig_external 74 #else 75 extern 76 #endif /* mig_external */ 77 kern_return_t host_get_boot_info 78 ( 79 host_priv_t host_priv, 80 kernel_boot_info_t boot_info 81 ); 82 83 /* Routine host_reboot */ 84 #ifdef mig_external 85 mig_external 86 #else 87 extern 88 #endif /* mig_external */ 89 kern_return_t host_reboot 90 ( 91 host_priv_t host_priv, 92 int options 93 ); 94 95 /* Routine host_priv_statistics */ 96 #ifdef mig_external 97 mig_external 98 #else 99 extern 100 #endif /* mig_external */ 101 kern_return_t host_priv_statistics 102 ( 103 host_priv_t host_priv, 104 host_flavor_t flavor, 105 host_info_t host_info_out, 106 mach_msg_type_number_t *host_info_outCnt 107 ); 108 109 /* Routine host_default_memory_manager */ 110 #ifdef mig_external 111 mig_external 112 #else 113 extern 114 #endif /* mig_external */ 115 kern_return_t host_default_memory_manager 116 ( 117 host_priv_t host_priv, 118 memory_object_default_t *default_manager, 119 memory_object_cluster_size_t cluster_size 120 ); 121 122 /* Routine vm_wire */ 123 #ifdef mig_external 124 mig_external 125 #else 126 extern 127 #endif /* mig_external */ 128 kern_return_t vm_wire 129 ( 130 host_priv_t host_priv, 131 vm_map_t task, 132 vm_address_t address, 133 vm_size_t size, 134 vm_prot_t desired_access 135 ); 136 137 /* Routine thread_wire */ 138 #ifdef mig_external 139 mig_external 140 #else 141 extern 142 #endif /* mig_external */ 143 kern_return_t thread_wire 144 ( 145 host_priv_t host_priv, 146 thread_act_t thread, 147 boolean_t wired 148 ); 149 150 /* Routine vm_allocate_cpm */ 151 #ifdef mig_external 152 mig_external 153 #else 154 extern 155 #endif /* mig_external */ 156 kern_return_t vm_allocate_cpm 157 ( 158 host_priv_t host_priv, 159 vm_map_t task, 160 vm_address_t *address, 161 vm_size_t size, 162 int flags 163 ); 164 165 /* Routine host_processors */ 166 #ifdef mig_external 167 mig_external 168 #else 169 extern 170 #endif /* mig_external */ 171 kern_return_t host_processors 172 ( 173 host_priv_t host_priv, 174 processor_array_t *out_processor_list, 175 mach_msg_type_number_t *out_processor_listCnt 176 ); 177 178 /* Routine host_get_clock_control */ 179 #ifdef mig_external 180 mig_external 181 #else 182 extern 183 #endif /* mig_external */ 184 kern_return_t host_get_clock_control 185 ( 186 host_priv_t host_priv, 187 clock_id_t clock_id, 188 clock_ctrl_t *clock_ctrl 189 ); 190 191 /* Routine kmod_create */ 192 #ifdef mig_external 193 mig_external 194 #else 195 extern 196 #endif /* mig_external */ 197 kern_return_t kmod_create 198 ( 199 host_priv_t host_priv, 200 vm_address_t info, 201 kmod_t *module 202 ); 203 204 /* Routine kmod_destroy */ 205 #ifdef mig_external 206 mig_external 207 #else 208 extern 209 #endif /* mig_external */ 210 kern_return_t kmod_destroy 211 ( 212 host_priv_t host_priv, 213 kmod_t module 214 ); 215 216 /* Routine kmod_control */ 217 #ifdef mig_external 218 mig_external 219 #else 220 extern 221 #endif /* mig_external */ 222 kern_return_t kmod_control 223 ( 224 host_priv_t host_priv, 225 kmod_t module, 226 kmod_control_flavor_t flavor, 227 kmod_args_t *data, 228 mach_msg_type_number_t *dataCnt 229 ); 230 231 /* Routine host_get_special_port */ 232 #ifdef mig_external 233 mig_external 234 #else 235 extern 236 #endif /* mig_external */ 237 kern_return_t host_get_special_port 238 ( 239 host_priv_t host_priv, 240 int node, 241 int which, 242 mach_port_t *port 243 ); 244 245 /* Routine host_set_special_port */ 246 #ifdef mig_external 247 mig_external 248 #else 249 extern 250 #endif /* mig_external */ 251 kern_return_t host_set_special_port 252 ( 253 host_priv_t host_priv, 254 int which, 255 mach_port_t port 256 ); 257 258 /* Routine host_set_exception_ports */ 259 #ifdef mig_external 260 mig_external 261 #else 262 extern 263 #endif /* mig_external */ 264 kern_return_t host_set_exception_ports 265 ( 266 host_priv_t host_priv, 267 exception_mask_t exception_mask, 268 mach_port_t new_port, 269 exception_behavior_t behavior, 270 thread_state_flavor_t new_flavor 271 ); 272 273 /* Routine host_get_exception_ports */ 274 #ifdef mig_external 275 mig_external 276 #else 277 extern 278 #endif /* mig_external */ 279 kern_return_t host_get_exception_ports 280 ( 281 host_priv_t host_priv, 282 exception_mask_t exception_mask, 283 exception_mask_array_t masks, 284 mach_msg_type_number_t *masksCnt, 285 exception_handler_array_t old_handlers, 286 exception_behavior_array_t old_behaviors, 287 exception_flavor_array_t old_flavors 288 ); 289 290 /* Routine host_swap_exception_ports */ 291 #ifdef mig_external 292 mig_external 293 #else 294 extern 295 #endif /* mig_external */ 296 kern_return_t host_swap_exception_ports 297 ( 298 host_priv_t host_priv, 299 exception_mask_t exception_mask, 300 mach_port_t new_port, 301 exception_behavior_t behavior, 302 thread_state_flavor_t new_flavor, 303 exception_mask_array_t masks, 304 mach_msg_type_number_t *masksCnt, 305 exception_handler_array_t old_handlerss, 306 exception_behavior_array_t old_behaviors, 307 exception_flavor_array_t old_flavors 308 ); 309 310 /* Routine mach_vm_wire */ 311 #ifdef mig_external 312 mig_external 313 #else 314 extern 315 #endif /* mig_external */ 316 kern_return_t mach_vm_wire 317 ( 318 host_priv_t host_priv, 319 vm_map_t task, 320 mach_vm_address_t address, 321 mach_vm_size_t size, 322 vm_prot_t desired_access 323 ); 324 325 /* Routine host_processor_sets */ 326 #ifdef mig_external 327 mig_external 328 #else 329 extern 330 #endif /* mig_external */ 331 kern_return_t host_processor_sets 332 ( 333 host_priv_t host_priv, 334 processor_set_name_array_t *processor_sets, 335 mach_msg_type_number_t *processor_setsCnt 336 ); 337 338 /* Routine host_processor_set_priv */ 339 #ifdef mig_external 340 mig_external 341 #else 342 extern 343 #endif /* mig_external */ 344 kern_return_t host_processor_set_priv 345 ( 346 host_priv_t host_priv, 347 processor_set_name_t set_name, 348 processor_set_t *set 349 ); 350 351 /* Routine host_set_UNDServer */ 352 #ifdef mig_external 353 mig_external 354 #else 355 extern 356 #endif /* mig_external */ 357 kern_return_t host_set_UNDServer 358 ( 359 host_priv_t host, 360 UNDServerRef server 361 ); 362 363 /* Routine host_get_UNDServer */ 364 #ifdef mig_external 365 mig_external 366 #else 367 extern 368 #endif /* mig_external */ 369 kern_return_t host_get_UNDServer 370 ( 371 host_priv_t host, 372 UNDServerRef *server 373 ); 374 375 /* Routine kext_request */ 376 #ifdef mig_external 377 mig_external 378 #else 379 extern 380 #endif /* mig_external */ 381 kern_return_t kext_request 382 ( 383 host_priv_t host_priv, 384 uint32_t user_log_flags, 385 vm_offset_t request_data, 386 mach_msg_type_number_t request_dataCnt, 387 vm_offset_t *response_data, 388 mach_msg_type_number_t *response_dataCnt, 389 vm_offset_t *log_data, 390 mach_msg_type_number_t *log_dataCnt, 391 kern_return_t *op_result 392 ); 393 394 __END_DECLS 395 396 /********************** Caution **************************/ 397 /* The following data types should be used to calculate */ 398 /* maximum message sizes only. The actual message may be */ 399 /* smaller, and the position of the arguments within the */ 400 /* message layout may vary from what is presented here. */ 401 /* For example, if any of the arguments are variable- */ 402 /* sized, and less than the maximum is sent, the data */ 403 /* will be packed tight in the actual message to reduce */ 404 /* the presence of holes. */ 405 /********************** Caution **************************/ 406 407 /* typedefs for all requests */ 408 409 #ifndef __Request__host_priv_subsystem__defined 410 #define __Request__host_priv_subsystem__defined 411 412 #ifdef __MigPackStructs 413 #pragma pack(push, 4) 414 #endif 415 typedef struct { 416 mach_msg_header_t Head; 417 } __Request__host_get_boot_info_t __attribute__((unused)); 418 #ifdef __MigPackStructs 419 #pragma pack(pop) 420 #endif 421 422 #ifdef __MigPackStructs 423 #pragma pack(push, 4) 424 #endif 425 typedef struct { 426 mach_msg_header_t Head; 427 NDR_record_t NDR; 428 int options; 429 } __Request__host_reboot_t __attribute__((unused)); 430 #ifdef __MigPackStructs 431 #pragma pack(pop) 432 #endif 433 434 #ifdef __MigPackStructs 435 #pragma pack(push, 4) 436 #endif 437 typedef struct { 438 mach_msg_header_t Head; 439 NDR_record_t NDR; 440 host_flavor_t flavor; 441 mach_msg_type_number_t host_info_outCnt; 442 } __Request__host_priv_statistics_t __attribute__((unused)); 443 #ifdef __MigPackStructs 444 #pragma pack(pop) 445 #endif 446 447 #ifdef __MigPackStructs 448 #pragma pack(push, 4) 449 #endif 450 typedef struct { 451 mach_msg_header_t Head; 452 /* start of the kernel processed data */ 453 mach_msg_body_t msgh_body; 454 mach_msg_port_descriptor_t default_manager; 455 /* end of the kernel processed data */ 456 NDR_record_t NDR; 457 memory_object_cluster_size_t cluster_size; 458 } __Request__host_default_memory_manager_t __attribute__((unused)); 459 #ifdef __MigPackStructs 460 #pragma pack(pop) 461 #endif 462 463 #ifdef __MigPackStructs 464 #pragma pack(push, 4) 465 #endif 466 typedef struct { 467 mach_msg_header_t Head; 468 /* start of the kernel processed data */ 469 mach_msg_body_t msgh_body; 470 mach_msg_port_descriptor_t task; 471 /* end of the kernel processed data */ 472 NDR_record_t NDR; 473 vm_address_t address; 474 vm_size_t size; 475 vm_prot_t desired_access; 476 } __Request__vm_wire_t __attribute__((unused)); 477 #ifdef __MigPackStructs 478 #pragma pack(pop) 479 #endif 480 481 #ifdef __MigPackStructs 482 #pragma pack(push, 4) 483 #endif 484 typedef struct { 485 mach_msg_header_t Head; 486 /* start of the kernel processed data */ 487 mach_msg_body_t msgh_body; 488 mach_msg_port_descriptor_t thread; 489 /* end of the kernel processed data */ 490 NDR_record_t NDR; 491 boolean_t wired; 492 } __Request__thread_wire_t __attribute__((unused)); 493 #ifdef __MigPackStructs 494 #pragma pack(pop) 495 #endif 496 497 #ifdef __MigPackStructs 498 #pragma pack(push, 4) 499 #endif 500 typedef struct { 501 mach_msg_header_t Head; 502 /* start of the kernel processed data */ 503 mach_msg_body_t msgh_body; 504 mach_msg_port_descriptor_t task; 505 /* end of the kernel processed data */ 506 NDR_record_t NDR; 507 vm_address_t address; 508 vm_size_t size; 509 int flags; 510 } __Request__vm_allocate_cpm_t __attribute__((unused)); 511 #ifdef __MigPackStructs 512 #pragma pack(pop) 513 #endif 514 515 #ifdef __MigPackStructs 516 #pragma pack(push, 4) 517 #endif 518 typedef struct { 519 mach_msg_header_t Head; 520 } __Request__host_processors_t __attribute__((unused)); 521 #ifdef __MigPackStructs 522 #pragma pack(pop) 523 #endif 524 525 #ifdef __MigPackStructs 526 #pragma pack(push, 4) 527 #endif 528 typedef struct { 529 mach_msg_header_t Head; 530 NDR_record_t NDR; 531 clock_id_t clock_id; 532 } __Request__host_get_clock_control_t __attribute__((unused)); 533 #ifdef __MigPackStructs 534 #pragma pack(pop) 535 #endif 536 537 #ifdef __MigPackStructs 538 #pragma pack(push, 4) 539 #endif 540 typedef struct { 541 mach_msg_header_t Head; 542 NDR_record_t NDR; 543 vm_address_t info; 544 } __Request__kmod_create_t __attribute__((unused)); 545 #ifdef __MigPackStructs 546 #pragma pack(pop) 547 #endif 548 549 #ifdef __MigPackStructs 550 #pragma pack(push, 4) 551 #endif 552 typedef struct { 553 mach_msg_header_t Head; 554 NDR_record_t NDR; 555 kmod_t module; 556 } __Request__kmod_destroy_t __attribute__((unused)); 557 #ifdef __MigPackStructs 558 #pragma pack(pop) 559 #endif 560 561 #ifdef __MigPackStructs 562 #pragma pack(push, 4) 563 #endif 564 typedef struct { 565 mach_msg_header_t Head; 566 /* start of the kernel processed data */ 567 mach_msg_body_t msgh_body; 568 mach_msg_ool_descriptor_t data; 569 /* end of the kernel processed data */ 570 NDR_record_t NDR; 571 kmod_t module; 572 kmod_control_flavor_t flavor; 573 mach_msg_type_number_t dataCnt; 574 } __Request__kmod_control_t __attribute__((unused)); 575 #ifdef __MigPackStructs 576 #pragma pack(pop) 577 #endif 578 579 #ifdef __MigPackStructs 580 #pragma pack(push, 4) 581 #endif 582 typedef struct { 583 mach_msg_header_t Head; 584 NDR_record_t NDR; 585 int node; 586 int which; 587 } __Request__host_get_special_port_t __attribute__((unused)); 588 #ifdef __MigPackStructs 589 #pragma pack(pop) 590 #endif 591 592 #ifdef __MigPackStructs 593 #pragma pack(push, 4) 594 #endif 595 typedef struct { 596 mach_msg_header_t Head; 597 /* start of the kernel processed data */ 598 mach_msg_body_t msgh_body; 599 mach_msg_port_descriptor_t port; 600 /* end of the kernel processed data */ 601 NDR_record_t NDR; 602 int which; 603 } __Request__host_set_special_port_t __attribute__((unused)); 604 #ifdef __MigPackStructs 605 #pragma pack(pop) 606 #endif 607 608 #ifdef __MigPackStructs 609 #pragma pack(push, 4) 610 #endif 611 typedef struct { 612 mach_msg_header_t Head; 613 /* start of the kernel processed data */ 614 mach_msg_body_t msgh_body; 615 mach_msg_port_descriptor_t new_port; 616 /* end of the kernel processed data */ 617 NDR_record_t NDR; 618 exception_mask_t exception_mask; 619 exception_behavior_t behavior; 620 thread_state_flavor_t new_flavor; 621 } __Request__host_set_exception_ports_t __attribute__((unused)); 622 #ifdef __MigPackStructs 623 #pragma pack(pop) 624 #endif 625 626 #ifdef __MigPackStructs 627 #pragma pack(push, 4) 628 #endif 629 typedef struct { 630 mach_msg_header_t Head; 631 NDR_record_t NDR; 632 exception_mask_t exception_mask; 633 } __Request__host_get_exception_ports_t __attribute__((unused)); 634 #ifdef __MigPackStructs 635 #pragma pack(pop) 636 #endif 637 638 #ifdef __MigPackStructs 639 #pragma pack(push, 4) 640 #endif 641 typedef struct { 642 mach_msg_header_t Head; 643 /* start of the kernel processed data */ 644 mach_msg_body_t msgh_body; 645 mach_msg_port_descriptor_t new_port; 646 /* end of the kernel processed data */ 647 NDR_record_t NDR; 648 exception_mask_t exception_mask; 649 exception_behavior_t behavior; 650 thread_state_flavor_t new_flavor; 651 } __Request__host_swap_exception_ports_t __attribute__((unused)); 652 #ifdef __MigPackStructs 653 #pragma pack(pop) 654 #endif 655 656 #ifdef __MigPackStructs 657 #pragma pack(push, 4) 658 #endif 659 typedef struct { 660 mach_msg_header_t Head; 661 /* start of the kernel processed data */ 662 mach_msg_body_t msgh_body; 663 mach_msg_port_descriptor_t task; 664 /* end of the kernel processed data */ 665 NDR_record_t NDR; 666 mach_vm_address_t address; 667 mach_vm_size_t size; 668 vm_prot_t desired_access; 669 } __Request__mach_vm_wire_t __attribute__((unused)); 670 #ifdef __MigPackStructs 671 #pragma pack(pop) 672 #endif 673 674 #ifdef __MigPackStructs 675 #pragma pack(push, 4) 676 #endif 677 typedef struct { 678 mach_msg_header_t Head; 679 } __Request__host_processor_sets_t __attribute__((unused)); 680 #ifdef __MigPackStructs 681 #pragma pack(pop) 682 #endif 683 684 #ifdef __MigPackStructs 685 #pragma pack(push, 4) 686 #endif 687 typedef struct { 688 mach_msg_header_t Head; 689 /* start of the kernel processed data */ 690 mach_msg_body_t msgh_body; 691 mach_msg_port_descriptor_t set_name; 692 /* end of the kernel processed data */ 693 } __Request__host_processor_set_priv_t __attribute__((unused)); 694 #ifdef __MigPackStructs 695 #pragma pack(pop) 696 #endif 697 698 #ifdef __MigPackStructs 699 #pragma pack(push, 4) 700 #endif 701 typedef struct { 702 mach_msg_header_t Head; 703 /* start of the kernel processed data */ 704 mach_msg_body_t msgh_body; 705 mach_msg_port_descriptor_t server; 706 /* end of the kernel processed data */ 707 } __Request__host_set_UNDServer_t __attribute__((unused)); 708 #ifdef __MigPackStructs 709 #pragma pack(pop) 710 #endif 711 712 #ifdef __MigPackStructs 713 #pragma pack(push, 4) 714 #endif 715 typedef struct { 716 mach_msg_header_t Head; 717 } __Request__host_get_UNDServer_t __attribute__((unused)); 718 #ifdef __MigPackStructs 719 #pragma pack(pop) 720 #endif 721 722 #ifdef __MigPackStructs 723 #pragma pack(push, 4) 724 #endif 725 typedef struct { 726 mach_msg_header_t Head; 727 /* start of the kernel processed data */ 728 mach_msg_body_t msgh_body; 729 mach_msg_ool_descriptor_t request_data; 730 /* end of the kernel processed data */ 731 NDR_record_t NDR; 732 uint32_t user_log_flags; 733 mach_msg_type_number_t request_dataCnt; 734 } __Request__kext_request_t __attribute__((unused)); 735 #ifdef __MigPackStructs 736 #pragma pack(pop) 737 #endif 738 #endif /* !__Request__host_priv_subsystem__defined */ 739 740 /* union of all requests */ 741 742 #ifndef __RequestUnion__host_priv_subsystem__defined 743 #define __RequestUnion__host_priv_subsystem__defined 744 union __RequestUnion__host_priv_subsystem { 745 __Request__host_get_boot_info_t Request_host_get_boot_info; 746 __Request__host_reboot_t Request_host_reboot; 747 __Request__host_priv_statistics_t Request_host_priv_statistics; 748 __Request__host_default_memory_manager_t Request_host_default_memory_manager; 749 __Request__vm_wire_t Request_vm_wire; 750 __Request__thread_wire_t Request_thread_wire; 751 __Request__vm_allocate_cpm_t Request_vm_allocate_cpm; 752 __Request__host_processors_t Request_host_processors; 753 __Request__host_get_clock_control_t Request_host_get_clock_control; 754 __Request__kmod_create_t Request_kmod_create; 755 __Request__kmod_destroy_t Request_kmod_destroy; 756 __Request__kmod_control_t Request_kmod_control; 757 __Request__host_get_special_port_t Request_host_get_special_port; 758 __Request__host_set_special_port_t Request_host_set_special_port; 759 __Request__host_set_exception_ports_t Request_host_set_exception_ports; 760 __Request__host_get_exception_ports_t Request_host_get_exception_ports; 761 __Request__host_swap_exception_ports_t Request_host_swap_exception_ports; 762 __Request__mach_vm_wire_t Request_mach_vm_wire; 763 __Request__host_processor_sets_t Request_host_processor_sets; 764 __Request__host_processor_set_priv_t Request_host_processor_set_priv; 765 __Request__host_set_UNDServer_t Request_host_set_UNDServer; 766 __Request__host_get_UNDServer_t Request_host_get_UNDServer; 767 __Request__kext_request_t Request_kext_request; 768 }; 769 #endif /* !__RequestUnion__host_priv_subsystem__defined */ 770 /* typedefs for all replies */ 771 772 #ifndef __Reply__host_priv_subsystem__defined 773 #define __Reply__host_priv_subsystem__defined 774 775 #ifdef __MigPackStructs 776 #pragma pack(push, 4) 777 #endif 778 typedef struct { 779 mach_msg_header_t Head; 780 NDR_record_t NDR; 781 kern_return_t RetCode; 782 mach_msg_type_number_t boot_infoOffset; /* MiG doesn't use it */ 783 mach_msg_type_number_t boot_infoCnt; 784 char boot_info[4096]; 785 } __Reply__host_get_boot_info_t __attribute__((unused)); 786 #ifdef __MigPackStructs 787 #pragma pack(pop) 788 #endif 789 790 #ifdef __MigPackStructs 791 #pragma pack(push, 4) 792 #endif 793 typedef struct { 794 mach_msg_header_t Head; 795 NDR_record_t NDR; 796 kern_return_t RetCode; 797 } __Reply__host_reboot_t __attribute__((unused)); 798 #ifdef __MigPackStructs 799 #pragma pack(pop) 800 #endif 801 802 #ifdef __MigPackStructs 803 #pragma pack(push, 4) 804 #endif 805 typedef struct { 806 mach_msg_header_t Head; 807 NDR_record_t NDR; 808 kern_return_t RetCode; 809 mach_msg_type_number_t host_info_outCnt; 810 integer_t host_info_out[68]; 811 } __Reply__host_priv_statistics_t __attribute__((unused)); 812 #ifdef __MigPackStructs 813 #pragma pack(pop) 814 #endif 815 816 #ifdef __MigPackStructs 817 #pragma pack(push, 4) 818 #endif 819 typedef struct { 820 mach_msg_header_t Head; 821 /* start of the kernel processed data */ 822 mach_msg_body_t msgh_body; 823 mach_msg_port_descriptor_t default_manager; 824 /* end of the kernel processed data */ 825 } __Reply__host_default_memory_manager_t __attribute__((unused)); 826 #ifdef __MigPackStructs 827 #pragma pack(pop) 828 #endif 829 830 #ifdef __MigPackStructs 831 #pragma pack(push, 4) 832 #endif 833 typedef struct { 834 mach_msg_header_t Head; 835 NDR_record_t NDR; 836 kern_return_t RetCode; 837 } __Reply__vm_wire_t __attribute__((unused)); 838 #ifdef __MigPackStructs 839 #pragma pack(pop) 840 #endif 841 842 #ifdef __MigPackStructs 843 #pragma pack(push, 4) 844 #endif 845 typedef struct { 846 mach_msg_header_t Head; 847 NDR_record_t NDR; 848 kern_return_t RetCode; 849 } __Reply__thread_wire_t __attribute__((unused)); 850 #ifdef __MigPackStructs 851 #pragma pack(pop) 852 #endif 853 854 #ifdef __MigPackStructs 855 #pragma pack(push, 4) 856 #endif 857 typedef struct { 858 mach_msg_header_t Head; 859 NDR_record_t NDR; 860 kern_return_t RetCode; 861 vm_address_t address; 862 } __Reply__vm_allocate_cpm_t __attribute__((unused)); 863 #ifdef __MigPackStructs 864 #pragma pack(pop) 865 #endif 866 867 #ifdef __MigPackStructs 868 #pragma pack(push, 4) 869 #endif 870 typedef struct { 871 mach_msg_header_t Head; 872 /* start of the kernel processed data */ 873 mach_msg_body_t msgh_body; 874 mach_msg_ool_ports_descriptor_t out_processor_list; 875 /* end of the kernel processed data */ 876 NDR_record_t NDR; 877 mach_msg_type_number_t out_processor_listCnt; 878 } __Reply__host_processors_t __attribute__((unused)); 879 #ifdef __MigPackStructs 880 #pragma pack(pop) 881 #endif 882 883 #ifdef __MigPackStructs 884 #pragma pack(push, 4) 885 #endif 886 typedef struct { 887 mach_msg_header_t Head; 888 /* start of the kernel processed data */ 889 mach_msg_body_t msgh_body; 890 mach_msg_port_descriptor_t clock_ctrl; 891 /* end of the kernel processed data */ 892 } __Reply__host_get_clock_control_t __attribute__((unused)); 893 #ifdef __MigPackStructs 894 #pragma pack(pop) 895 #endif 896 897 #ifdef __MigPackStructs 898 #pragma pack(push, 4) 899 #endif 900 typedef struct { 901 mach_msg_header_t Head; 902 NDR_record_t NDR; 903 kern_return_t RetCode; 904 kmod_t module; 905 } __Reply__kmod_create_t __attribute__((unused)); 906 #ifdef __MigPackStructs 907 #pragma pack(pop) 908 #endif 909 910 #ifdef __MigPackStructs 911 #pragma pack(push, 4) 912 #endif 913 typedef struct { 914 mach_msg_header_t Head; 915 NDR_record_t NDR; 916 kern_return_t RetCode; 917 } __Reply__kmod_destroy_t __attribute__((unused)); 918 #ifdef __MigPackStructs 919 #pragma pack(pop) 920 #endif 921 922 #ifdef __MigPackStructs 923 #pragma pack(push, 4) 924 #endif 925 typedef struct { 926 mach_msg_header_t Head; 927 /* start of the kernel processed data */ 928 mach_msg_body_t msgh_body; 929 mach_msg_ool_descriptor_t data; 930 /* end of the kernel processed data */ 931 NDR_record_t NDR; 932 mach_msg_type_number_t dataCnt; 933 } __Reply__kmod_control_t __attribute__((unused)); 934 #ifdef __MigPackStructs 935 #pragma pack(pop) 936 #endif 937 938 #ifdef __MigPackStructs 939 #pragma pack(push, 4) 940 #endif 941 typedef struct { 942 mach_msg_header_t Head; 943 /* start of the kernel processed data */ 944 mach_msg_body_t msgh_body; 945 mach_msg_port_descriptor_t port; 946 /* end of the kernel processed data */ 947 } __Reply__host_get_special_port_t __attribute__((unused)); 948 #ifdef __MigPackStructs 949 #pragma pack(pop) 950 #endif 951 952 #ifdef __MigPackStructs 953 #pragma pack(push, 4) 954 #endif 955 typedef struct { 956 mach_msg_header_t Head; 957 NDR_record_t NDR; 958 kern_return_t RetCode; 959 } __Reply__host_set_special_port_t __attribute__((unused)); 960 #ifdef __MigPackStructs 961 #pragma pack(pop) 962 #endif 963 964 #ifdef __MigPackStructs 965 #pragma pack(push, 4) 966 #endif 967 typedef struct { 968 mach_msg_header_t Head; 969 NDR_record_t NDR; 970 kern_return_t RetCode; 971 } __Reply__host_set_exception_ports_t __attribute__((unused)); 972 #ifdef __MigPackStructs 973 #pragma pack(pop) 974 #endif 975 976 #ifdef __MigPackStructs 977 #pragma pack(push, 4) 978 #endif 979 typedef struct { 980 mach_msg_header_t Head; 981 /* start of the kernel processed data */ 982 mach_msg_body_t msgh_body; 983 mach_msg_port_descriptor_t old_handlers[32]; 984 /* end of the kernel processed data */ 985 NDR_record_t NDR; 986 mach_msg_type_number_t masksCnt; 987 exception_mask_t masks[32]; 988 exception_behavior_t old_behaviors[32]; 989 thread_state_flavor_t old_flavors[32]; 990 } __Reply__host_get_exception_ports_t __attribute__((unused)); 991 #ifdef __MigPackStructs 992 #pragma pack(pop) 993 #endif 994 995 #ifdef __MigPackStructs 996 #pragma pack(push, 4) 997 #endif 998 typedef struct { 999 mach_msg_header_t Head; 1000 /* start of the kernel processed data */ 1001 mach_msg_body_t msgh_body; 1002 mach_msg_port_descriptor_t old_handlerss[32]; 1003 /* end of the kernel processed data */ 1004 NDR_record_t NDR; 1005 mach_msg_type_number_t masksCnt; 1006 exception_mask_t masks[32]; 1007 exception_behavior_t old_behaviors[32]; 1008 thread_state_flavor_t old_flavors[32]; 1009 } __Reply__host_swap_exception_ports_t __attribute__((unused)); 1010 #ifdef __MigPackStructs 1011 #pragma pack(pop) 1012 #endif 1013 1014 #ifdef __MigPackStructs 1015 #pragma pack(push, 4) 1016 #endif 1017 typedef struct { 1018 mach_msg_header_t Head; 1019 NDR_record_t NDR; 1020 kern_return_t RetCode; 1021 } __Reply__mach_vm_wire_t __attribute__((unused)); 1022 #ifdef __MigPackStructs 1023 #pragma pack(pop) 1024 #endif 1025 1026 #ifdef __MigPackStructs 1027 #pragma pack(push, 4) 1028 #endif 1029 typedef struct { 1030 mach_msg_header_t Head; 1031 /* start of the kernel processed data */ 1032 mach_msg_body_t msgh_body; 1033 mach_msg_ool_ports_descriptor_t processor_sets; 1034 /* end of the kernel processed data */ 1035 NDR_record_t NDR; 1036 mach_msg_type_number_t processor_setsCnt; 1037 } __Reply__host_processor_sets_t __attribute__((unused)); 1038 #ifdef __MigPackStructs 1039 #pragma pack(pop) 1040 #endif 1041 1042 #ifdef __MigPackStructs 1043 #pragma pack(push, 4) 1044 #endif 1045 typedef struct { 1046 mach_msg_header_t Head; 1047 /* start of the kernel processed data */ 1048 mach_msg_body_t msgh_body; 1049 mach_msg_port_descriptor_t set; 1050 /* end of the kernel processed data */ 1051 } __Reply__host_processor_set_priv_t __attribute__((unused)); 1052 #ifdef __MigPackStructs 1053 #pragma pack(pop) 1054 #endif 1055 1056 #ifdef __MigPackStructs 1057 #pragma pack(push, 4) 1058 #endif 1059 typedef struct { 1060 mach_msg_header_t Head; 1061 NDR_record_t NDR; 1062 kern_return_t RetCode; 1063 } __Reply__host_set_UNDServer_t __attribute__((unused)); 1064 #ifdef __MigPackStructs 1065 #pragma pack(pop) 1066 #endif 1067 1068 #ifdef __MigPackStructs 1069 #pragma pack(push, 4) 1070 #endif 1071 typedef struct { 1072 mach_msg_header_t Head; 1073 /* start of the kernel processed data */ 1074 mach_msg_body_t msgh_body; 1075 mach_msg_port_descriptor_t server; 1076 /* end of the kernel processed data */ 1077 } __Reply__host_get_UNDServer_t __attribute__((unused)); 1078 #ifdef __MigPackStructs 1079 #pragma pack(pop) 1080 #endif 1081 1082 #ifdef __MigPackStructs 1083 #pragma pack(push, 4) 1084 #endif 1085 typedef struct { 1086 mach_msg_header_t Head; 1087 /* start of the kernel processed data */ 1088 mach_msg_body_t msgh_body; 1089 mach_msg_ool_descriptor_t response_data; 1090 mach_msg_ool_descriptor_t log_data; 1091 /* end of the kernel processed data */ 1092 NDR_record_t NDR; 1093 mach_msg_type_number_t response_dataCnt; 1094 mach_msg_type_number_t log_dataCnt; 1095 kern_return_t op_result; 1096 } __Reply__kext_request_t __attribute__((unused)); 1097 #ifdef __MigPackStructs 1098 #pragma pack(pop) 1099 #endif 1100 #endif /* !__Reply__host_priv_subsystem__defined */ 1101 1102 /* union of all replies */ 1103 1104 #ifndef __ReplyUnion__host_priv_subsystem__defined 1105 #define __ReplyUnion__host_priv_subsystem__defined 1106 union __ReplyUnion__host_priv_subsystem { 1107 __Reply__host_get_boot_info_t Reply_host_get_boot_info; 1108 __Reply__host_reboot_t Reply_host_reboot; 1109 __Reply__host_priv_statistics_t Reply_host_priv_statistics; 1110 __Reply__host_default_memory_manager_t Reply_host_default_memory_manager; 1111 __Reply__vm_wire_t Reply_vm_wire; 1112 __Reply__thread_wire_t Reply_thread_wire; 1113 __Reply__vm_allocate_cpm_t Reply_vm_allocate_cpm; 1114 __Reply__host_processors_t Reply_host_processors; 1115 __Reply__host_get_clock_control_t Reply_host_get_clock_control; 1116 __Reply__kmod_create_t Reply_kmod_create; 1117 __Reply__kmod_destroy_t Reply_kmod_destroy; 1118 __Reply__kmod_control_t Reply_kmod_control; 1119 __Reply__host_get_special_port_t Reply_host_get_special_port; 1120 __Reply__host_set_special_port_t Reply_host_set_special_port; 1121 __Reply__host_set_exception_ports_t Reply_host_set_exception_ports; 1122 __Reply__host_get_exception_ports_t Reply_host_get_exception_ports; 1123 __Reply__host_swap_exception_ports_t Reply_host_swap_exception_ports; 1124 __Reply__mach_vm_wire_t Reply_mach_vm_wire; 1125 __Reply__host_processor_sets_t Reply_host_processor_sets; 1126 __Reply__host_processor_set_priv_t Reply_host_processor_set_priv; 1127 __Reply__host_set_UNDServer_t Reply_host_set_UNDServer; 1128 __Reply__host_get_UNDServer_t Reply_host_get_UNDServer; 1129 __Reply__kext_request_t Reply_kext_request; 1130 }; 1131 #endif /* !__RequestUnion__host_priv_subsystem__defined */ 1132 1133 #ifndef subsystem_to_name_map_host_priv 1134 #define subsystem_to_name_map_host_priv \ 1135 { "host_get_boot_info", 400 },\ 1136 { "host_reboot", 401 },\ 1137 { "host_priv_statistics", 402 },\ 1138 { "host_default_memory_manager", 403 },\ 1139 { "vm_wire", 404 },\ 1140 { "thread_wire", 405 },\ 1141 { "vm_allocate_cpm", 406 },\ 1142 { "host_processors", 407 },\ 1143 { "host_get_clock_control", 408 },\ 1144 { "kmod_create", 409 },\ 1145 { "kmod_destroy", 410 },\ 1146 { "kmod_control", 411 },\ 1147 { "host_get_special_port", 412 },\ 1148 { "host_set_special_port", 413 },\ 1149 { "host_set_exception_ports", 414 },\ 1150 { "host_get_exception_ports", 415 },\ 1151 { "host_swap_exception_ports", 416 },\ 1152 { "mach_vm_wire", 418 },\ 1153 { "host_processor_sets", 419 },\ 1154 { "host_processor_set_priv", 420 },\ 1155 { "host_set_UNDServer", 423 },\ 1156 { "host_get_UNDServer", 424 },\ 1157 { "kext_request", 425 } 1158 #endif 1159 1160 #ifdef __AfterMigUserHeader 1161 __AfterMigUserHeader 1162 #endif /* __AfterMigUserHeader */ 1163 1164 #endif /* _host_priv_user_ */