[PATCH 05/10] i.MX23/28: Fix setting of lcd clock

Sascha Hauer s.hauer at pengutronix.de
Thu Jan 20 04:46:56 EST 2011


Use the correct bitmask for masking out which is
SET_PIXFRAC(MASK_PIXFRAC)

Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 arch/arm/mach-stm/imx_lcd_clk.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-stm/imx_lcd_clk.c b/arch/arm/mach-stm/imx_lcd_clk.c
index 8938664..65bfc6e 100644
--- a/arch/arm/mach-stm/imx_lcd_clk.c
+++ b/arch/arm/mach-stm/imx_lcd_clk.c
@@ -120,7 +120,8 @@ unsigned imx_set_lcdifclk(unsigned nc)
 			best_frac, best_div, 480 * 18 / best_frac,
 			480000 * 18 / best_frac / best_div);
 
-	reg = readl(IMX_CCM_BASE + HW_CLKCTRL_FRAC) & ~MASK_PIXFRAC;
+	reg = readl(IMX_CCM_BASE + HW_CLKCTRL_FRAC);
+	reg &= ~SET_PIXFRAC(MASK_PIXFRAC);
 	reg |= SET_PIXFRAC(best_frac);
 	writel(reg, IMX_CCM_BASE + HW_CLKCTRL_FRAC);
 	writel(reg & ~CLKCTRL_FRAC_CLKGATEPIX, IMX_CCM_BASE + HW_CLKCTRL_FRAC);
-- 
1.7.2.3




More information about the barebox mailing list