From 285e69b993d263f7e5dd7b72bfc4b4d4d85457e9 Mon Sep 17 00:00:00 2001 From: popcornmix Date: Tue, 5 Apr 2016 19:40:12 +0100 Subject: [PATCH] reboot: Use power off rather than busy spinning when halt is requested reboot: Use power off rather than busy spinning when halt is requested Busy spinning after halt is dumb We've previously applied this patch to arch/arm but it is currenltly missing in arch/arm64 Pi4 after "sudo halt" uses 520mA Pi4 after "sudo shutdown now" uses 310mA Make them both use the lower powered option Signed-off-by: Dom Cobley --- arch/arm/kernel/reboot.c | 4 +--- arch/arm64/kernel/process.c | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) --- a/arch/arm/kernel/reboot.c +++ b/arch/arm/kernel/reboot.c @@ -102,9 +102,7 @@ void machine_shutdown(void) */ void machine_halt(void) { - local_irq_disable(); - smp_send_stop(); - while (1); + machine_power_off(); } /* --- a/arch/arm64/kernel/process.c +++ b/arch/arm64/kernel/process.c @@ -97,9 +97,7 @@ void machine_shutdown(void) */ void machine_halt(void) { - local_irq_disable(); - smp_send_stop(); - while (1); + machine_power_off(); } /*