mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 09:19:51 +00:00
ARM: 5864/1: Implement arch_reset() in NUC900
Implement arch_reset(), reboot from shell become possible. Signed-off-by: lijie <eltshanli@gmail.com> Acked-by: Wan ZongShun <mcuos.com@gmail.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
This commit is contained in:
parent
1368c51c50
commit
58b2e0a2dd
1 changed files with 14 additions and 1 deletions
|
@ -15,7 +15,15 @@
|
|||
*
|
||||
*/
|
||||
|
||||
#include <linux/io.h>
|
||||
#include <asm/proc-fns.h>
|
||||
#include <mach/map.h>
|
||||
#include <mach/regs-timer.h>
|
||||
|
||||
#define WTCR (TMR_BA + 0x1C)
|
||||
#define WTCLK (1 << 10)
|
||||
#define WTE (1 << 7)
|
||||
#define WTRE (1 << 1)
|
||||
|
||||
static void arch_idle(void)
|
||||
{
|
||||
|
@ -23,6 +31,11 @@ static void arch_idle(void)
|
|||
|
||||
static void arch_reset(char mode, const char *cmd)
|
||||
{
|
||||
cpu_reset(0);
|
||||
if (mode == 's') {
|
||||
/* Jump into ROM at address 0 */
|
||||
cpu_reset(0);
|
||||
} else {
|
||||
__raw_writel(WTE | WTRE | WTCLK, WTCR);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue