]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
MMC: OMAP: Make board-h3.c uses new board-h3-mmc.c code
authorFelipe Balbi <felipe.lima@indt.org.br>
Mon, 26 Nov 2007 16:01:49 +0000 (12:01 -0400)
committerTony Lindgren <tony@atomide.com>
Wed, 28 Nov 2007 01:55:58 +0000 (17:55 -0800)
Make board-h3.c file uses new board-h3-mmc.c code.

This patch also:
- Introduces a new gpio_switch to get events when inserting and removing
  MMC/SD/SDIO cards to/from the slot.
- Enables the following options on omap_h3_1710_defconfig to use
  multislot support:
  - GPIO switch support
  - MSDOS fs support
  - VFAT fs support
  - Codepage 437
  - NLS ISO 8859-1

Signed-off-by: Felipe Balbi <felipe.lima@indt.org.br>
Signed-off-by: Anderson Briglia <anderson.briglia@indt.org.br>
Signed-off-by: Carlos Eduardo Aguiar <carlos.aguiar@indt.org.br>
Signed-off-by: David Cohen <david.cohen@indt.org.br>
Signed-off-by: Eduardo Valentin <eduardo.valentin@indt.org.br>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/configs/omap_h3_1710_defconfig
arch/arm/mach-omap1/Makefile
arch/arm/mach-omap1/board-h3.c

index 938d4fca731758007a859bc54a84178ae39a3e2f..5cebec75b0b6bb20948c54de867ac0fd0cafa4a6 100644 (file)
@@ -149,7 +149,7 @@ CONFIG_ARCH_OMAP1=y
 #
 # CONFIG_OMAP_RESET_CLOCKS is not set
 # CONFIG_OMAP_BOOT_TAG is not set
-# CONFIG_OMAP_GPIO_SWITCH is not set
+CONFIG_OMAP_GPIO_SWITCH=y
 CONFIG_OMAP_MUX=y
 # CONFIG_OMAP_MUX_DEBUG is not set
 CONFIG_OMAP_MUX_WARNINGS=y
@@ -1088,8 +1088,11 @@ CONFIG_DNOTIFY=y
 #
 # DOS/FAT/NT Filesystems
 #
-# CONFIG_MSDOS_FS is not set
-# CONFIG_VFAT_FS is not set
+CONFIG_FAT_FS=y
+CONFIG_MSDOS_FS=y
+CONFIG_VFAT_FS=y
+CONFIG_FAT_DEFAULT_CODEPAGE=437
+CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1"
 # CONFIG_NTFS_FS is not set
 
 #
@@ -1152,7 +1155,46 @@ CONFIG_MSDOS_PARTITION=y
 #
 # Native Language Support
 #
-# CONFIG_NLS is not set
+CONFIG_NLS=y
+CONFIG_NLS_DEFAULT="iso8859-1"
+CONFIG_NLS_CODEPAGE_437=y
+# CONFIG_NLS_CODEPAGE_737 is not set
+# CONFIG_NLS_CODEPAGE_775 is not set
+# CONFIG_NLS_CODEPAGE_850 is not set
+# CONFIG_NLS_CODEPAGE_852 is not set
+# CONFIG_NLS_CODEPAGE_855 is not set
+# CONFIG_NLS_CODEPAGE_857 is not set
+# CONFIG_NLS_CODEPAGE_860 is not set
+# CONFIG_NLS_CODEPAGE_861 is not set
+# CONFIG_NLS_CODEPAGE_862 is not set
+# CONFIG_NLS_CODEPAGE_863 is not set
+# CONFIG_NLS_CODEPAGE_864 is not set
+# CONFIG_NLS_CODEPAGE_865 is not set
+# CONFIG_NLS_CODEPAGE_866 is not set
+# CONFIG_NLS_CODEPAGE_869 is not set
+# CONFIG_NLS_CODEPAGE_936 is not set
+# CONFIG_NLS_CODEPAGE_950 is not set
+# CONFIG_NLS_CODEPAGE_932 is not set
+# CONFIG_NLS_CODEPAGE_949 is not set
+# CONFIG_NLS_CODEPAGE_874 is not set
+# CONFIG_NLS_ISO8859_8 is not set
+# CONFIG_NLS_CODEPAGE_1250 is not set
+# CONFIG_NLS_CODEPAGE_1251 is not set
+# CONFIG_NLS_ASCII is not set
+CONFIG_NLS_ISO8859_1=y
+# CONFIG_NLS_ISO8859_2 is not set
+# CONFIG_NLS_ISO8859_3 is not set
+# CONFIG_NLS_ISO8859_4 is not set
+# CONFIG_NLS_ISO8859_5 is not set
+# CONFIG_NLS_ISO8859_6 is not set
+# CONFIG_NLS_ISO8859_7 is not set
+# CONFIG_NLS_ISO8859_9 is not set
+# CONFIG_NLS_ISO8859_13 is not set
+# CONFIG_NLS_ISO8859_14 is not set
+# CONFIG_NLS_ISO8859_15 is not set
+# CONFIG_NLS_KOI8_R is not set
+# CONFIG_NLS_KOI8_U is not set
+# CONFIG_NLS_UTF8 is not set
 
 #
 # Distributed Lock Manager
index c52484391f2e2904a0bbd04ded650ded2391d0b7..dc0a8700843f2f193d9926f7a1ca69c5c99665d0 100644 (file)
@@ -26,7 +26,7 @@ obj-$(CONFIG_MACH_OMAP_GENERIC)               += board-generic.o
 obj-$(CONFIG_MACH_OMAP_PERSEUS2)       += board-perseus2.o
 obj-$(CONFIG_MACH_OMAP_FSAMPLE)                += board-fsample.o
 obj-$(CONFIG_MACH_OMAP_OSK)            += board-osk.o
-obj-$(CONFIG_MACH_OMAP_H3)             += board-h3.o
+obj-$(CONFIG_MACH_OMAP_H3)             += board-h3.o board-h3-mmc.o
 obj-$(CONFIG_MACH_VOICEBLUE)           += board-voiceblue.o
 obj-$(CONFIG_MACH_OMAP_PALMTE)         += board-palmte.o
 obj-$(CONFIG_MACH_OMAP_PALMZ71)                += board-palmz71.o
index 50daf702bd2ec1de6da79f670fe902c1152d8a7f..092c8144a60aa0d7658b915e3a0d92701988349b 100644 (file)
@@ -41,6 +41,7 @@
 #include <media/v4l2-int-device.h>
 
 #include <asm/arch/gpio.h>
+#include <asm/arch/gpio-switch.h>
 #include <asm/arch/gpioexpander.h>
 #include <asm/arch/irqs.h>
 #include <asm/arch/mux.h>
@@ -524,12 +525,13 @@ static struct omap_usb_config h3_usb_config __initdata = {
 
 static struct omap_mmc_config h3_mmc_config __initdata = {
        .mmc[0] = {
-               .enabled        = 1,
-               .power_pin      = -1,   /* tps65010 GPIO4 */
-               .switch_pin     = OMAP_MPUIO(1),
-       },
+               .enabled        = 1,
+               .wire4          = 1,
+       },
 };
 
+extern struct omap_mmc_platform_data h3_mmc_data;
+
 static struct omap_uart_config h3_uart_config __initdata = {
        .enabled_uarts = ((1 << 0) | (1 << 1) | (1 << 2)),
 };
@@ -545,6 +547,18 @@ static struct omap_board_config_kernel h3_config[] __initdata = {
        { OMAP_TAG_LCD,         &h3_lcd_config },
 };
 
+static struct omap_gpio_switch h3_gpio_switches[] __initdata = {
+       {
+               .name                   = "mmc_slot",
+               .gpio                   = OMAP_MPUIO(1),
+               .type                   = OMAP_GPIO_SWITCH_TYPE_COVER,
+               .debounce_rising        = 100,
+               .debounce_falling       = 0,
+               .notify                 = h3_mmc_slot_cover_handler,
+               .notify_data            = NULL,
+       },
+};
+
 #define H3_NAND_RB_GPIO_PIN    10
 
 static int nand_dev_ready(struct nand_platform_data *data)
@@ -689,6 +703,9 @@ static void __init h3_init(void)
        omap_board_config_size = ARRAY_SIZE(h3_config);
        omap_serial_init();
        omap_register_i2c_bus(1, 100, NULL, 0);
+       h3_mmc_init();
+       omap_register_gpio_switches(h3_gpio_switches,
+                                   ARRAY_SIZE(h3_gpio_switches));
 }
 
 static void __init h3_init_smc91x(void)