thread_wire


Function - Mark the thread as privileged with respect to kernel resources.

SYNOPSIS

kern_return_t   thread_wire
                (host_priv_t                          host_priv,
                 thread_act_t                            thread,
                 boolean_t                                wired);

PARAMETERS

host_priv
[in host-control send right] The privileged control port for the host on which the thread executes.

thread
[in thread send right] The thread to be wired.

wired
[in scalar] TRUE if the thread is to be wired.

DESCRIPTION

The thread_wire function marks the thread as "wired". A "wired" thread is always eligible to be scheduled and can consume physical memory even when free memory is scarce. This property should be assigned to threads in the default page-out path. Threads not in the default page-out path should not have this property to prevent the kernel's free list of pages from being exhausted.

RETURN VALUES

KERN_INVALID_ARGUMENT
thread is not a thread port. .P host_priv is not the control port for the host on which thread executes.

RELATED INFORMATION

Functions: vm_wire.