4 <strong>Function
</strong> - Set per-thread segment descriptors.
7 <strong>kern_return_t i386_set_ldt
</strong>
8 <strong>(thread_act_t
</strong> <var>target_act
</var>,
9 <strong>int
</strong> <var>first_selector
</var>,
10 <strong>descriptor_list_t
</strong> <var>desc_list
</var><strong>);
</strong>
15 <dt> <var>target_act
</var>
17 [in thread send right]
18 Thread whose segment descriptors are to be set.
20 <dt> <var>first_selector
</var>
23 Selector value (segment register value) corresponding to the
24 first segment whose descriptor is to be set.
26 <dt> <var>desc_list
</var>
28 [pointer to in array of
<strong>descriptor_t
</strong>]
29 Array of segment descriptors. The
30 following forms are permitted:
34 Empty descriptor. The
<strong>ACC_P
</strong> flag (segment present) may or may
38 <strong>ACC_CALL_GATE
</strong>--Converted into a system call gate. The
39 <strong>ACC_P
</strong> flag must be set.
42 All other descriptors must have both the
<strong>ACC_P
</strong> flag set and specify
43 user mode access (
<strong>ACC_PL_U
</strong>).
47 <strong>ACC_DATA
</strong>.
50 <strong>ACC_DATA_W
</strong>.
53 <strong>ACC_DATA_E
</strong>.
56 <strong>ACC_DATA_EW
</strong>.
59 <strong>ACC_CODE
</strong>.
62 <strong>ACC_CODE_R
</strong>.
65 <strong>ACC_CODE_C
</strong>.
68 <strong>ACC_CODE_CR
</strong>.
71 <strong>ACC_CALL_GATE_16
</strong>.
74 <strong>ACC_CALL_GATE
</strong>.
79 The
<strong>i386_set_ldt
</strong> function allows a thread to have a
80 private local descriptor
81 table (LDT) which allows its local segments to map various ranges
84 <h3>RETURN VALUES
</h3>
86 Only generic errors apply.
87 <h3>RELATED INFORMATION
</h3>
90 <a href=
"i386_get_ldt.html"><strong>i386_get_ldt
<strong></a>.