1 .\" (c) Copyright 2010 by Matthew Dillon and Dima Ruban. Permission to
2 .\" use and distribute based on the DragonFly copyright.
9 .Nd simple CPU performance control and battery life monitor
13 .Op Fl b Ar backlight_percentage
14 .Op Fl h Ar highest_freq
15 .Op Fl l Ar lowest_freq
16 .Op Fl p Ar hysteresis
18 .Op Fl u Ar trigger_up
19 .Op Fl B Ar minimum_battery_life
20 .Op Fl H Ar lowtemp:hightemp
21 .Op Fl L Ar battery_life_linger
22 .Op Fl P Ar battery_poll_interval
23 .Op Fl T Ar sample_time
27 daemon monitors the CPU load and automatically adjusts the CPU
28 performance up or down accordingly.
32 also monitors battery life.
33 If the battery life is low
34 (less than or equal to 2% by default),
36 will send audio alert immediately,
37 and shutdown the machine after lingering for a little while
38 (60 seconds by default).
40 The options are as follows:
41 .Bl -tag -width ".Fl p Ar hysteresis"
42 .It Fl b Ar backlight_percentage
43 Set backlight to the specified percentage,
44 if AC line is not plugged in.
46 Enable mwait C-state hint adjustment,
52 to not go to the background and prints some debug output to
55 Enable Intel Performance and Energy Bias Hint adjustment,
58 Disable CPU power domain frequency adjustment.
59 CPU power domain frequency adjustment does not reduce CPU power consumption
62 on some of the modern Intel CPUs,
64 .It Fl h Ar highest_freq
65 If CPU power domain frequency adjustment is enabled,
66 then frequency of CPU power domains will not be set to a value higher
67 than the specified limit (unit: MHz).
68 .It Fl l Ar lowest_freq
69 If CPU power domain frequency adjustment is enabled,
70 then frequency of CPU power domains will not be set to a value lower
71 than the specified limit (unit: MHz).
73 NOTE: This option is ignored if powerd is in temperature management.
74 Temperature management will lower the frequency in excess of this value
75 if necessary (but usually doesn't have to).
76 .It Fl p Ar hysteresis
77 Percent of the upper limit to subtract as an hysteresis value to scale
78 down to the min performance.
82 Polling time in seconds.
84 Setting this value lower will poll for load changes faster.
86 a workstation might want to use 0.2 or 0.4.
87 .Nm can become unstable if you make this value too small.
90 Disables switching to turbo mode as maximum frequency completely.
91 Switching to turbo mode as maximum frequency is enabled by default,
92 if the CPU supports it.
93 .It Fl u Ar trigger_up
94 Per CPU load limit in percent to force maximum performance.
96 (meaning an instantanious load of 0.25 on a single cpu).
97 The load is calculated over 3 polls.
98 It is suggested that this value not be made lower than around 7.
99 .It Fl B Ar minimum_battery_life
100 If battery life is less than or equal to the specified value,
101 the machine will start shutting down process.
103 (2% battery life left).
104 .It Fl H Ar lowtemp:hightemp
105 If the cpu temperature goes above lowtemp, powerd will begin ramping down
106 the cpu frequency, reaching the lowest possible cpu frequency when the cpu
107 temperature reaches hightemp.
108 The default range is 75:85 (in degrees C), which tends to hold a laptop
109 to ~80C under heavy load.
111 speaking, no machine cpu should be allowed to go above 80C even if the
112 cpu can handle it, it means something is seriously wrong with your cooling
113 system and you are stressing the cpu and mobo if you allow it.
115 The default range starts at 75C. Most desktops with reasonable cooling
116 will not exceed this value so it makes for a good default. Laptops can
117 easily exceed 75C, sometimes reaching into the high 80's or even the 90's
118 due to poor cooling and vendors tweaking their BIOS/fan-controls to the
119 high side to do well in benchmarks.
120 If you want your laptop to last, however, you really don't want it to get
121 that hot. For powerd to be able to stabilize, we recommend that a minimum
122 of a 10C range be used. So, for example, 70:80, or 75:85, and so forth.
123 The user can change this range when starting powerd by adjusting
128 This option can cause cpu fans to oscillate, and you may need to adjust the
129 range if the oscillation is annoying to you. The basic reason for this is
130 that small changes to the cpu frequency can have a huge effect on system
131 power consumption, causing the BIOS-controlled fan to react, which in turn
132 also changes the temperature and causes powerd to react.
133 .It Fl L Ar battery_life_linger
134 If battery life is less than or equal to the configured value,
135 shutting down the machine will be delayed by the specified value.
137 alert message will be logged to the console,
138 and audio alert will be alarmed.
139 If AC line is plugged in during this delay,
140 shutting down process will be cancelled.
141 Default is 60 seconds.
142 .It Fl P Ar battery_poll_interval
143 Poll the battery life at the specified interval.
145 battery life monitoring will be disabled.
146 Default is 5 seconds.
148 Don't alarm audio alert,
149 if the battery life is low.
150 .It Fl T Ar sample_time
151 Total sample interval in seconds.
153 This effects how quickly powerd ratchets down the performance
154 and cpus on an idle machine.
155 Longer times will ratchet down more slowly.
157 a workstation might want to use a value of 30.0.
162 utility will exit with a non-zero code if required sysctls are not
164 If the system is unable to report temperature,
166 will still run, but will not be able to do any temperature-based frequency
171 is run from the command line, it will automatically kill any previous
172 instance running in the background.
173 The system operator does not have to manually kill or signal
175 when restarting it, simply invoke a new copy.
177 The defaults work well for servers but a workstation user might want
178 to use something like the following in their
180 to ratchet up the machine more quickly in response to spike loads
181 (such as when you are browsing).
183 .Li powerd_enable="YES"
185 .Li powerd_flags="-u 7 -r 0.2 -T 60"
192 command first appeared in
195 I'm shocked I tell you,
196 shocked that there might be bugs in this program!