]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.sbin/powerd/powerd.8
Move SYSCTL_ADD_PROC() to unlocked context in if_ure to avoid lock order reversal.
[FreeBSD/FreeBSD.git] / usr.sbin / powerd / powerd.8
1 .\" Copyright (c) 2005 Nate Lawson
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .\" $FreeBSD$
26 .\"
27 .Dd March 3, 2020
28 .Dt POWERD 8
29 .Os
30 .Sh NAME
31 .Nm powerd
32 .Nd "system power control utility"
33 .Sh SYNOPSIS
34 .Nm
35 .Op Fl a Ar mode
36 .Op Fl b Ar mode
37 .Op Fl i Ar percent
38 .Op Fl M Ar freq
39 .Op Fl m Ar freq
40 .Op Fl N
41 .Op Fl n Ar mode
42 .Op Fl P Ar pidfile
43 .Op Fl p Ar ival
44 .Op Fl r Ar percent
45 .Op Fl s Ar source
46 .Op Fl v
47 .Sh DESCRIPTION
48 The
49 .Nm
50 utility monitors the system state and sets various power control options
51 accordingly.
52 It offers power-saving modes that can be
53 individually selected for operation on AC power or batteries.
54 .Bl -tag -width "hiadaptive"
55 .It Cm maximum
56 Choose the highest performance values.
57 May be abbreviated as
58 .Cm max .
59 .It Cm minimum
60 Choose the lowest performance values to get the most power savings.
61 May be abbreviated as
62 .Cm min .
63 .It Cm adaptive
64 Attempt to strike a balance by degrading performance when the system
65 appears idle and increasing it when the system is busy.
66 It offers a good balance between a small performance loss for greatly
67 increased power savings.
68 May be abbreviated as
69 .Cm adp .
70 .It Cm hiadaptive
71 Like
72 .Cm adaptive
73 mode, but tuned for systems where performance and interactivity are
74 more important than power consumption.
75 It increases frequency faster, reduces frequency less aggressively, and
76 will maintain full frequency for longer.
77 May be abbreviated as
78 .Cm hadp .
79 .El
80 .Pp
81 The default mode is
82 .Cm adaptive
83 for battery power and
84 .Cm hiadaptive
85 for the rest.
86 .Pp
87 .Nm
88 recognizes these runtime options:
89 .Bl -tag -width "-r percent"
90 .It Fl a Ar mode
91 Selects the
92 .Ar mode
93 to use while on AC power.
94 .It Fl b Ar mode
95 Selects the
96 .Ar mode
97 to use while on battery power.
98 .It Fl i Ar percent
99 Specifies the CPU load percent level when adaptive
100 mode should begin to degrade performance to save power.
101 The default is 50% or lower.
102 .It Fl M Ar freq
103 Specifies the maximum frequency to throttle up to.
104 .It Fl m Ar freq
105 Specifies the minimum frequency to throttle down to.
106 .It Fl N
107 Treat "nice" time as idle for the purpose of load calculation;
108 i.e., do not increase the CPU frequency if the CPU is only busy
109 with "nice" processes.
110 .It Fl n Ar mode
111 Selects the
112 .Ar mode
113 to use normally when the AC line state is unknown.
114 .It Fl P Ar pidfile
115 Specifies an alternative file in which the process ID should be stored.
116 .It Fl p Ar ival
117 Specifies a different polling interval (in milliseconds) for AC line state
118 and system idle levels.
119 The default is 250 ms.
120 .It Fl r Ar percent
121 Specifies the CPU load percent level where adaptive
122 mode should consider the CPU running and increase performance.
123 The default is 75% or higher.
124 .It Fl s Ar source
125 Enforces method for AC line state refresh; by default, it is chosen
126 automatically.
127 The set of valid methods is
128 .Cm sysctl , devd
129 and
130 .Cm apm
131 (i386 only).
132 .It Fl v
133 Verbose mode.
134 Messages about power changes will be printed to stdout and
135 .Nm
136 will operate in the foreground.
137 .El
138 .Sh FILES
139 .Bl -tag -width "/var/run/powerd.pid"
140 .It Pa /var/run/powerd.pid
141 The default PID file.
142 .El
143 .Sh SEE ALSO
144 .Xr acpi 4 ,
145 .Xr apm 4 ,
146 .Xr cpufreq 4
147 .Sh HISTORY
148 The
149 .Nm
150 utility first appeared in
151 .Fx 6.0 .
152 .Sh AUTHORS
153 .An -nosplit
154 .An Colin Percival
155 first wrote
156 .Nm estctrl ,
157 the utility that
158 .Nm
159 is based on.
160 .An Nate Lawson
161 then updated it for
162 .Xr cpufreq 4 ,
163 added features, and wrote this manual page.
164 .Sh BUGS
165 The
166 .Nm
167 utility should also power down idle disks and other components besides the CPU.
168 .Pp
169 If
170 .Nm
171 is used with
172 .Pa power_profile ,
173 they may override each other.
174 .Pp
175 The
176 .Nm
177 utility
178 should probably use the
179 .Xr devctl 4
180 interface instead of polling for AC line state.