summaryrefslogtreecommitdiff
path: root/firmware/target/arm/as3525
diff options
context:
space:
mode:
authorMichael Giacomelli <giac2000@hotmail.com>2012-07-22 19:21:54 -0400
committerMichael Giacomelli <giac2000@hotmail.com>2012-07-22 19:21:54 -0400
commitb61b14f5e86f4f0edea1bca53b37a14a8f7f9585 (patch)
treef6292aa4e534b88e000e5ba56202f3741caff535 /firmware/target/arm/as3525
parent08238178d3840b57e7a2e782fdf8182a2786870c (diff)
downloadrockbox-b61b14f5e86f4f0edea1bca53b37a14a8f7f9585.tar.gz
rockbox-b61b14f5e86f4f0edea1bca53b37a14a8f7f9585.zip
Revert my previous commit disabling the internal ROM clock during normal
operation. The interal ROM clock seems to be needed to reboot the player, so disabling it is too dangerous. Hopefully this will prevent problems where crashes during the abort handler resulted in a stock player that needed the battery to drain in order to reboot. Change-Id: I7d1e64743dde15b64d718ad3255dada3d570736f
Diffstat (limited to 'firmware/target/arm/as3525')
-rw-r--r--firmware/target/arm/as3525/system-as3525.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/firmware/target/arm/as3525/system-as3525.c b/firmware/target/arm/as3525/system-as3525.c
index 5bdd0c0d89..80d21b2d0b 100644
--- a/firmware/target/arm/as3525/system-as3525.c
+++ b/firmware/target/arm/as3525/system-as3525.c
@@ -272,7 +272,9 @@ void system_init(void)
272 CGU_PERI &= ~0x7f; /* pclk 24 MHz */ 272 CGU_PERI &= ~0x7f; /* pclk 24 MHz */
273#endif 273#endif
274 274
275 CGU_PERI &= ~CGU_ROM_ENABLE; /*disable built in boot rom clock*/ 275 /*this saves a tiny bit of power but seems to leave the processor in
276 a bad state if it manages to reboot without the clock reenabled*/
277 /*CGU_PERI &= ~CGU_ROM_ENABLE;*/ /*disable built in boot rom clock*/
276 278
277 /* bits 31:30 should be set to 0 in arm926-ejs */ 279 /* bits 31:30 should be set to 0 in arm926-ejs */
278 asm volatile( 280 asm volatile(
@@ -320,7 +322,7 @@ void system_init(void)
320 dma_init(); 322 dma_init();
321 323
322 ascodec_init(); 324 ascodec_init();
323 325
324 /* Initialize power management settings */ 326 /* Initialize power management settings */
325#ifdef HAVE_AS3543 327#ifdef HAVE_AS3543
326 /* PLL: disable audio PLL, we use MCLK already */ 328 /* PLL: disable audio PLL, we use MCLK already */
@@ -364,8 +366,8 @@ void system_reboot(void)
364 366
365 disable_irq(); 367 disable_irq();
366 368
367 /* re-enable internal ROM */ 369 /* re-enable internal ROM so that we don't hard lock on power up*/
368 CGU_PERI |= CGU_ROM_ENABLE; 370 CGU_PERI |= CGU_ROM_ENABLE; /*should always be on, but to be safe...*/
369 371
370 /* use watchdog to reset */ 372 /* use watchdog to reset */
371 CGU_PERI |= (CGU_WDOCNT_CLOCK_ENABLE | CGU_WDOIF_CLOCK_ENABLE); 373 CGU_PERI |= (CGU_WDOCNT_CLOCK_ENABLE | CGU_WDOIF_CLOCK_ENABLE);