summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMoshe Piekarski <dev.rockbox@melachim.net>2020-07-28 10:48:47 -0400
committerSolomon Peachy <pizza@shaftnet.org>2020-07-28 22:37:26 +0000
commite3f6e9d9f6e14727740e28bf30914cea1d07ff39 (patch)
tree13fe701c020d4d1fdf483187685f3fecbf5344c7
parent20e400e74b0f34e9ff96f07ae602cf3775f04cf2 (diff)
downloadrockbox-e3f6e9d.tar.gz
rockbox-e3f6e9d.zip
imx233: rtc: generalize PERSISTENT0 fix
Change-Id: Id8452055534df239dcf5e535943ee918a93ec10c
-rw-r--r--firmware/target/arm/imx233/rtc-imx233.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/firmware/target/arm/imx233/rtc-imx233.h b/firmware/target/arm/imx233/rtc-imx233.h
index bc9e8e0c1e..144809cc90 100644
--- a/firmware/target/arm/imx233/rtc-imx233.h
+++ b/firmware/target/arm/imx233/rtc-imx233.h
@@ -84,7 +84,10 @@ static inline void imx233_rtc_init(void)
BF_CLR(RTC_CTRL, SFTRST);
udelay(5); /* only need 3 GPMI clocks (1us) */
BF_CLR(RTC_CTRL, CLKGATE);
- HW_RTC_PERSISTENT0_SET=0x082114;
+#ifdef BM_RTC_PERSISTENT0_DISABLE_XTALOK
+ BF_SET(RTC_PERSISTENT0, XTAL24MHZ_PWRUP, DISABLE_XTALOK);
+#endif
+ BF_CLR(RTC_PERSISTENT0, CLOCKSOURCE);
imx233_rtc_enable_watchdog(false);
}