diff options
author | Björn Stenberg <bjorn@haxx.se> | 2008-12-30 23:53:35 +0000 |
---|---|---|
committer | Björn Stenberg <bjorn@haxx.se> | 2008-12-30 23:53:35 +0000 |
commit | 5d3a035cb3714028a659ecd8abbad034666b7b3c (patch) | |
tree | 0046652c99529f7825a7e5b54d8b96a1b0ba6cb7 /firmware/target | |
parent | f59724414bd241509d8f6950fa4b5465a3f26c8e (diff) | |
download | rockbox-5d3a035cb3714028a659ecd8abbad034666b7b3c.tar.gz rockbox-5d3a035cb3714028a659ecd8abbad034666b7b3c.zip |
Implemented system_reboot().
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19617 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target')
-rw-r--r-- | firmware/target/arm/as3525/system-as3525.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/firmware/target/arm/as3525/system-as3525.c b/firmware/target/arm/as3525/system-as3525.c index f2f2c0b454..b502b22425 100644 --- a/firmware/target/arm/as3525/system-as3525.c +++ b/firmware/target/arm/as3525/system-as3525.c | |||
@@ -272,6 +272,11 @@ void system_init(void) | |||
272 | 272 | ||
273 | void system_reboot(void) | 273 | void system_reboot(void) |
274 | { | 274 | { |
275 | /* use watchdog to reset */ | ||
276 | CGU_PERI |= (CGU_WDOCNT_CLOCK_ENABLE | CGU_WDOIF_CLOCK_ENABLE); | ||
277 | WDT_LOAD = 1; /* set counter to 1 */ | ||
278 | WDT_CONTROL = 3; /* enable watchdog counter & reset */ | ||
279 | while(1); | ||
275 | } | 280 | } |
276 | 281 | ||
277 | int system_memory_guard(int newmode) | 282 | int system_memory_guard(int newmode) |