imx25: Fix reset
Subsystems (2)
PATCH 1/1 imx25: Fix reset
This patch fixes the reset command on imx25
Signed-off-by Matthias Weisser <[email protected]>
--- arch/arm/cpu/arm926ejs/mx25/reset.c | 10 ++-------- arch/arm/include/asm/arch-mx25/imx-regs.h | 10 +++++----- 2 files changed, 7 insertions(+), 13 deletions(-)
arch/arm/cpu/arm926ejs/mx25/reset.c +2 -8
@@ -42,15 +42,9 @@void reset_cpu (ulong ignored) {struct wdog_regs *regs = (struct wdog_regs *)IMX_WDT_BASE ; -/* Disable watchdog and set Time-Out field to 0 */ -writel (0x00000000 , ®s->wcr); -/* Write Service Sequence */ -writel (0x00005555 , ®s->wsr); -writel (0x0000AAAA , ®s->wsr); - -/* Enable watchdog */ -writel (WCR_WDE , ®s->wcr); +/* Enable watchdog and set Time-Out field to 0 (0.5s timeout) */ +writew (WCR_WDE , ®s->wcr);while (1 ) ; }
arch/arm/include/asm/arch-mx25/imx-regs.h +5 -5
@@ -108,11 +108,11 @@ struct gpt_regs {/* Watchdog Timer (WDOG) registers */ struct wdog_regs { -u32 wcr;/* Control */ -u32 wsr;/* Service */ -u32 wrsr;/* Reset Status */ -u32 wicr;/* Interrupt Control */ -u32 wmcr;/* Misc Control */ +u16 wcr;/* Control */ +u16 wsr;/* Service */ +u16 wrsr;/* Reset Status */ +u16 wicr;/* Interrupt Control */ +u16 wmcr;/* Misc Control */ };/* IIM control registers */
Signature · 1 line
1.7.0.4
PATCH 1/1 imx25: Fix reset
Hello.
Quoted 3 lines · Matthias Weisser
This patch fixes the reset command on imx25
Signed-off-by Matthias Weisser<[email protected]>
[...]
Quoted 9 lines
arch/arm/cpu/arm926ejs/mx25/reset.c +0
-1@@ -42,15 +42,9 @@void reset_cpu (ulong ignored) {struct wdog_regs *regs = (struct wdog_regs *)IMX_WDT_BASE ; -/* Disable watchdog and set Time-Out field to 0 */
arch/arm/cpu/arm926ejs/mx25/reset.c line 47
Quoted 10 lines
arch/arm/cpu/arm926ejs/mx25/reset.c +2
-7-writel (0x00000000 ,®s->wcr); -/* Write Service Sequence */ -writel (0x00005555 ,®s->wsr); -writel (0x0000AAAA ,®s->wsr); - -/* Enable watchdog */ -writel (WCR_WDE ,®s->wcr); +/* Enable watchdog and set Time-Out field to 0 (0.5s timeout) */ +writew (WCR_WDE ,®s->wcr);
This wouldn't pass checkpatch.pl -- spaces not allowed before (...
WBR, Sergei