1 .\"
2 .\" Mach Operating System
3 .\" Copyright (c) 1993,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: processor_set_policy_add.man,v $
29 .\" Revision 2.2 93/12/07 13:56:52 dbg
30 .\" Created.
31 .\"
32 .\"
33 .TH processor_set_policy_add 2 9/22/93
34 .CM 4
35 .SH NAME
36 .nf
37 processor_set_policy_add \- enable scheduling policy on processor set
38 processor_set_policy_remove \- disable scheduling policy on processor set
39 .SH SYNOPSIS
40 .nf
41 .ft B
42 #include <mach.h>
43
44 .nf
45 .ft B
46 kern_return_t
47 processor_set_policy_add(
48 mach_port_t processor_set,
49 int policy,
50 policy_param_t limit,
51 natural_t limit_count);
52
53
54 .fi
55 .ft P
56 .nf
57 .ft B
58 kern_return_t
59 processor_set_policy_remove(
60 mach_port_t processor_set,
61 int policy);
62
63
64
65
66 .fi
67 .ft P
68 .SH ARGUMENTS
69 .TP 15
70 .B
71 processor_set
72 The processor set whose allowed policies are to be changed.
73 .TP 15
74 .B
75 policy
76 The policy to enable or disable.
77
78 .SH DESCRIPTION
79 Processor sets may restrict the scheduling policies to be used for
80 threads assigned to them. These two calls provide the mechanism for
81 designating permitted and forbidden policies. The current set of
82 permitted policies can be obtained from
83 .B processor_set_info.
84 Background may not
85 be forbidden by any processor_set. This is a compromise to reduce the
86 complexity of the assign operation; any thread whose policy is forbidden by
87 the target processor set has its policy reset to timesharing, or
88 to background if
89 timesharing is not enabled.
90
91 <mach/policy.h> contains the allowed policies; it is included by mach.h.
92 <mach/rt_policy.h> contains additional policies used by real-time threads.
93
94 .SH DIAGNOSTICS
95 .TP 25
96 KERN_SUCCESS
97 Operation completed successfully
98 .TP 25
99 KERN_INVALID_ARGUMENT
100 .B processor_set
101 is not a processor set,
102 or
103 .B policy
104 is not a valid policy, or an attempt was made to disable background.
105
106 .SH BUGS
107 Not all policies (e.g. real-time policies) are supported
108 by all systems.
109
110 .SH SEE ALSO
111 .B thread_policy, task_policy
112
Cache object: 8ca569a30f69b8e76dd1644a79d619d4
|