summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSammy He <r62914@freescale.com>2009-09-09 14:38:34 +0800
committerSammy He <r62914@freescale.com>2009-09-14 10:09:28 +0800
commit7a12b352ccd0d8d8e79b1da028ea9e9911d99c1d (patch)
tree7a3321db7fad3a702c5323eb0192d00c7ef06c48
parent07bcc018564e79953571458bd04971365afa8f6d (diff)
ENGR00115826 Fix system hung when LCD is powered off with uboot
MCR in clock control isn't initialized on uboot. Here, add this init to clock_init and then it isn't related to bootloader. Signed-off-by: Sammy He <b23300@freescale.com>
-rw-r--r--arch/arm/mach-mx25/clock.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/arm/mach-mx25/clock.c b/arch/arm/mach-mx25/clock.c
index 163c3bba219c..31ab725e1ba8 100644
--- a/arch/arm/mach-mx25/clock.c
+++ b/arch/arm/mach-mx25/clock.c
@@ -1683,6 +1683,7 @@ extern void propagate_rate(struct clk *tclk);
int __init mxc_clocks_init(unsigned long ckil, unsigned long osc, unsigned long ckih1, unsigned long ckih2)
{
+ int i;
struct clk **clkp;
for (clkp = mxc_clks; clkp < mxc_clks + ARRAY_SIZE(mxc_clks); clkp++)
@@ -1695,6 +1696,10 @@ int __init mxc_clocks_init(unsigned long ckil, unsigned long osc, unsigned long
(1 << MXC_CCM_CGCR1_IIM_OFFSET), MXC_CCM_CGCR1);
__raw_writel(1 << MXC_CCM_CGCR2_SCC_OFFSET, MXC_CCM_CGCR2);
+ /* Init all perclk sources to ahb clock*/
+ for (i = 0; i < (sizeof(per_clk) / sizeof(struct clk)); i++)
+ per_clk[i].set_parent(&per_clk[i], &ahb_clk);
+
/* This will propagate to all children and init all the clock rates */
propagate_rate(&osc24m_clk);
propagate_rate(&osc32k_clk);