summaryrefslogtreecommitdiff
path: root/drivers/mmc/host/sdhci-tegra.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc/host/sdhci-tegra.c')
-rwxr-xr-x[-rw-r--r--]drivers/mmc/host/sdhci-tegra.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c
index b6308d5a9572..a16aa2b53417 100644..100755
--- a/drivers/mmc/host/sdhci-tegra.c
+++ b/drivers/mmc/host/sdhci-tegra.c
@@ -283,6 +283,10 @@ static int tegra_sdhci_suspend(struct platform_device *pdev, pm_message_t state)
u16 clk;
unsigned int clock = 100000;
+ if (device_may_wakeup(&pdev->dev)) {
+ enable_irq_wake(host->sdhci->irq);
+ }
+
/* save interrupt status before suspending */
host->sdhci_ints = sdhci_readl(host->sdhci, SDHCI_INT_ENABLE);
@@ -320,6 +324,10 @@ static int tegra_sdhci_resume(struct platform_device *pdev)
if (host->card_always_on && is_card_sdio(host->sdhci->mmc->card)) {
int ret = 0;
+ if (device_may_wakeup(&pdev->dev)) {
+ disable_irq_wake(host->sdhci->irq);
+ }
+
/* soft reset SD host controller and enable interrupts */
ret = tegra_sdhci_restore(host->sdhci);
if (ret) {