Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Fix MIMC200 board LCD init

This patch updates the LCD init code for the MIMC200 board.

V2 fixes a .yres typo and corrects an incorrect setup value
in the call to at32_add_device_lcdc()

Without this patch, the lcd setup is wrong and won't display images
correctly (if at all !!)

Signed-off-by: Mark Jackson <mpfj@mimc.co.uk>
Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>

authored by

Mark Jackson and committed by
Haavard Skinnemoen
c878b7d6 c076b993

+15 -14
+15 -14
arch/avr32/boards/mimc200/setup.c
··· 43 43 /* Initialized by bootloader-specific startup code. */ 44 44 struct tag *bootloader_tags __initdata; 45 45 46 - static struct fb_videomode __initdata tx14d14_modes[] = { 46 + static struct fb_videomode __initdata pt0434827_modes[] = { 47 47 { 48 - .name = "640x480 @ 60", 49 - .refresh = 60, 50 - .xres = 640, .yres = 480, 51 - .pixclock = KHZ2PICOS(11666), 48 + .name = "480x272 @ 72", 49 + .refresh = 72, 50 + .xres = 480, .yres = 272, 51 + .pixclock = KHZ2PICOS(10000), 52 52 53 - .left_margin = 80, .right_margin = 1, 54 - .upper_margin = 13, .lower_margin = 2, 55 - .hsync_len = 64, .vsync_len = 1, 53 + .left_margin = 1, .right_margin = 1, 54 + .upper_margin = 12, .lower_margin = 1, 55 + .hsync_len = 42, .vsync_len = 1, 56 56 57 57 .sync = 0, 58 58 .vmode = FB_VMODE_NONINTERLACED, ··· 60 60 }; 61 61 62 62 static struct fb_monspecs __initdata mimc200_default_monspecs = { 63 - .manufacturer = "HIT", 64 - .monitor = "TX14D14VM1BAB", 65 - .modedb = tx14d14_modes, 66 - .modedb_len = ARRAY_SIZE(tx14d14_modes), 63 + .manufacturer = "PT", 64 + .monitor = "PT0434827-A401", 65 + .modedb = pt0434827_modes, 66 + .modedb_len = ARRAY_SIZE(pt0434827_modes), 67 67 .hfmin = 14820, 68 68 .hfmax = 22230, 69 69 .vfmin = 60, 70 - .vfmax = 73.3, 70 + .vfmax = 85, 71 71 .dclkmax = 25200000, 72 72 }; 73 73 ··· 228 228 i2c_register_board_info(0, i2c_info, ARRAY_SIZE(i2c_info)); 229 229 230 230 at32_add_device_lcdc(0, &mimc200_lcdc_data, 231 - fbmem_start, fbmem_size, 1); 231 + fbmem_start, fbmem_size, 232 + ATMEL_LCDC_CONTROL | ATMEL_LCDC_ALT_CONTROL | ATMEL_LCDC_ALT_24B_DATA); 232 233 233 234 return 0; 234 235 }