summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mxs/clock-mx23.c
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2011-03-29 21:54:54 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2011-03-29 21:54:54 +0100
commitb43d151e9679a06df896ac3db65a9dca80040fed (patch)
treeac0b71ef0a28f795700d85a8c8e23ba3fb6eef30 /arch/arm/mach-mxs/clock-mx23.c
parentdfad549d98b60160547d1b8299051b9456c8da85 (diff)
parent5f183860d5007ec76ea36bfa6c36d66e37f0dbcf (diff)
downloadblackbird-op-linux-b43d151e9679a06df896ac3db65a9dca80040fed.tar.gz
blackbird-op-linux-b43d151e9679a06df896ac3db65a9dca80040fed.zip
Merge branches 'fixes' and 'devel-stable' into for-linus
Diffstat (limited to 'arch/arm/mach-mxs/clock-mx23.c')
-rw-r--r--arch/arm/mach-mxs/clock-mx23.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/arm/mach-mxs/clock-mx23.c b/arch/arm/mach-mxs/clock-mx23.c
index d133c7f30940..c3577ea789ac 100644
--- a/arch/arm/mach-mxs/clock-mx23.c
+++ b/arch/arm/mach-mxs/clock-mx23.c
@@ -521,6 +521,15 @@ static int clk_misc_init(void)
__raw_writel(BM_CLKCTRL_CPU_INTERRUPT_WAIT,
CLKCTRL_BASE_ADDR + HW_CLKCTRL_CPU_SET);
+ /*
+ * 480 MHz seems too high to be ssp clock source directly,
+ * so set frac to get a 288 MHz ref_io.
+ */
+ reg = __raw_readl(CLKCTRL_BASE_ADDR + HW_CLKCTRL_FRAC);
+ reg &= ~BM_CLKCTRL_FRAC_IOFRAC;
+ reg |= 30 << BP_CLKCTRL_FRAC_IOFRAC;
+ __raw_writel(reg, CLKCTRL_BASE_ADDR + HW_CLKCTRL_FRAC);
+
return 0;
}
@@ -528,6 +537,12 @@ int __init mx23_clocks_init(void)
{
clk_misc_init();
+ /*
+ * source ssp clock from ref_io than ref_xtal,
+ * as ref_xtal only provides 24 MHz as maximum.
+ */
+ clk_set_parent(&ssp_clk, &ref_io_clk);
+
clk_enable(&cpu_clk);
clk_enable(&hbus_clk);
clk_enable(&xbus_clk);
OpenPOWER on IntegriCloud