diff options
author | Masahiro Yamada <yamada.m@jp.panasonic.com> | 2015-02-20 17:04:05 +0900 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2015-02-21 08:23:51 -0500 |
commit | 601fbec7cf815bc2b26ba2546ac5e8501fc7edae (patch) | |
tree | 61c83cdadd3499fcbcf63feb39064ef4130afe3e /arch/arm/mach-davinci/reset.c | |
parent | 09f455dca74973ef5e42311162c8dff7e83d44a2 (diff) | |
download | u-boot-imx-601fbec7cf815bc2b26ba2546ac5e8501fc7edae.zip u-boot-imx-601fbec7cf815bc2b26ba2546ac5e8501fc7edae.tar.gz u-boot-imx-601fbec7cf815bc2b26ba2546ac5e8501fc7edae.tar.bz2 |
ARM: davinci: move SoC sources to mach-davinci
Move
arch/arm/cpu/arm926ejs/davinci/* -> arch/arm/mach-davinci/*
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Tom Rini <trini@ti.com>
Diffstat (limited to 'arch/arm/mach-davinci/reset.c')
-rw-r--r-- | arch/arm/mach-davinci/reset.c | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/arch/arm/mach-davinci/reset.c b/arch/arm/mach-davinci/reset.c new file mode 100644 index 0000000..6b0f154 --- /dev/null +++ b/arch/arm/mach-davinci/reset.c @@ -0,0 +1,32 @@ +/* + * Processor reset using WDT. + * + * Copyright (C) 2012 Dmitry Bondar <bond@inmys.ru> + * Copyright (C) 2007 Sergey Kubushyn <ksi@koi8.net> + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +#include <common.h> +#include <asm/io.h> +#include <asm/arch/timer_defs.h> +#include <asm/arch/hardware.h> + +void reset_cpu(unsigned long a) +{ + struct davinci_timer *const wdttimer = + (struct davinci_timer *)DAVINCI_WDOG_BASE; + writel(0x08, &wdttimer->tgcr); + writel(readl(&wdttimer->tgcr) | 0x03, &wdttimer->tgcr); + writel(0, &wdttimer->tim12); + writel(0, &wdttimer->tim34); + writel(0, &wdttimer->prd12); + writel(0, &wdttimer->prd34); + writel(readl(&wdttimer->tcr) | 0x40, &wdttimer->tcr); + writel(readl(&wdttimer->wdtcr) | 0x4000, &wdttimer->wdtcr); + writel(0xa5c64000, &wdttimer->wdtcr); + writel(0xda7e4000, &wdttimer->wdtcr); + writel(0x4000, &wdttimer->wdtcr); + while (1) + /*nothing*/; +} |