mmc: enable mmc suspend/resume for sdio device
Om Prakash Singh [Sat, 18 Feb 2012 16:35:21 +0000 (21:35 +0530)]
Bug 942826

Change-Id: Ie782f17c51e78994e0fc96da3fbbe2e6592f58dc
Signed-off-by: Rakesh Kumar <krakesh@nvidia.com>
Reviewed-on: http://git-master/r/84697
Reviewed-by: Rakesh Goyal <rgoyal@nvidia.com>
Tested-by: Rakesh Goyal <rgoyal@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>

drivers/mmc/host/sdhci.c

index 92ff372..c25f54f 100644 (file)
@@ -2327,7 +2327,7 @@ int sdhci_suspend_host(struct sdhci_host *host, pm_message_t state)
                        host->tuning_count * HZ);
        }
 
-       if (mmc->card && (mmc->card->type != MMC_TYPE_SDIO))
+       if (mmc->card)
                ret = mmc_suspend_host(host->mmc);
 
        if (mmc->pm_flags & MMC_PM_KEEP_POWER)
@@ -2371,15 +2371,12 @@ int sdhci_resume_host(struct sdhci_host *host)
        mmiowb();
 
        if (mmc->card) {
-               if (mmc->card->type != MMC_TYPE_SDIO) {
-                       ret = mmc_resume_host(host->mmc);
-               } else {
-                       /* Enable card interrupt as it is overwritten in sdhci_init */
-                       if ((mmc->caps & MMC_CAP_SDIO_IRQ) &&
-                               (mmc->pm_flags & MMC_PM_KEEP_POWER))
-                                       if (host->card_int_set)
-                                               mmc->ops->enable_sdio_irq(mmc, true);
-               }
+               ret = mmc_resume_host(host->mmc);
+               /* Enable card interrupt as it is overwritten in sdhci_init */
+               if ((mmc->caps & MMC_CAP_SDIO_IRQ) &&
+                       (mmc->pm_flags & MMC_PM_KEEP_POWER))
+                               if (host->card_int_set)
+                                       mmc->ops->enable_sdio_irq(mmc, true);
        }
 
        sdhci_enable_card_detection(host);