Merge tag 'wireless-2022-04-13' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-block.git] / drivers / cpufreq / Kconfig
CommitLineData
ec8f24b7 1# SPDX-License-Identifier: GPL-2.0-only
bb0a56ec
DJ
2menu "CPU Frequency scaling"
3
1da177e4
LT
4config CPU_FREQ
5 bool "CPU Frequency scaling"
83fe27ea 6 select SRCU
1da177e4
LT
7 help
8 CPU Frequency scaling allows you to change the clock speed of
9 CPUs on the fly. This is a nice method to save power, because
10 the lower the CPU clock speed, the less power the CPU consumes.
11
12 Note that this driver doesn't automatically change the CPU
13 clock speed, you need to either enable a dynamic cpufreq governor
14 (see below) after boot, or use a userspace tool.
15
733dda9c
AM
16 For details, take a look at
17 <file:Documentation/admin-guide/pm/cpufreq.rst>.
1da177e4
LT
18
19 If in doubt, say N.
20
21if CPU_FREQ
22
2d0c58ad
RW
23config CPU_FREQ_GOV_ATTR_SET
24 bool
25
1e15f295 26config CPU_FREQ_GOV_COMMON
2d0c58ad 27 select CPU_FREQ_GOV_ATTR_SET
e6f03657 28 select IRQ_WORK
1e15f295
LF
29 bool
30
1da177e4 31config CPU_FREQ_STAT
1aefc75b 32 bool "CPU frequency transition statistics"
9101be53 33 help
1aefc75b 34 Export CPU frequency statistics information through sysfs.
9101be53
MF
35
36 If in doubt, say N.
1da177e4 37
1da177e4
LT
38choice
39 prompt "Default CPUFreq governor"
559f56c7 40 default CPU_FREQ_DEFAULT_GOV_USERSPACE if ARM_SA1100_CPUFREQ || ARM_SA1110_CPUFREQ
f259eab3 41 default CPU_FREQ_DEFAULT_GOV_SCHEDUTIL if ARM64 || ARM
a00ec387 42 default CPU_FREQ_DEFAULT_GOV_SCHEDUTIL if X86_INTEL_PSTATE && SMP
1da177e4
LT
43 default CPU_FREQ_DEFAULT_GOV_PERFORMANCE
44 help
45 This option sets which CPUFreq governor shall be loaded at
a00ec387 46 startup. If in doubt, use the default setting.
1da177e4
LT
47
48config CPU_FREQ_DEFAULT_GOV_PERFORMANCE
49 bool "performance"
50 select CPU_FREQ_GOV_PERFORMANCE
51 help
52 Use the CPUFreq governor 'performance' as default. This sets
53 the frequency statically to the highest frequency supported by
54 the CPU.
55
30d221db
AG
56config CPU_FREQ_DEFAULT_GOV_POWERSAVE
57 bool "powersave"
30d221db
AG
58 select CPU_FREQ_GOV_POWERSAVE
59 help
60 Use the CPUFreq governor 'powersave' as default. This sets
61 the frequency statically to the lowest frequency supported by
62 the CPU.
63
1da177e4
LT
64config CPU_FREQ_DEFAULT_GOV_USERSPACE
65 bool "userspace"
66 select CPU_FREQ_GOV_USERSPACE
67 help
68 Use the CPUFreq governor 'userspace' as default. This allows
0211a9c8 69 you to set the CPU frequency manually or when a userspace
1da177e4
LT
70 program shall be able to set the CPU dynamically without having
71 to enable the userspace governor manually.
72
1c256245
TR
73config CPU_FREQ_DEFAULT_GOV_ONDEMAND
74 bool "ondemand"
db865272 75 depends on !(X86_INTEL_PSTATE && SMP)
1c256245
TR
76 select CPU_FREQ_GOV_ONDEMAND
77 select CPU_FREQ_GOV_PERFORMANCE
78 help
79 Use the CPUFreq governor 'ondemand' as default. This allows
80 you to get a full dynamic frequency capable system by simply
81 loading your cpufreq low-level hardware driver.
82 Be aware that not all cpufreq drivers support the ondemand
83 governor. If unsure have a look at the help section of the
84 driver. Fallback governor will be the performance governor.
85
86config CPU_FREQ_DEFAULT_GOV_CONSERVATIVE
87 bool "conservative"
db865272 88 depends on !(X86_INTEL_PSTATE && SMP)
1c256245
TR
89 select CPU_FREQ_GOV_CONSERVATIVE
90 select CPU_FREQ_GOV_PERFORMANCE
91 help
92 Use the CPUFreq governor 'conservative' as default. This allows
93 you to get a full dynamic frequency capable system by simply
94 loading your cpufreq low-level hardware driver.
95 Be aware that not all cpufreq drivers support the conservative
96 governor. If unsure have a look at the help section of the
97 driver. Fallback governor will be the performance governor.
9bdcb44e
RW
98
99config CPU_FREQ_DEFAULT_GOV_SCHEDUTIL
100 bool "schedutil"
cfe9492f 101 depends on SMP
9bdcb44e
RW
102 select CPU_FREQ_GOV_SCHEDUTIL
103 select CPU_FREQ_GOV_PERFORMANCE
104 help
105 Use the 'schedutil' CPUFreq governor by default. If unsure,
106 have a look at the help section of that governor. The fallback
107 governor will be 'performance'.
108
1da177e4
LT
109endchoice
110
111config CPU_FREQ_GOV_PERFORMANCE
9101be53
MF
112 tristate "'performance' governor"
113 help
1da177e4
LT
114 This cpufreq governor sets the frequency statically to the
115 highest available CPU frequency.
116
9101be53
MF
117 To compile this driver as a module, choose M here: the
118 module will be called cpufreq_performance.
119
1da177e4
LT
120 If in doubt, say Y.
121
122config CPU_FREQ_GOV_POWERSAVE
9101be53
MF
123 tristate "'powersave' governor"
124 help
1da177e4
LT
125 This cpufreq governor sets the frequency statically to the
126 lowest available CPU frequency.
127
9101be53
MF
128 To compile this driver as a module, choose M here: the
129 module will be called cpufreq_powersave.
130
1da177e4
LT
131 If in doubt, say Y.
132
133config CPU_FREQ_GOV_USERSPACE
9101be53
MF
134 tristate "'userspace' governor for userspace frequency scaling"
135 help
1da177e4 136 Enable this cpufreq governor when you either want to set the
0211a9c8 137 CPU frequency manually or when a userspace program shall
1da177e4 138 be able to set the CPU dynamically, like on LART
4c41251e 139 <http://www.lartmaker.nl/>.
1da177e4 140
9101be53
MF
141 To compile this driver as a module, choose M here: the
142 module will be called cpufreq_userspace.
143
1da177e4
LT
144 If in doubt, say Y.
145
146config CPU_FREQ_GOV_ONDEMAND
147 tristate "'ondemand' cpufreq policy governor"
1e15f295 148 select CPU_FREQ_GOV_COMMON
1da177e4
LT
149 help
150 'ondemand' - This driver adds a dynamic cpufreq policy governor.
151 The governor does a periodic polling and
152 changes frequency based on the CPU utilization.
153 The support for this governor depends on CPU capability to
154 do fast frequency switching (i.e, very low latency frequency
155 transitions).
156
9101be53
MF
157 To compile this driver as a module, choose M here: the
158 module will be called cpufreq_ondemand.
159
733dda9c
AM
160 For details, take a look at
161 <file:Documentation/admin-guide/pm/cpufreq.rst>.
1da177e4
LT
162
163 If in doubt, say N.
164
b9170836
DJ
165config CPU_FREQ_GOV_CONSERVATIVE
166 tristate "'conservative' cpufreq governor"
167 depends on CPU_FREQ
1e15f295 168 select CPU_FREQ_GOV_COMMON
b9170836
DJ
169 help
170 'conservative' - this driver is rather similar to the 'ondemand'
171 governor both in its source code and its purpose, the difference is
172 its optimisation for better suitability in a battery powered
173 environment. The frequency is gracefully increased and decreased
174 rather than jumping to 100% when speed is required.
175
176 If you have a desktop machine then you should really be considering
177 the 'ondemand' governor instead, however if you are using a laptop,
178 PDA or even an AMD64 based computer (due to the unacceptable
179 step-by-step latency issues between the minimum and maximum frequency
180 transitions in the CPU) you will probably want to use this governor.
181
9101be53
MF
182 To compile this driver as a module, choose M here: the
183 module will be called cpufreq_conservative.
184
733dda9c
AM
185 For details, take a look at
186 <file:Documentation/admin-guide/pm/cpufreq.rst>.
b9170836
DJ
187
188 If in doubt, say N.
189
9bdcb44e 190config CPU_FREQ_GOV_SCHEDUTIL
58919e83 191 bool "'schedutil' cpufreq policy governor"
bf7cdff1 192 depends on CPU_FREQ && SMP
9bdcb44e
RW
193 select CPU_FREQ_GOV_ATTR_SET
194 select IRQ_WORK
195 help
196 This governor makes decisions based on the utilization data provided
197 by the scheduler. It sets the CPU frequency to be proportional to
198 the utilization/capacity ratio coming from the scheduler. If the
199 utilization is frequency-invariant, the new frequency is also
200 proportional to the maximum available frequency. If that is not the
201 case, it is proportional to the current frequency of the CPU. The
202 frequency tipping point is at utilization/capacity equal to 80% in
203 both cases.
204
9bdcb44e
RW
205 If in doubt, say N.
206
f41f4815
VK
207comment "CPU frequency scaling drivers"
208
bbcf0719
VK
209config CPUFREQ_DT
210 tristate "Generic DT based cpufreq driver"
5fbfbcd3 211 depends on HAVE_CLK && OF
f56aad1d 212 select CPUFREQ_DT_PLATDEV
109df086 213 select PM_OPP
95ceafd4 214 help
bbcf0719 215 This adds a generic DT based cpufreq driver for frequency management.
95ceafd4 216 It supports both uniprocessor (UP) and symmetric multiprocessor (SMP)
33cc4fc1 217 systems.
95ceafd4
SG
218
219 If in doubt, say N.
220
f56aad1d
VK
221config CPUFREQ_DT_PLATDEV
222 bool
223 help
224 This adds a generic DT based cpufreq platdev driver for frequency
225 management. This creates a 'cpufreq-dt' platform device, on the
226 supported platforms.
227
228 If in doubt, say N.
229
f41f4815 230if X86
bb0a56ec 231source "drivers/cpufreq/Kconfig.x86"
f41f4815 232endif
bb0a56ec 233
f41f4815 234if ARM || ARM64
f7d77079 235source "drivers/cpufreq/Kconfig.arm"
f41f4815 236endif
f7d77079 237
f41f4815
VK
238if PPC32 || PPC64
239source "drivers/cpufreq/Kconfig.powerpc"
240endif
81c720c9 241
f41f4815 242if IA64
ab423e43
VK
243config IA64_ACPI_CPUFREQ
244 tristate "ACPI Processor P-States driver"
ab423e43
VK
245 depends on ACPI_PROCESSOR
246 help
247 This driver adds a CPUFreq driver which utilizes the ACPI
248 Processor Performance States.
249
ab423e43 250 If in doubt, say N.
f41f4815 251endif
ab423e43 252
f41f4815 253if MIPS
cdb56cbf
MM
254config BMIPS_CPUFREQ
255 tristate "BMIPS CPUfreq Driver"
256 help
257 This option adds a CPUfreq driver for BMIPS processors with
258 support for configurable CPU frequency.
259
260 For now, BMIPS5 chips are supported (such as the Broadcom 7425).
261
262 If in doubt, say N.
263
7a998935
VK
264config LOONGSON2_CPUFREQ
265 tristate "Loongson2 CPUFreq Driver"
0d307935 266 depends on LEMOTE_MACH2F
7a998935
VK
267 help
268 This option adds a CPUFreq driver for loongson processors which
269 support software configurable cpu frequency.
270
271 Loongson2F and it's successors support this feature.
272
7a998935
VK
273 If in doubt, say N.
274
a0a22cf1
KC
275config LOONGSON1_CPUFREQ
276 tristate "Loongson1 CPUFreq Driver"
0d307935 277 depends on LOONGSON1_LS1B
a0a22cf1
KC
278 help
279 This option adds a CPUFreq driver for loongson1 processors which
280 support software configurable cpu frequency.
281
a0a22cf1 282 If in doubt, say N.
f41f4815 283endif
a0a22cf1 284
f41f4815 285if SPARC64
764295ae
VK
286config SPARC_US3_CPUFREQ
287 tristate "UltraSPARC-III CPU Frequency driver"
764295ae
VK
288 help
289 This adds the CPUFreq driver for UltraSPARC-III processors.
290
764295ae
VK
291 If in doubt, say N.
292
293config SPARC_US2E_CPUFREQ
294 tristate "UltraSPARC-IIe CPU Frequency driver"
764295ae
VK
295 help
296 This adds the CPUFreq driver for UltraSPARC-IIe processors.
297
764295ae 298 If in doubt, say N.
f41f4815 299endif
764295ae 300
f41f4815 301if SUPERH
7258267e
VK
302config SH_CPU_FREQ
303 tristate "SuperH CPU Frequency driver"
7258267e
VK
304 help
305 This adds the cpufreq driver for SuperH. Any CPU that supports
306 clock rate rounding through the clock framework can use this
307 driver. While it will make the kernel slightly larger, this is
308 harmless for CPUs that don't support rate rounding. The driver
309 will also generate a notice in the boot log before disabling
310 itself if the CPU in question is not capable of rate rounding.
311
7258267e 312 If unsure, say N.
f41f4815 313endif
7258267e 314
2f249358
TY
315config QORIQ_CPUFREQ
316 tristate "CPU frequency scaling driver for Freescale QorIQ SoCs"
1f1755af
GU
317 depends on OF && COMMON_CLK
318 depends on PPC_E500MC || SOC_LS1021A || ARCH_LAYERSCAPE || COMPILE_TEST
2f249358
TY
319 select CLK_QORIQ
320 help
321 This adds the CPUFreq driver support for Freescale QorIQ SoCs
322 which are capable of changing the CPU's frequency dynamically.
323
bb0a56ec
DJ
324endif
325endmenu