From: Manuel Lauss Date: Wed, 20 Aug 2014 19:36:30 +0000 (+0200) Subject: MIPS: Alchemy: devboards: sit and spin after poweroff X-Git-Tag: v3.18-rc1~14^2~22 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=092ea4660808cd441ccf3d415b80665dbe8712f4;p=linux.git MIPS: Alchemy: devboards: sit and spin after poweroff On boards which don't support poweroff, systemd complains about this fact. In case poweroff fails, just sit and spin in the wait loop. Signed-off-by: Manuel Lauss Cc: Linux-MIPS Cc: Manuel Lauss Patchwork: https://patchwork.linux-mips.org/patch/7558/ Signed-off-by: Ralf Baechle --- diff --git a/arch/mips/alchemy/devboards/platform.c b/arch/mips/alchemy/devboards/platform.c index 8df86eb94972..be139a0198b0 100644 --- a/arch/mips/alchemy/devboards/platform.c +++ b/arch/mips/alchemy/devboards/platform.c @@ -11,6 +11,7 @@ #include #include +#include #include #include #include @@ -53,6 +54,8 @@ static void db1x_power_off(void) { bcsr_write(BCSR_RESETS, 0); bcsr_write(BCSR_SYSTEM, BCSR_SYSTEM_PWROFF | BCSR_SYSTEM_RESET); + while (1) /* sit and spin */ + cpu_wait(); } static void db1x_reset(char *c)