From: Ye Li Date: Tue, 26 Jan 2016 14:01:57 +0000 (+0800) Subject: imx: mx6sx: Fix issue in LCDIF clock enablement X-Git-Tag: v2016.03-rc2~146 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9655ebdd50c42f24179d738e4e6230c048f41de1;p=u-boot imx: mx6sx: Fix issue in LCDIF clock enablement Wrong checking for the base_addr paramter with LCDIF1 and LCDIF2. Always enter the -EINVAL return. Signed-off-by: Ye Li Reviewed-by: Stefano Babic --- diff --git a/arch/arm/cpu/armv7/mx6/clock.c b/arch/arm/cpu/armv7/mx6/clock.c index 27a3f2f4e6..007204dd4d 100644 --- a/arch/arm/cpu/armv7/mx6/clock.c +++ b/arch/arm/cpu/armv7/mx6/clock.c @@ -742,8 +742,8 @@ int enable_lcdif_clock(u32 base_addr) u32 lcdif_clk_sel_mask, lcdif_ccgr3_mask; if (is_cpu_type(MXC_CPU_MX6SX)) { - if ((base_addr == LCDIF1_BASE_ADDR) || - (base_addr == LCDIF2_BASE_ADDR)) { + if ((base_addr != LCDIF1_BASE_ADDR) && + (base_addr != LCDIF2_BASE_ADDR)) { puts("Wrong LCD interface!\n"); return -EINVAL; }