aboutsummaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorAndy Green <andy.green@linaro.org>2011-11-18 16:03:26 +0800
committerAndy Green <andy.green@linaro.org>2011-11-19 08:55:06 +0800
commit08ed77dc4ee750a2a6f8f425ce3faba6fd601794 (patch)
tree3ad047905a243e8845d11bfbce047bf63c08b4bf /arch/arm
parent7219b0494565c9dc41a1e3ca08aa80345fafec93 (diff)
omap4 clocks detect clock rounding error
Signed-off-by: Andy Green <andy.green@linaro.org>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-omap2/dpll3xxx.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/dpll3xxx.c b/arch/arm/mach-omap2/dpll3xxx.c
index f77022be783..06e00ac0711 100644
--- a/arch/arm/mach-omap2/dpll3xxx.c
+++ b/arch/arm/mach-omap2/dpll3xxx.c
@@ -455,7 +455,12 @@ int omap3_noncore_dpll_set_rate(struct clk *clk, unsigned long rate)
new_parent = dd->clk_bypass;
} else {
if (dd->last_rounded_rate != rate)
- omap2_dpll_round_rate(clk, rate);
+ ret = omap2_dpll_round_rate(clk, rate);
+
+ if (ret == ~0) {
+ pr_err("Rounding failed\n");
+ return -EINVAL;
+ }
if (dd->last_rounded_rate == 0)
return -EINVAL;