Subject: [PATCH 1/1] powerpc/e500/qemu-e500: allow core to idle without waiting

From: Joachim Wiberg <[email-masked]>
Date: Wed, 12 Jan 2022 12:24:59 +0100

From: Tobias Waldekranz <[email-masked]>

This means an idle guest won't needlessly consume an entire core on
the host, waiting for work to show up.

Signed-off-by: Tobias Waldekranz <[email-masked]>
Signed-off-by: Joachim Wiberg <[email-masked]>
---
 arch/powerpc/platforms/85xx/qemu_e500.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/powerpc/platforms/85xx/qemu_e500.c b/arch/powerpc/platforms/85xx/qemu_e500.c
index a4127b0b161f..4c4d577effd9 100644
--- a/arch/powerpc/platforms/85xx/qemu_e500.c
+++ b/arch/powerpc/platforms/85xx/qemu_e500.c
@@ -67,4 +67,9 @@ define_machine(qemu_e500) {
 	.get_irq		= mpic_get_coreint_irq,
 	.calibrate_decr		= generic_calibrate_decr,
 	.progress		= udbg_progress,
+#ifdef CONFIG_PPC64
+	.power_save		= book3e_idle,
+#else
+	.power_save		= e500_idle,
+#endif
 };
-- 
2.25.1