Linux 4.19.0 Build Error when CONFIG_ACPI not set.

From: Thomas-Mich Richter
Date: Mon Oct 29 2018 - 06:53:48 EST


When I compile the 4.19.0 Linux kernel, I get this build error:

[root@f28 linux]# fgrep -r CONFIG_ACPI .config
# CONFIG_ACPI is not set
[root@f28 linux]#

[root@f28 linux]# make
CALL scripts/checksyscalls.sh
DESCEND objtool
CHK include/generated/compile.h
CC drivers/cpufreq/intel_pstate.o
drivers/cpufreq/intel_pstate.c: In function âshow_base_frequencyâ:
drivers/cpufreq/intel_pstate.c:726:10: error: implicit declaration of
function âintel_pstate_get_cppc_guranteedâ;
did you mean âintel_pstate_get_eppâ?
[-Werror=implicit-function-declaration]
ratio = intel_pstate_get_cppc_guranteed(policy->cpu);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
intel_pstate_get_epp
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:306: drivers/cpufreq/intel_pstate.o]
Error 1
make[1]: *** [scripts/Makefile.build:546: drivers/cpufreq] Error 2
make: *** [Makefile:1052: drivers] Error 2
[root@f28 linux]#

I am building on a virtual machine.

This was introduced with
commit 86d333a8cc7f ("cpufreq: intel_pstate: Add base_frequency attribute")

The function intel_pstate_get_cppc_guranteed() is called but the function
definition is within #ifdef CONFIG_ACPI/#endif conditional compile.

Any ideas how to fix this?
Thanks

--
Thomas Richter, Dept 3303, IBM s390 Linux Development, Boeblingen, Germany
--
Vorsitzende des Aufsichtsrats: Martina Koederitz
GeschÃftsfÃhrung: Dirk Wittkopp
Sitz der Gesellschaft: BÃblingen / Registergericht: Amtsgericht Stuttgart, HRB 243294