diff options
Diffstat (limited to 'include/linux/amba/clcd.h')
-rw-r--r-- | include/linux/amba/clcd.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/include/linux/amba/clcd.h b/include/linux/amba/clcd.h index 6b8d73dc1ab0..9cf64b1b688b 100644 --- a/include/linux/amba/clcd.h +++ b/include/linux/amba/clcd.h | |||
@@ -54,6 +54,7 @@ | |||
54 | #define CNTL_LCDBPP4 (2 << 1) | 54 | #define CNTL_LCDBPP4 (2 << 1) |
55 | #define CNTL_LCDBPP8 (3 << 1) | 55 | #define CNTL_LCDBPP8 (3 << 1) |
56 | #define CNTL_LCDBPP16 (4 << 1) | 56 | #define CNTL_LCDBPP16 (4 << 1) |
57 | #define CNTL_LCDBPP16_565 (6 << 1) | ||
57 | #define CNTL_LCDBPP24 (5 << 1) | 58 | #define CNTL_LCDBPP24 (5 << 1) |
58 | #define CNTL_LCDBW (1 << 4) | 59 | #define CNTL_LCDBW (1 << 4) |
59 | #define CNTL_LCDTFT (1 << 5) | 60 | #define CNTL_LCDTFT (1 << 5) |
@@ -209,7 +210,16 @@ static inline void clcdfb_decode(struct clcd_fb *fb, struct clcd_regs *regs) | |||
209 | val |= CNTL_LCDBPP8; | 210 | val |= CNTL_LCDBPP8; |
210 | break; | 211 | break; |
211 | case 16: | 212 | case 16: |
212 | val |= CNTL_LCDBPP16; | 213 | /* |
214 | * PL110 cannot choose between 5551 and 565 modes in | ||
215 | * its control register | ||
216 | */ | ||
217 | if ((fb->dev->periphid & 0x000fffff) == 0x00041110) | ||
218 | val |= CNTL_LCDBPP16; | ||
219 | else if (fb->fb.var.green.length == 5) | ||
220 | val |= CNTL_LCDBPP16; | ||
221 | else | ||
222 | val |= CNTL_LCDBPP16_565; | ||
213 | break; | 223 | break; |
214 | case 32: | 224 | case 32: |
215 | val |= CNTL_LCDBPP24; | 225 | val |= CNTL_LCDBPP24; |