From 4e88d013dcefd37cb32a30b48183983176e66640 Mon Sep 17 00:00:00 2001 From: Ranjani Vaidyanathan Date: Tue, 21 Jun 2011 12:54:09 -0500 Subject: [PATCH] ENGR00151891: MX50-Fix bug in exit from LPAPM mode. When exiting from LPAPM mode, ARM clock is run at 266.67MHZ for a few instructions while the voltage is still at 0.85V. Fix this issue by setting the ARM-PODF divider before switching the parent. Signed-off-by: Ranjani Vaidyanathan --- arch/arm/mach-mx5/bus_freq.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-mx5/bus_freq.c b/arch/arm/mach-mx5/bus_freq.c index c94cf55ae5ff..b5d151e49e6f 100755 --- a/arch/arm/mach-mx5/bus_freq.c +++ b/arch/arm/mach-mx5/bus_freq.c @@ -498,10 +498,12 @@ void exit_lpapm_mode_mx50(int high_bus_freq) __raw_writel(0x02, MXC_CCM_CACRR); clk_set_rate(pll1, cpu_op_tbl[0].pll_rate); - clk_set_parent(pll1_sw_clk, pll1); - /* Set the divider to ARM_PODF to 5. */ + /* Set the divider to ARM_PODF to 5 before + * switching the parent. + */ __raw_writel(0x4, MXC_CCM_CACRR); + clk_set_parent(pll1_sw_clk, pll1); } if (!completion_done(&voltage_change_cmpl)) -- 2.39.5