#include <mach/mach_types.h> also included by <mach/mach.h>

mach/mach_types.h

86 typedefs · 41 macros

typedeftask_t

If we are not in the kernel, then these will all be represented by ports at user-space.
typedef mach_port_t task_t
GNU Mach reference · 7.2 Task Interface · © FSF, GFDL
task_t
This is a mach_port_t and used to hold the port name of a task port that represents the thread. Manipulations of the task are implemented as remote procedure calls to the task port. A task can get a port to itself with the mach_task_self system call. The task port name is also used to identify the task's IPC space (see Port Manipulation Interface) and the task's virtual memory map (see Virtual Memory Interface).

typedeftask_name_t

typedef mach_port_t task_name_t

typedeftask_policy_set_t

typedef mach_port_t task_policy_set_t

typedeftask_policy_get_t

typedef mach_port_t task_policy_get_t

typedeftask_inspect_t

typedef mach_port_t task_inspect_t

typedeftask_read_t

typedef mach_port_t task_read_t

typedeftask_suspension_token_t

typedef mach_port_t task_suspension_token_t

typedefthread_t

typedef mach_port_t thread_t
GNU Mach reference · 7.1 Thread Interface · © FSF, GFDL
thread_t
This is a mach_port_t and used to hold the port name of a thread port that represents the thread. Manipulations of the thread are implemented as remote procedure calls to the thread port. A thread can get a port to itself with the mach_thread_self system call.

typedefthread_act_t

typedef mach_port_t thread_act_t

typedefthread_inspect_t

typedef mach_port_t thread_inspect_t

typedefthread_read_t

typedef mach_port_t thread_read_t

typedefthread_suspension_token_t

typedef mach_port_t thread_suspension_token_t

typedefipc_space_t

typedef mach_port_t ipc_space_t

typedefipc_space_read_t

typedef mach_port_t ipc_space_read_t

typedefipc_space_inspect_t

typedef mach_port_t ipc_space_inspect_t

typedefcoalition_t

typedef mach_port_t coalition_t

typedefhost_t

typedef mach_port_t host_t

typedefhost_priv_t

typedef mach_port_t host_priv_t

typedefhost_security_t

typedef mach_port_t host_security_t

typedefprocessor_t

typedef mach_port_t processor_t

typedefprocessor_set_t

typedef mach_port_t processor_set_t

typedefprocessor_set_control_t

typedef mach_port_t processor_set_control_t

typedefsemaphore_t

typedef mach_port_t semaphore_t

typedeflock_set_t

typedef mach_port_t lock_set_t

typedefledger_t

typedef mach_port_t ledger_t

typedefalarm_t

typedef mach_port_t alarm_t

typedefclock_serv_t

typedef mach_port_t clock_serv_t

typedefclock_ctrl_t

typedef mach_port_t clock_ctrl_t

typedefarcade_register_t

typedef mach_port_t arcade_register_t

typedeftask_id_token_t

typedef mach_port_t task_id_token_t

typedefkcdata_object_t

typedef mach_port_t kcdata_object_t

typedefprocessor_set_name_t

These aren't really unique types. They are just called out as unique types at one point in history. So we list them here for compatibility.
typedef processor_set_t processor_set_name_t

typedefclock_reply_t

These types are just hard-coded as ports
typedef mach_port_t clock_reply_t

typedefbootstrap_t

typedef mach_port_t bootstrap_t

typedefmem_entry_name_port_t

typedef mach_port_t mem_entry_name_port_t

typedefexception_handler_t

typedef mach_port_t exception_handler_t

typedefexception_handler_array_t

typedef exception_handler_t *exception_handler_array_t

typedefvm_task_entry_t

typedef mach_port_t vm_task_entry_t

typedefio_main_t

typedef mach_port_t io_main_t

typedefUNDServerRef

typedef mach_port_t UNDServerRef

typedefexception_handler_info_t

typedef ipc_info_port_t exception_handler_info_t

typedeftask_array_t

Mig doesn't translate the components of an array. For example, Mig won't use the thread_t translations to translate a thread_array_t argument. So, these definitions are not completely accurate at the moment for other kernel components.
typedef task_t *task_array_t

typedefthread_array_t

typedef thread_t *thread_array_t

typedefprocessor_set_array_t

typedef processor_set_t *processor_set_array_t

typedefprocessor_set_name_array_t

typedef processor_set_t *processor_set_name_array_t

typedefprocessor_array_t

typedef processor_t *processor_array_t

typedefthread_act_array_t

typedef thread_act_t *thread_act_array_t

typedefledger_array_t

typedef ledger_t *ledger_array_t

typedeftask_port_t

However the real mach_types got declared, we also have to declare types with "port" in the name for compatability with the way OSF had declared the user interfaces at one point. Someday these should go away.
typedef task_t task_port_t

typedeftask_port_array_t

typedef task_array_t task_port_array_t

typedefthread_port_t

typedef thread_t thread_port_t

typedefthread_port_array_t

typedef thread_array_t thread_port_array_t

typedefipc_space_port_t

typedef ipc_space_t ipc_space_port_t

typedefhost_name_t

typedef host_t host_name_t

typedefhost_name_port_t

typedef host_t host_name_port_t

typedefprocessor_set_port_t

typedef processor_set_t processor_set_port_t

typedefprocessor_set_name_port_t

typedef processor_set_t processor_set_name_port_t

typedefprocessor_set_name_port_array_t

typedef processor_set_array_t processor_set_name_port_array_t

typedefprocessor_set_control_port_t

typedef processor_set_t processor_set_control_port_t

typedefprocessor_port_t

typedef processor_t processor_port_t

typedefprocessor_port_array_t

typedef processor_array_t processor_port_array_t

typedefthread_act_port_t

typedef thread_act_t thread_act_port_t

typedefthread_act_port_array_t

typedef thread_act_array_t thread_act_port_array_t

typedefsemaphore_port_t

typedef semaphore_t semaphore_port_t

typedeflock_set_port_t

typedef lock_set_t lock_set_port_t

typedefledger_port_t

typedef ledger_t ledger_port_t

typedefledger_port_array_t

typedef ledger_array_t ledger_port_array_t

typedefalarm_port_t

typedef alarm_t alarm_port_t

typedefclock_serv_port_t

typedef clock_serv_t clock_serv_port_t

typedefclock_ctrl_port_t

typedef clock_ctrl_t clock_ctrl_port_t

typedefexception_port_t

typedef exception_handler_t exception_port_t

typedefexception_port_arrary_t

typedef exception_handler_array_t exception_port_arrary_t

typedefvfs_path_t

typedef char vfs_path_t[4096]

typedefnspace_path_t

8K, c.f. MAXLONGPATHLEN in sys/syslimits.h. These types should NEVER be allocated on the stack.
typedef char nspace_path_t[8192]

typedefnspace_name_t

typedef char nspace_name_t[8192]

macroTASK_NULL

#define TASK_NULL ((task_t) 0)

macroTASK_NAME_NULL

#define TASK_NAME_NULL ((task_name_t) 0)

macroTASK_INSPECT_NULL

#define TASK_INSPECT_NULL ((task_inspect_t) 0)

macroTASK_READ_NULL

#define TASK_READ_NULL ((task_read_t) 0)

macroTHREAD_NULL

#define THREAD_NULL ((thread_t) 0)

macroTHREAD_INSPECT_NULL

#define THREAD_INSPECT_NULL ((thread_inspect_t) 0)

macroTHREAD_READ_NULL

#define THREAD_READ_NULL ((thread_read_t) 0)

macroTID_NULL

#define TID_NULL ((uint64_t) 0)

macroTHR_ACT_NULL

#define THR_ACT_NULL ((thread_act_t) 0)

macroIPC_SPACE_NULL

#define IPC_SPACE_NULL ((ipc_space_t) 0)

macroIPC_SPACE_READ_NULL

#define IPC_SPACE_READ_NULL ((ipc_space_read_t) 0)

macroIPC_SPACE_INSPECT_NULL

#define IPC_SPACE_INSPECT_NULL ((ipc_space_inspect_t) 0)

macroCOALITION_NULL

#define COALITION_NULL ((coalition_t) 0)

macroHOST_NULL

#define HOST_NULL ((host_t) 0)

macroHOST_PRIV_NULL

#define HOST_PRIV_NULL ((host_priv_t) 0)

macroHOST_SECURITY_NULL

#define HOST_SECURITY_NULL ((host_security_t) 0)

macroPROCESSOR_SET_NULL

#define PROCESSOR_SET_NULL ((processor_set_t) 0)

macroPROCESSOR_NULL

#define PROCESSOR_NULL ((processor_t) 0)

macroSEMAPHORE_NULL

#define SEMAPHORE_NULL ((semaphore_t) 0)

macroLOCK_SET_NULL

#define LOCK_SET_NULL ((lock_set_t) 0)

macroLEDGER_NULL

#define LEDGER_NULL ((ledger_t) 0)

macroALARM_NULL

#define ALARM_NULL ((alarm_t) 0)

macroCLOCK_NULL

#define CLOCK_NULL ((clock_t) 0)

macroUND_SERVER_NULL

#define UND_SERVER_NULL ((UNDServerRef) 0)

macroARCADE_REG_NULL

#define ARCADE_REG_NULL ((arcade_register_t) 0)

macroTASK_ID_TOKEN_NULL

#define TASK_ID_TOKEN_NULL ((task_id_token_t) 0)

macroKCDATA_OBJECT_NULL

#define KCDATA_OBJECT_NULL ((kcdata_object_t) 0)

typedefmach_task_flavor_t

capability strictly _DECREASING_. not ordered the other way around because we want TASK_FLAVOR_CONTROL to be closest to the itk_lock. see task.h.
typedef unsigned int mach_task_flavor_t

macroTASK_FLAVOR_CONTROL

#define TASK_FLAVOR_CONTROL 0

macroTASK_FLAVOR_READ

#define TASK_FLAVOR_READ 1

macroTASK_FLAVOR_INSPECT

#define TASK_FLAVOR_INSPECT 2

macroTASK_FLAVOR_NAME

#define TASK_FLAVOR_NAME 3

macroTASK_FLAVOR_MAX

#define TASK_FLAVOR_MAX TASK_FLAVOR_NAME

typedefmach_thread_flavor_t

capability strictly _DECREASING_
typedef unsigned int mach_thread_flavor_t

macroTHREAD_FLAVOR_CONTROL

#define THREAD_FLAVOR_CONTROL 0

macroTHREAD_FLAVOR_READ

#define THREAD_FLAVOR_READ 1

macroTHREAD_FLAVOR_INSPECT

#define THREAD_FLAVOR_INSPECT 2

macroTHREAD_FLAVOR_MAX

#define THREAD_FLAVOR_MAX THREAD_FLAVOR_INSPECT

typedefledger_item_t

DEPRECATED
typedef natural_t ledger_item_t

macroLEDGER_ITEM_INFINITY

#define LEDGER_ITEM_INFINITY ((ledger_item_t) (~0))

typedefledger_entry_id_t

typedef uint32_t ledger_entry_id_t

macroLEDGER_ENTRY_ID_INVALID

#define LEDGER_ENTRY_ID_INVALID ((ledger_entry_id_t)0)

typedefledger_amount_t

typedef int64_t ledger_amount_t

macroLEDGER_LIMIT_INFINITY

#define LEDGER_LIMIT_INFINITY ((ledger_amount_t)((1ULL << 63) - 1))

typedefemulation_vector_t

typedef mach_vm_offset_t *emulation_vector_t

typedefuser_subsystem_t

typedef char *user_subsystem_t

typedeflabelstr_t

typedef char *labelstr_t