summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2019-01-01 23:27:24 -0500
committerSolomon Peachy <pizza@shaftnet.org>2019-01-01 23:30:44 -0500
commit88cae9d13dcb7164d2445dca837ed76ac405ecd5 (patch)
tree63835a00d8eca55cb5ec9fb6dfd097128220f046
parent7e7ca0c85847e0b7eff094710cc5167df4e852da (diff)
downloadrockbox-88cae9d13dcb7164d2445dca837ed76ac405ecd5.tar.gz
rockbox-88cae9d13dcb7164d2445dca837ed76ac405ecd5.tar.bz2
rockbox-88cae9d13dcb7164d2445dca837ed76ac405ecd5.zip
Coldfire: Don't clobber alwarm wakeup signal in dualboot mode
(See FS#7814 for details) Change-Id: I6a09a8dfe1abc3a396ca8afe1dbbf1d203c7e3e2
-rw-r--r--firmware/target/coldfire/crt0.S4
1 files changed, 4 insertions, 0 deletions
diff --git a/firmware/target/coldfire/crt0.S b/firmware/target/coldfire/crt0.S
index 5e73131894..34492ec853 100644
--- a/firmware/target/coldfire/crt0.S
+++ b/firmware/target/coldfire/crt0.S
@@ -46,6 +46,10 @@ start:
lea MBAR2, %a1
move.l (%a1), %a0 /* store GPIO_READ result for button check in main() */
+ tst.b 0x30000000 /* preloader sets this to 1
+ if woke up due to RTC alarm */
+ bne .loadrockbox
+
/* Wait ~3 seconds for ON-button release. We need roughly 300ns per
iteration, so we check 10000000 times to reach the desired delay */
move.l #10000000, %d0