diff --git a/arch/arm/boards/at91sam9m10g45ek/init.c b/arch/arm/boards/at91sam9m10g45ek/init.c index bb8b7ba..77d51b7 100644 --- a/arch/arm/boards/at91sam9m10g45ek/init.c +++ b/arch/arm/boards/at91sam9m10g45ek/init.c @@ -40,6 +40,26 @@ #include #include +/* + * board revision encoding + * bit 0-3: lcd type + * 0 => truly TFT1N4633-E (sam9m10g45-ek) + * 1 => LG philips LB043WQ1 (sam9m10-ekes and sam9g45-ekes) + */ +#define HAVE_LCD_TRULY_TFT1N4633E (0 << 0) +#define HAVE_LCD_LG_LB043WQ1 (1 << 0) +static void ek_set_board_revision(void) +{ + u32 rev; + +#ifdef CONFIG_LCD_LG_LB043WQ1 + rev = HAVE_LCD_LG_LB043WQ1; +#else + rev = HAVE_LCD_TRULY_TFT1N4633E; +#endif + armlinux_set_revision(rev); +} + static struct atmel_nand_data nand_pdata = { .ale = 21, .cle = 22, @@ -103,6 +123,7 @@ armlinux_set_bootparams((void *)(AT91_CHIPSELECT_6 + 0x100)); armlinux_set_architecture(MACH_TYPE_AT91SAM9M10G45EK); + ek_set_board_revision(); return 0; } diff --git a/arch/arm/mach-at91/Kconfig b/arch/arm/mach-at91/Kconfig index e5bd45e..52c5d4b 100644 --- a/arch/arm/mach-at91/Kconfig +++ b/arch/arm/mach-at91/Kconfig @@ -174,7 +174,8 @@ bool "Atmel AT91SAM9M10G45-EK Evaluation Kit" select HAVE_NAND_ATMEL_BUSWIDTH_16 help - Select this if you are using Atmel's AT91SAM9M10G45-EK Evaluation Kit. + Select this if you are using Atmel's AT91SAM9M10G45-EK Evaluation Kit + or AT91SAM9G45-EKES or AT91SAM9M10-EKES (for those 2 select the LG LCD) config MACH_PM9G45 @@ -205,4 +206,20 @@ with 2 SD/MMC Slots. This is the case for AT91SAM9G20-EK rev. C and onwards. +choice + prompt "LCD type" + depends on MACH_AT91SAM9M10G45EK + +config LCD_TRULY_TFT1N4633E + bool "truly TFT1N4633-E" + help + Found on AT91SAM9M10G45-EK + +config LCD_LG_LB043WQ1 + bool "LG philips LB043WQ1" + help + Found on AT91SAM9G45-EKES and AT91SAM9M10-EKES + +endchoice + endif