Signed-off-by: Jialing Fu <jlfu@xxxxxxxxxxx> Signed-off-by: Kevin Liu <kliu5@xxxxxxxxxxx> --- drivers/mmc/host/sdhci-pxav3.c | 7 +++++++ include/linux/platform_data/pxa_sdhci.h | 2 ++ 2 files changed, 9 insertions(+), 0 deletions(-) diff --git a/drivers/mmc/host/sdhci-pxav3.c b/drivers/mmc/host/sdhci-pxav3.c index fad0966..9f82b4c 100644 --- a/drivers/mmc/host/sdhci-pxav3.c +++ b/drivers/mmc/host/sdhci-pxav3.c @@ -311,6 +311,13 @@ static int sdhci_pxav3_probe(struct platform_device *pdev) platform_set_drvdata(pdev, host); + if (pdata->flags & PXA_FLAG_WAKEUP_HOST) { + device_init_wakeup(&pdev->dev, 1); + host->mmc->pm_flags |= MMC_PM_WAKE_SDIO_IRQ; + } else { + device_init_wakeup(&pdev->dev, 0); + } + return 0; err_add_host: diff --git a/include/linux/platform_data/pxa_sdhci.h b/include/linux/platform_data/pxa_sdhci.h index 27d3156..2af0c12 100644 --- a/include/linux/platform_data/pxa_sdhci.h +++ b/include/linux/platform_data/pxa_sdhci.h @@ -21,6 +21,8 @@ #define PXA_FLAG_CARD_PERMANENT (1<<1) /* Board design supports 8-bit data on SD/SDIO BUS */ #define PXA_FLAG_SD_8_BIT_CAPABLE_SLOT (1<<2) +/* SDIO device or SD Card wakeup host from sleep feature */ +#define PXA_FLAG_WAKEUP_HOST (1<<3) /* * struct pxa_sdhci_platdata() - Platform device data for PXA SDHCI -- 1.7.0.4 -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html