1 .\"
2 .\" Mach Operating System
3 .\" Copyright (c) 1991,1990 Carnegie Mellon University
4 .\" All Rights Reserved.
5 .\"
6 .\" Permission to use, copy, modify and distribute this software and its
7 .\" documentation is hereby granted, provided that both the copyright
8 .\" notice and this permission notice appear in all copies of the
9 .\" software, derivative works or modified versions, and any portions
10 .\" thereof, and that both notices appear in supporting documentation.
11 .\"
12 .\" CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
13 .\" CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
14 .\" ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
15 .\"
16 .\" Carnegie Mellon requests users of this software to return to
17 .\"
18 .\" Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
19 .\" School of Computer Science
20 .\" Carnegie Mellon University
21 .\" Pittsburgh PA 15213-3890
22 .\"
23 .\" any improvements or extensions that they make and grant Carnegie Mellon
24 .\" the rights to redistribute these changes.
25 .\"
26 .\"
27 .\" HISTORY
28 .\" $Log: thread_wire.man,v $
29 .\" Revision 2.3 93/05/10 19:34:10 rvb
30 .\" updated
31 .\" [93/04/21 16:09:00 lli]
32 .\"
33 .\" Revision 2.2 91/12/11 08:43:29 jsb
34 .\" Created.
35 .\" [91/11/25 rpd]
36 .\"
37 .TH thread_wire 2 1/22/88
38 .CM 4
39 .SH NAME
40 .nf
41 thread_wire \- control VM privilege level of threads
42 .SH SYNOPSIS
43 .nf
44 .ft B
45 #include <mach.h>
46
47 .nf
48 .ft B
49 kern_return_t thread_wire(host_priv, thread, wired)
50 mach_port_t host_priv;
51 mach_port_t thread;
52 boolean_t wired;
53
54 .fi
55 .ft P
56 .SH ARGUMENTS
57 .TP 15
58 .B
59 host_priv
60 The privileged host port for the thread's host.
61 .TP 15
62 .B
63 thread
64 The thread to be affected
65 .TP 15
66 .B
67 wired
68 Make thread privileged if TRUE, unprivileged if FALSE.
69 .SH DESCRIPTION
70 \fBthread_wire\fR controls the VM privilege level of threads.
71 A VM-privileged thread never waits inside the kernel for memory allocation
72 from the kernel's free list of pages or for allocation of
73 a kernel stack.
74
75 Threads that are part of the default pageout path should be
76 VM-privileged, to prevent system deadlocks. Threads that
77 are not part of the default pageout path should not
78 be VM-privileged, to prevent the kernel's free list of pages
79 from being exhausted.
80 .SH DIAGNOSTICS
81 .TP 25
82 KERN_SUCCESS
83 The call succeeded.
84 .TP 25
85 KERN_INVALID_ARGUMENT
86 \fBhost_priv\fR or \fBthread\fR was invalid.
87 .PP
88 The \fBthread_wire\fR call is actually an RPC to \fBhost_priv\fR,
89 normally a send right for a privileged host port, but potentially any
90 send right. In addition to the normal diagnostic return codes from
91 the call's server (normally the kernel), the call may return
92 \fBmach_msg(2)\fR return codes.
93 .SH SEE ALSO
94 vm_wire(2),
95 vm_set_default_memory_manager(2).
Cache object: 9d1b265454f0ce58a6a622c511a884a4
|