Next: Exceptions, Previous: Scheduling, Up: Thread Interface
The function
thread_get_special_portreturns send rights to one of a set of special ports for the thread specified by thread.The possible values for which_port are
THREAD_KERNEL_PORTandTHREAD_EXCEPTION_PORT. A thread also has access to its task's special ports.The function returns
KERN_SUCCESSif the port was returned andKERN_INVALID_ARGUMENTif thread is not a thread or which_port is an invalid port selector.
The function
thread_get_kernel_portis equivalent to the functionthread_get_special_portwith the which_port argument set toTHREAD_KERNEL_PORT.
The function
thread_get_exception_portis equivalent to the functionthread_get_special_portwith the which_port argument set toTHREAD_EXCEPTION_PORT.
The function
thread_set_special_portsets one of a set of special ports for the thread specified by thread.The possible values for which_port are
THREAD_KERNEL_PORTandTHREAD_EXCEPTION_PORT. A thread also has access to its task's special ports.The function returns
KERN_SUCCESSif the port was set andKERN_INVALID_ARGUMENTif thread is not a thread or which_port is an invalid port selector.