@@ -7,6 +7,7 @@
#ifdef CONFIG_CPU_IDLE
extern int arm_cpuidle_init(unsigned int cpu);
extern int arm_cpuidle_suspend(int index);
+extern int arm_cpuidle_wake(int index);
#else
static inline int arm_cpuidle_init(unsigned int cpu)
{
@@ -17,5 +18,10 @@ static inline int arm_cpuidle_suspend(int index)
{
return -EOPNOTSUPP;
}
+
+static inline int arm_cpuidle_wake(int index)
+{
+ return -EOPNOTSUPP;
+}
#endif
#endif
@@ -43,6 +43,14 @@ int arm_cpuidle_suspend(int index)
return cpu_ops[cpu]->cpu_suspend(index);
}
+int arm_cpuidle_wake(int index)
+{
+ int cpu = smp_processor_id();
+
+ return cpu_ops[cpu]->cpu_poke(index);
+}
+
+
#ifdef CONFIG_ACPI
#include <acpi/processor.h>
@@ -48,7 +48,7 @@ static int arm_enter_idle_state(struct cpuidle_device *dev,
static int arm_poke_idle_state(struct cpuidle_device *dev,
struct cpuidle_driver *drv, int cpu)
{
- return 0;
+ return arm_cpuidle_wake(cpu);
}
static struct cpuidle_driver arm_idle_driver __initdata = {
When the arm_poke_idle_state gets called, the poking cpu_ops of the current core gets called, passing on the the index of the core to be poked. Signed-off-by: Abel Vesa <abel.vesa@nxp.com> --- arch/arm64/include/asm/cpuidle.h | 6 ++++++ arch/arm64/kernel/cpuidle.c | 8 ++++++++ drivers/cpuidle/cpuidle-arm.c | 2 +- 3 files changed, 15 insertions(+), 1 deletion(-)