diff options
author | Jason Jin <Jason.jin@freescale.com> | 2008-05-13 11:50:36 +0800 |
---|---|---|
committer | Jon Loeliger <jdl@freescale.com> | 2008-07-07 11:29:48 -0500 |
commit | 3473ab737282b08ad61841fcbb14c4d264a93a8e (patch) | |
tree | e67db44d71402d9d6ee3d24742f769c62d87131c /cpu/mpc86xx/cpu.c | |
parent | a036b0443657fe0f4773786de9092251869f08ac (diff) | |
download | u-boot-imx-3473ab737282b08ad61841fcbb14c4d264a93a8e.zip u-boot-imx-3473ab737282b08ad61841fcbb14c4d264a93a8e.tar.gz u-boot-imx-3473ab737282b08ad61841fcbb14c4d264a93a8e.tar.bz2 |
Feed the watchdog in u-boot for 8610 board.
The watchdog on 8610 board is enabled by setting sw[6]
to on. Once enabled, the watchdog can not be disabled
by software. So feed the dog in u-boot is necessary for
normal operation.
Signed-off-by: Jason Jin <Jason.jin@freescale.com>
Diffstat (limited to 'cpu/mpc86xx/cpu.c')
-rw-r--r-- | cpu/mpc86xx/cpu.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/cpu/mpc86xx/cpu.c b/cpu/mpc86xx/cpu.c index e26bf36..4a9905d 100644 --- a/cpu/mpc86xx/cpu.c +++ b/cpu/mpc86xx/cpu.c @@ -214,6 +214,20 @@ get_tbclk(void) void watchdog_reset(void) { +#if defined(CONFIG_MPC8610) + /* + * This actually feed the hard enabled watchdog. + */ + volatile immap_t *immap = (immap_t *)CFG_IMMR; + volatile ccsr_wdt_t *wdt = &immap->im_wdt; + volatile ccsr_gur_t *gur = &immap->im_gur; + u32 tmp = gur->pordevsr; + + if (tmp & 0x4000) { + wdt->swsrr = 0x556c; + wdt->swsrr = 0xaa39; + } +#endif } #endif /* CONFIG_WATCHDOG */ |