Another (hopefully final) fix for FS#11453 (AMSv2 powerdown fails sometimes when wakeup timer set) by Fabian Vogel.

This fix disables MCLK before powerdown-for-wakeup.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28435 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Bertrik Sikken 2010-11-01 18:58:40 +00:00
parent f2dbbf45de
commit cec1e476e6
2 changed files with 5 additions and 0 deletions

View file

@ -562,6 +562,7 @@ Tuomas Airaksinen
Calvin Walden Calvin Walden
Michael Gentry Michael Gentry
David Fowle David Fowle
Fabian Vogel
The libmad team The libmad team
The wavpack team The wavpack team

View file

@ -142,6 +142,10 @@ void rtc_alarm_poweroff(void)
seconds -= tm.tm_sec; seconds -= tm.tm_sec;
/* disable MCLK, it is a wakeup source and prevents proper shutdown */
CGU_AUDIO = (2 << 0) | (1 << 11);
CGU_PLLBSUP = (1 << 2) | (1 << 3);
/* write wakeup register */ /* write wakeup register */
alarm.seconds = seconds; alarm.seconds = seconds;
alarm.enabled = true; alarm.enabled = true;