ACPI: processor: Fix build when !CONFIG_HOTPLUG_CPU
PATCH 1/1 ACPI: processor: Fix build when !CONFIG_HOTPLUG_CPU
Kernel test robot reports build breakage with commit 5f5e49e999ac ("ACPI: processor: Fix CPU0 wakeup in acpi_idle_play_dead()") when !CONFIG_HOTPLUG_CPU/!CONFIG_SMP. wakeup_cpu0() is defined under CONFIG_SMP and start_cpu0() under CONFIG_HOTPLUG_CPU which, in its turn, depend on CONFIG_SMP. Add #ifdef CONFIG_HOTPLUG_CPU to the block, this should be sufficient.
--- drivers/acpi/processor_idle.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/acpi/processor_idle.c +1 -1
@@ -539,7 +539,7 @@ static int acpi_idle_play_dead(struct cpuidle_device *dev, int index) }else return -ENODEV ; -#ifdef CONFIG_X86 +#if defined(CONFIG_X86 ) && defined(CONFIG_HOTPLUG_CPU )/* If NMI wants to wake up CPU0, start CPU0. */ if (wakeup_cpu0 ())start_cpu0 ();
Signature · 1 line
2.30.2
Rafael J. Wysocki
maintainerQuoted 10 lines · Vitaly Kuznetsov
Kernel test robot reports build breakage with commit
5f5e49e999ac("ACPI: processor: Fix CPU0 wakeup inacpi_idle_play_dead()") when !CONFIG_HOTPLUG_CPU/!CONFIG_SMP.wakeup_cpu0()is defined underCONFIG_SMPandstart_cpu0()underCONFIG_HOTPLUG_CPUwhich, in its turn, depend onCONFIG_SMP. Add #ifdefCONFIG_HOTPLUG_CPUto the block, this should be sufficient.Reported-by kernel test robot <[email protected]>Fixes 5f5e49e999ac ("ACPI: processor: Fix CPU0 wakeup in acpi_idle_play_dead()")
Folded into the above patch, thanks!
Quoted 21 lines
Signed-off-by Vitaly Kuznetsov <[email protected]>--- drivers/acpi/processor_idle.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/acpi/processor_idle.c +1
-2@@ -539,7 +539,7 @@ static int acpi_idle_play_dead(struct cpuidle_device *dev, int index) }else return -ENODEV ; -#ifdef CONFIG_X86 +#if defined(CONFIG_X86 ) && defined(CONFIG_HOTPLUG_CPU )/* If NMI wants to wake up CPU0, start CPU0. */ if (wakeup_cpu0 ())start_cpu0 (); --2.30.2