Commit 9c49e4ab authored by Russell King's avatar Russell King

ARM: clcd: use amba_part() to determine if we have a PL110 primecell

Instead of matching the entire peripheral ID, match against
just the part number using the amba_xxx() macros.
Acked-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent ff643322
...@@ -212,12 +212,12 @@ static inline void clcdfb_decode(struct clcd_fb *fb, struct clcd_regs *regs) ...@@ -212,12 +212,12 @@ static inline void clcdfb_decode(struct clcd_fb *fb, struct clcd_regs *regs)
break; break;
case 16: case 16:
/* /*
* PL110 cannot choose between 5551 and 565 modes in * PL110 cannot choose between 5551 and 565 modes in its
* its control register * control register. It is possible to use 565 with
* custom external wiring.
*/ */
if ((fb->dev->periphid & 0x000fffff) == 0x00041110) if (amba_part(fb->dev) == 0x110 ||
val |= CNTL_LCDBPP16; fb->fb.var.green.length == 5)
else if (fb->fb.var.green.length == 5)
val |= CNTL_LCDBPP16; val |= CNTL_LCDBPP16;
else else
val |= CNTL_LCDBPP16_565; val |= CNTL_LCDBPP16_565;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment