diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2011-01-14 14:30:03 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2011-01-24 09:01:04 +0100 |
commit | 13be9f00c33fe69112fe6c755d6a8f3e249abbb2 (patch) | |
tree | 102a64866c2442ed2b3a75167a8c7e572bea7c86 /arch/arm/mach-mxs | |
parent | c56eb8fb6dccb83d9fe62fd4dc00c834de9bc470 (diff) | |
download | op-kernel-dev-13be9f00c33fe69112fe6c755d6a8f3e249abbb2.zip op-kernel-dev-13be9f00c33fe69112fe6c755d6a8f3e249abbb2.tar.gz |
ARM i.MX28: fix bit operation
reg | (1 << clk->enable_shift) always evaluates to true. Switch it
to & which makes much more sense
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Shawn Guo <shawn.guo@freescale.com>
Diffstat (limited to 'arch/arm/mach-mxs')
-rw-r--r-- | arch/arm/mach-mxs/clock-mx28.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/mach-mxs/clock-mx28.c b/arch/arm/mach-mxs/clock-mx28.c index 56312c0..4146b38 100644 --- a/arch/arm/mach-mxs/clock-mx28.c +++ b/arch/arm/mach-mxs/clock-mx28.c @@ -355,7 +355,7 @@ static int name##_set_rate(struct clk *clk, unsigned long rate) \ } else { \ reg &= ~BM_CLKCTRL_##dr##_DIV; \ reg |= div << BP_CLKCTRL_##dr##_DIV; \ - if (reg | (1 << clk->enable_shift)) { \ + if (reg & (1 << clk->enable_shift)) { \ pr_err("%s: clock is gated\n", __func__); \ return -EINVAL; \ } \ |