diff options
author | Tero Kristo <t-kristo@ti.com> | 2015-03-02 16:24:26 +0200 |
---|---|---|
committer | Tero Kristo <t-kristo@ti.com> | 2015-06-02 12:30:59 +0300 |
commit | afe2cf08401638fbf1bfaf7234be7eb3a5778b04 (patch) | |
tree | e01e2593754c591602ffb004d582997bee7950bc /arch/arm/mach-omap2 | |
parent | ef14db0977547b1982d4f6eaa305e1a22eb95778 (diff) | |
download | linux-afe2cf08401638fbf1bfaf7234be7eb3a5778b04.tar.bz2 |
ARM: OMAP3: dpll3-m2: get rid of obsolete clksel access
Core DVFS support code is currently referencing clksel functionality, which
is wrong. The m2 divisor has been implemented as a divider clock for a long
time already, so replace the validrate check call with proper functionality.
Core DVFS is currently not supported in the kernel so verifying this patch
can be rather tricky, this should probably be fixed at some point.
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Diffstat (limited to 'arch/arm/mach-omap2')
-rw-r--r-- | arch/arm/mach-omap2/clkt34xx_dpll3m2.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/clkt34xx_dpll3m2.c b/arch/arm/mach-omap2/clkt34xx_dpll3m2.c index eb69acf21014..825e3dadb16b 100644 --- a/arch/arm/mach-omap2/clkt34xx_dpll3m2.c +++ b/arch/arm/mach-omap2/clkt34xx_dpll3m2.c @@ -60,7 +60,9 @@ int omap3_core_dpll_m2_set_rate(struct clk_hw *hw, unsigned long rate, if (!clk || !rate) return -EINVAL; - validrate = omap2_clksel_round_rate_div(clk, rate, &new_div); + new_div = DIV_ROUND_UP(parent_rate, rate); + validrate = parent_rate / new_div; + if (validrate != rate) return -EINVAL; |