forked from len0rd/rockbox
Implemented system_reboot().
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19617 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
f59724414b
commit
5d3a035cb3
2 changed files with 11 additions and 0 deletions
|
@ -272,6 +272,11 @@ void system_init(void)
|
|||
|
||||
void system_reboot(void)
|
||||
{
|
||||
/* use watchdog to reset */
|
||||
CGU_PERI |= (CGU_WDOCNT_CLOCK_ENABLE | CGU_WDOIF_CLOCK_ENABLE);
|
||||
WDT_LOAD = 1; /* set counter to 1 */
|
||||
WDT_CONTROL = 3; /* enable watchdog counter & reset */
|
||||
while(1);
|
||||
}
|
||||
|
||||
int system_memory_guard(int newmode)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue