David Brazdil | 0f672f6 | 2019-12-10 10:32:29 +0000 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0-or-later |
Andrew Scull | b4b6d4a | 2019-01-02 15:54:55 +0000 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (C) 2010, Lars-Peter Clausen <lars@metafoo.de> |
Andrew Scull | b4b6d4a | 2019-01-02 15:54:55 +0000 | [diff] [blame] | 4 | */ |
| 5 | |
| 6 | #include <asm/reboot.h> |
| 7 | |
| 8 | #include "reset.h" |
| 9 | |
| 10 | static void jz4740_halt(void) |
| 11 | { |
| 12 | while (1) { |
| 13 | __asm__(".set push;\n" |
| 14 | ".set mips3;\n" |
| 15 | "wait;\n" |
| 16 | ".set pop;\n" |
| 17 | ); |
| 18 | } |
| 19 | } |
| 20 | |
| 21 | void jz4740_reset_init(void) |
| 22 | { |
| 23 | _machine_halt = jz4740_halt; |
| 24 | } |