diff options
author | Paul Burton <paul.burton@imgtec.com> | 2014-05-07 07:20:59 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2014-05-30 15:01:09 -0400 |
commit | 37e5c835bbbce4fde11cccc30dfe6c7b853ea964 (patch) | |
tree | d2cf384c474d8da3eb0645c23822e6018ea2cdc5 /arch/mips/mti-malta | |
parent | 9e53481eea26891011ef7aa28e7990769fb6cf50 (diff) |
MIPS: Malta: hang on halt
When the system is halted it makes little sense to reset it. Instead,
hang by executing an infinite loop.
[ralf@linux-mips.org: Remove printk from mips_machine_halt() - this is not
the place to communicate with the user.]
Suggested-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/6906/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/mti-malta')
-rw-r--r-- | arch/mips/mti-malta/malta-reset.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/arch/mips/mti-malta/malta-reset.c b/arch/mips/mti-malta/malta-reset.c index d627d4b2b47f..199ed28066e4 100644 --- a/arch/mips/mti-malta/malta-reset.c +++ b/arch/mips/mti-malta/malta-reset.c | |||
@@ -24,17 +24,19 @@ static void mips_machine_restart(char *command) | |||
24 | 24 | ||
25 | static void mips_machine_halt(void) | 25 | static void mips_machine_halt(void) |
26 | { | 26 | { |
27 | unsigned int __iomem *softres_reg = | 27 | while (true); |
28 | ioremap(SOFTRES_REG, sizeof(unsigned int)); | 28 | } |
29 | 29 | ||
30 | __raw_writel(GORESET, softres_reg); | 30 | static void mips_machine_power_off(void) |
31 | { | ||
32 | mips_machine_restart(NULL); | ||
31 | } | 33 | } |
32 | 34 | ||
33 | static int __init mips_reboot_setup(void) | 35 | static int __init mips_reboot_setup(void) |
34 | { | 36 | { |
35 | _machine_restart = mips_machine_restart; | 37 | _machine_restart = mips_machine_restart; |
36 | _machine_halt = mips_machine_halt; | 38 | _machine_halt = mips_machine_halt; |
37 | pm_power_off = mips_machine_halt; | 39 | pm_power_off = mips_machine_power_off; |
38 | 40 | ||
39 | return 0; | 41 | return 0; |
40 | } | 42 | } |