Skip to content

Commit 337aadf

Browse files
Ashwin Chaugulerafaeljw
authored andcommitted
ACPI: Introduce CPU performance controls using CPPC
CPPC stands for Collaborative Processor Performance Controls and is defined in the ACPI v5.0+ spec. It describes CPU performance controls on an abstract and continuous scale allowing the platform (e.g. remote power processor) to flexibly optimize CPU performance with its knowledge of power budgets and other architecture specific knowledge. This patch adds a shim which exports commonly used functions to get and set CPPC specific controls for each CPU. This enables CPUFreq drivers to gather per CPU performance data and use with exisiting governors or even allows for customized governors which are implemented inside CPUFreq drivers. Signed-off-by: Ashwin Chaugule <ashwin.chaugule@linaro.org> Reviewed-by: Al Stone <al.stone@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 25cb62b commit 337aadf

4 files changed

Lines changed: 887 additions & 0 deletions

File tree

‎drivers/acpi/Kconfig‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,20 @@ config ACPI_PROCESSOR_IDLE
197197
bool
198198
select CPU_IDLE
199199

200+
config ACPI_CPPC_LIB
201+
bool
202+
depends on ACPI_PROCESSOR
203+
depends on !ACPI_CPU_FREQ_PSS
204+
select MAILBOX
205+
select PCC
206+
help
207+
If this option is enabled, this file implements common functionality
208+
to parse CPPC tables as described in the ACPI 5.1+ spec. The
209+
routines implemented are meant to be used by other
210+
drivers to control CPU performance using CPPC semantics.
211+
If your platform does not support CPPC in firmware,
212+
leave this option disabled.
213+
200214
config ACPI_PROCESSOR
201215
tristate "Processor"
202216
depends on X86 || IA64

‎drivers/acpi/Makefile‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ obj-$(CONFIG_ACPI_HED) += hed.o
7878
obj-$(CONFIG_ACPI_EC_DEBUGFS) += ec_sys.o
7979
obj-$(CONFIG_ACPI_CUSTOM_METHOD)+= custom_method.o
8080
obj-$(CONFIG_ACPI_BGRT) += bgrt.o
81+
obj-$(CONFIG_ACPI_CPPC_LIB) += cppc_acpi.o
8182

8283
# processor has its own "processor." module_param namespace
8384
processor-y := processor_driver.o

0 commit comments

Comments
 (0)