Commit 18fc252e authored by Paul Walmsley's avatar Paul Walmsley Committed by Tony Lindgren

omap2 clock: fix incorrect rate calculation for osc_ck, sys_ck

omap2_get_crystal_rate() calculates osc_ck and sys_ck rates
incorrectly.  osc_ck runs at the same rate as the external clock
source.  Also, sys_ck's rate derives from osc_ck's rate, divided (not
multiplied) by PRCM_CLKSRC_CTRL:SYSCLKDIV.
Signed-off-by: default avatarPaul Walmsley <paul@pwsan.com>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent 8bfdccc7
......@@ -1126,8 +1126,8 @@ static void __init omap2_get_crystal_rate(struct clk *osc, struct clk *sys)
div &= OMAP_SYSCLKDIV_MASK;
div >>= sys->rate_offset;
osc->rate = sclk * div;
sys->rate = sclk;
osc->rate = sclk;
sys->rate = osc->rate / div;
}
/*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment