aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/clock34xx.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap2/clock34xx.c')
-rw-r--r--arch/arm/mach-omap2/clock34xx.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/arm/mach-omap2/clock34xx.c b/arch/arm/mach-omap2/clock34xx.c
index fdfc7d582913..aad77e0d43c7 100644
--- a/arch/arm/mach-omap2/clock34xx.c
+++ b/arch/arm/mach-omap2/clock34xx.c
@@ -314,14 +314,12 @@ static int _omap3_wait_dpll_status(struct clk *clk, u8 state)
314 const struct dpll_data *dd; 314 const struct dpll_data *dd;
315 int i = 0; 315 int i = 0;
316 int ret = -EINVAL; 316 int ret = -EINVAL;
317 u32 idlest_mask;
318 317
319 dd = clk->dpll_data; 318 dd = clk->dpll_data;
320 319
321 state <<= dd->idlest_bit; 320 state <<= __ffs(dd->idlest_mask);
322 idlest_mask = 1 << dd->idlest_bit;
323 321
324 while (((__raw_readl(dd->idlest_reg) & idlest_mask) != state) && 322 while (((__raw_readl(dd->idlest_reg) & dd->idlest_mask) != state) &&
325 i < MAX_DPLL_WAIT_TRIES) { 323 i < MAX_DPLL_WAIT_TRIES) {
326 i++; 324 i++;
327 udelay(1); 325 udelay(1);