]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00209686-1:sdio:suspend/resume issue
authorB38613 <B38613@freescale.com>
Fri, 18 May 2012 10:14:56 +0000 (18:14 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Fri, 24 May 2013 06:34:39 +0000 (08:34 +0200)
1.add MMC_PM_WAKE_SDIO_IRQ capability, it should be
used together with MMC_PM_KEEP_POWER although not support
SDIO wakeup in function.
2.add MMC_CAP_NONREMOVABLE to describe imx6's three sdhc
devices's removable feature.Now emmc is permanent,sdio and
sd is removable instead of all default were permanent before.
According to this feature, detimine whether reinit card
or not in resume.

Signed-off-by: B38613 <B38613@freescale.com>
arch/arm/mach-mx6/board-mx6q_sabresd.c
arch/arm/plat-mxc/include/mach/esdhc.h

index 66c9df9bde689b5913992c5e8d0acebf560e79b8..3b0e86c81d2e2d20b31d6dc2b951dde431414100 100644 (file)
@@ -216,6 +216,7 @@ static const struct esdhc_platform_data mx6q_sabresd_sd2_data __initconst = {
        .keep_power_at_suspend = 1,
        .support_8bit = 1,
        .delay_line = 0,
+       .cd_type = ESDHC_CD_CONTROLLER,
 };
 
 static const struct esdhc_platform_data mx6q_sabresd_sd3_data __initconst = {
@@ -224,6 +225,7 @@ static const struct esdhc_platform_data mx6q_sabresd_sd3_data __initconst = {
        .keep_power_at_suspend = 1,
        .support_8bit = 1,
        .delay_line = 0,
+       .cd_type = ESDHC_CD_CONTROLLER,
 };
 
 static const struct esdhc_platform_data mx6q_sabresd_sd4_data __initconst = {
@@ -231,6 +233,7 @@ static const struct esdhc_platform_data mx6q_sabresd_sd4_data __initconst = {
        .keep_power_at_suspend = 1,
        .support_8bit = 1,
        .delay_line = 0,
+       .cd_type = ESDHC_CD_PERMANENT,
 };
 
 static const struct anatop_thermal_platform_data
index 1862c70ac13dd79ff653dbbcb264d09a6b98540b..71ce14956495839a2afb9128452d49f5647c1ed5 100644 (file)
 #ifndef __ASM_ARCH_IMX_ESDHC_H
 #define __ASM_ARCH_IMX_ESDHC_H
 
+enum cd_types {
+       ESDHC_CD_NONE,          /* no CD, neither controller nor gpio */
+       ESDHC_CD_CONTROLLER,    /* mmc controller internal CD */
+       ESDHC_CD_GPIO,          /* external gpio pin for CD */
+       ESDHC_CD_PERMANENT,     /* no CD, card permanently wired to host */
+};
+
 /**
  * struct esdhc_platform_data - optional platform data for esdhc on i.MX
  *
@@ -22,6 +29,7 @@
 struct esdhc_platform_data {
        unsigned int wp_gpio;
        unsigned int cd_gpio;
+       enum cd_types cd_type;
        unsigned int always_present;
        unsigned int support_18v;
        unsigned int support_8bit;