summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin Gong <b38343@freescale.com>2012-04-26 17:05:26 +0800
committerJustin Waters <justin.waters@timesys.com>2012-09-05 14:58:09 -0400
commit2b9b84246bd32adf09541f5af5d35570404d1cd2 (patch)
treee0e066a7e562d7b248954e75d0f569ce4e705e71
parent750c4a4681fd95912e71c31e5f8c15a787f59587 (diff)
ENGR00180955 mx6q sabresd snvs TKT104835: fix long press ONOFF failed in u-boot
Need set Power Supply Glitch to 0x41736166 and clear Power Supply Glitch Detect bit when POR or reboot or power on, otherwise system could not be power off anymore, it will power up auto agian. These steps may be move to ROM code or fix by soc team in the future(PDM ticket number:TKT104835), anyway,u-boot fix the issue firsly. Signed-off-by: Robin Gong <b38343@freescale.com> Signed-off-by: Robin Gong <B38343@freescale.com>
-rw-r--r--board/freescale/mx6q_sabresd/mx6q_sabresd.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/board/freescale/mx6q_sabresd/mx6q_sabresd.c b/board/freescale/mx6q_sabresd/mx6q_sabresd.c
index f7b6251634..d9c803f2c9 100644
--- a/board/freescale/mx6q_sabresd/mx6q_sabresd.c
+++ b/board/freescale/mx6q_sabresd/mx6q_sabresd.c
@@ -817,6 +817,17 @@ void setup_splash_image(void)
int board_init(void)
{
+/* need set Power Supply Glitch to 0x41736166
+*and need clear Power supply Glitch Detect bit
+* when POR or reboot or power on Otherwise system
+*could not be power off anymore*/
+ u32 reg;
+ writel(0x41736166, SNVS_BASE_ADDR + 0x64);/*set LPPGDR*/
+ udelay(10);
+ reg = readl(SNVS_BASE_ADDR + 0x4c);
+ reg |= (1 << 3);
+ writel(reg, SNVS_BASE_ADDR + 0x4c);/*clear LPSR*/
+
mxc_iomux_v3_init((void *)IOMUXC_BASE_ADDR);
setup_boot_device();
fsl_set_system_rev();