summaryrefslogtreecommitdiff
path: root/firmware/target/arm/system-pp502x.c
diff options
context:
space:
mode:
authorMark Arigo <markarigo@gmail.com>2007-09-27 02:50:50 +0000
committerMark Arigo <markarigo@gmail.com>2007-09-27 02:50:50 +0000
commit61a83c02a3f0812c54cc9c41d2c1002af4c63f9e (patch)
tree9fe5725b0f0dcfd8468e53799e6a00d0743699de /firmware/target/arm/system-pp502x.c
parentd7c8cff3d827b5de1be4968aec623844a84a1b8c (diff)
downloadrockbox-61a83c02a3f0812c54cc9c41d2c1002af4c63f9e.tar.gz
rockbox-61a83c02a3f0812c54cc9c41d2c1002af4c63f9e.zip
Sansa c200: fix system_reboot with some magic from the OF. Reboot to the OF when usb is inserted.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14862 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/system-pp502x.c')
-rw-r--r--firmware/target/arm/system-pp502x.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/firmware/target/arm/system-pp502x.c b/firmware/target/arm/system-pp502x.c
index 64153eefc4..a234edab8c 100644
--- a/firmware/target/arm/system-pp502x.c
+++ b/firmware/target/arm/system-pp502x.c
@@ -255,7 +255,16 @@ void system_init(void)
255void system_reboot(void) 255void system_reboot(void)
256{ 256{
257 /* Reboot */ 257 /* Reboot */
258#ifdef SANSA_C200
259 CACHE_CTL &= ~0x10;
260
261 /* Magic used by the c200 OF. The BL uses a magic value of 0x23066b7b.
262 In both cases, the OF executes these 2 commands from iram. */
263 outl(0x23066000, 0x70000008);
264 DEV_RS = DEV_SYSTEM;
265#else
258 DEV_RS |= DEV_SYSTEM; 266 DEV_RS |= DEV_SYSTEM;
267#endif
259} 268}
260 269
261int system_memory_guard(int newmode) 270int system_memory_guard(int newmode)