]> git.saurik.com Git - apple/xnu.git/blobdiff - osfmk/mach/mach_traps.h
xnu-7195.101.1.tar.gz
[apple/xnu.git] / osfmk / mach / mach_traps.h
index 2639dbfb1d475944afc46d59807d9f59abafa926..7341d83d24984c8072809ca08095def664d1a7ee 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2000-2007 Apple Inc. All rights reserved.
+ * Copyright (c) 2000-2019 Apple Inc. All rights reserved.
  *
  * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  *
@@ -109,7 +109,7 @@ extern mach_msg_return_t mach_msg_overwrite_trap(
        mach_msg_size_t rcv_size,
        mach_port_name_t rcv_name,
        mach_msg_timeout_t timeout,
-       mach_msg_priority_t override,
+       mach_msg_priority_t priority,
        mach_msg_header_t *rcv_msg,
        mach_msg_size_t rcv_limit);
 
@@ -162,6 +162,11 @@ extern kern_return_t _kernelrpc_mach_vm_deallocate_trap(
        mach_vm_size_t size
        );
 
+extern kern_return_t task_dyld_process_info_notify_get(
+       mach_port_name_array_t names_addr,
+       natural_t *names_count_addr
+       );
+
 extern kern_return_t _kernelrpc_mach_vm_protect_trap(
        mach_port_name_t target,
        mach_vm_address_t address,
@@ -191,12 +196,6 @@ extern kern_return_t _kernelrpc_mach_port_allocate_trap(
        mach_port_name_t *name
        );
 
-
-extern kern_return_t _kernelrpc_mach_port_destroy_trap(
-       mach_port_name_t target,
-       mach_port_name_t name
-       );
-
 extern kern_return_t _kernelrpc_mach_port_deallocate_trap(
        mach_port_name_t target,
        mach_port_name_t name
@@ -320,6 +319,20 @@ extern kern_return_t mach_voucher_extract_attr_recipe_trap(
        mach_voucher_attr_raw_recipe_t recipe,
        mach_msg_type_number_t *recipe_size);
 
+extern kern_return_t _kernelrpc_mach_port_type_trap(
+       ipc_space_t task,
+       mach_port_name_t name,
+       mach_port_type_t *ptype);
+
+extern kern_return_t _kernelrpc_mach_port_request_notification_trap(
+       ipc_space_t task,
+       mach_port_name_t name,
+       mach_msg_id_t msgid,
+       mach_port_mscount_t sync,
+       mach_port_name_t notify,
+       mach_msg_type_name_t notifyPoly,
+       mach_port_name_t *previous);
+
 /*
  *     Obsolete interfaces.
  */
@@ -338,6 +351,11 @@ extern kern_return_t pid_for_task(
        mach_port_name_t t,
        int *x);
 
+extern kern_return_t debug_control_port_for_pid(
+       mach_port_name_t target_tport,
+       int pid,
+       mach_port_name_t *t);
+
 #else   /* KERNEL */
 
 #ifdef  XNU_KERNEL_PRIVATE
@@ -370,7 +388,7 @@ extern kern_return_t pid_for_task(
 #endif
 
 #define PAD_ARG_(arg_type, arg_name) \
-  char arg_name##_l_[PADL_(arg_type)]; arg_type arg_name; char arg_name##_r_[PADR_(arg_type)];
+  char arg_name##_l_[PADL_(arg_type)]; arg_type arg_name; char arg_name##_r_[PADR_(arg_type)]
 
 /*
  * To support 32-bit clients as well as 64-bit clients, argument
@@ -422,7 +440,7 @@ struct mach_msg_overwrite_trap_args {
        PAD_ARG_(mach_msg_size_t, rcv_size);
        PAD_ARG_(mach_port_name_t, rcv_name);
        PAD_ARG_(mach_msg_timeout_t, timeout);
-       PAD_ARG_(mach_msg_priority_t, override);
+       PAD_ARG_(mach_msg_priority_t, priority);
        PAD_ARG_8
            PAD_ARG_(user_addr_t, rcv_msg); /* Unused on mach_msg_trap */
 };
@@ -503,6 +521,14 @@ struct pid_for_task_args {
 extern kern_return_t pid_for_task(
        struct pid_for_task_args *args);
 
+struct debug_control_port_for_pid_args {
+       PAD_ARG_(mach_port_name_t, target_tport);
+       PAD_ARG_(int, pid);
+       PAD_ARG_(user_addr_t, t);
+};
+extern kern_return_t debug_control_port_for_pid(
+       struct debug_control_port_for_pid_args *args);
+
 struct macx_swapon_args {
        PAD_ARG_(uint64_t, filename);
        PAD_ARG_(int, flags);
@@ -641,6 +667,14 @@ struct _kernelrpc_mach_vm_deallocate_args {
 extern kern_return_t _kernelrpc_mach_vm_deallocate_trap(
        struct _kernelrpc_mach_vm_deallocate_args *args);
 
+struct task_dyld_process_info_notify_get_trap_args {
+       PAD_ARG_(mach_vm_address_t, names_addr);     /* 2 words */
+       PAD_ARG_(mach_vm_address_t, names_count_addr);  /* 2 words */
+};                                               /* Total: 4 */
+
+extern kern_return_t task_dyld_process_info_notify_get_trap(
+       struct task_dyld_process_info_notify_get_trap_args *args);
+
 struct _kernelrpc_mach_vm_protect_args {
        PAD_ARG_(mach_port_name_t, target);     /* 1 word */
        PAD_ARG_(mach_vm_address_t, address);   /* 2 words */
@@ -681,14 +715,6 @@ struct _kernelrpc_mach_port_allocate_args {
 extern kern_return_t _kernelrpc_mach_port_allocate_trap(
        struct _kernelrpc_mach_port_allocate_args *args);
 
-
-struct _kernelrpc_mach_port_destroy_args {
-       PAD_ARG_(mach_port_name_t, target);
-       PAD_ARG_(mach_port_name_t, name);
-};
-extern kern_return_t _kernelrpc_mach_port_destroy_trap(
-       struct _kernelrpc_mach_port_destroy_args *args);
-
 struct _kernelrpc_mach_port_deallocate_args {
        PAD_ARG_(mach_port_name_t, target);
        PAD_ARG_(mach_port_name_t, name);
@@ -814,6 +840,26 @@ struct mach_voucher_extract_attr_recipe_args {
 extern kern_return_t mach_voucher_extract_attr_recipe_trap(
        struct mach_voucher_extract_attr_recipe_args *args);
 
+struct _kernelrpc_mach_port_type_args {
+       PAD_ARG_(mach_port_name_t, target);
+       PAD_ARG_(mach_port_right_t, name);
+       PAD_ARG_(user_addr_t, ptype);
+};
+extern kern_return_t _kernelrpc_mach_port_type_trap(
+       struct _kernelrpc_mach_port_type_args *args);
+
+struct _kernelrpc_mach_port_request_notification_args {
+       PAD_ARG_(mach_port_name_t, target);
+       PAD_ARG_(mach_port_name_t, name);
+       PAD_ARG_(mach_msg_id_t, msgid);
+       PAD_ARG_(mach_port_mscount_t, sync);
+       PAD_ARG_(mach_port_name_t, notify);
+       PAD_ARG_(mach_msg_type_name_t, notifyPoly);
+       PAD_ARG_(user_addr_t, previous);
+};
+extern kern_return_t _kernelrpc_mach_port_request_notification_trap(
+       struct _kernelrpc_mach_port_request_notification_args *args);
+
 
 /* not published to LP64 clients yet */
 struct iokit_user_client_trap_args {