Commit d433dc63 authored by Dong Aisheng's avatar Dong Aisheng Committed by Chris Ball

mmc: sdhci-pltfm: export pltfm suspend/resume api

It is helpful for platform code to use to eliminate duplicated code.
Signed-off-by: default avatarDong Aisheng <b29396@freescale.com>
Acked-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
Signed-off-by: default avatarChris Ball <cjb@laptop.org>
parent 429a5b45
...@@ -237,19 +237,21 @@ int sdhci_pltfm_unregister(struct platform_device *pdev) ...@@ -237,19 +237,21 @@ int sdhci_pltfm_unregister(struct platform_device *pdev)
EXPORT_SYMBOL_GPL(sdhci_pltfm_unregister); EXPORT_SYMBOL_GPL(sdhci_pltfm_unregister);
#ifdef CONFIG_PM #ifdef CONFIG_PM
static int sdhci_pltfm_suspend(struct device *dev) int sdhci_pltfm_suspend(struct device *dev)
{ {
struct sdhci_host *host = dev_get_drvdata(dev); struct sdhci_host *host = dev_get_drvdata(dev);
return sdhci_suspend_host(host); return sdhci_suspend_host(host);
} }
EXPORT_SYMBOL_GPL(sdhci_pltfm_suspend);
static int sdhci_pltfm_resume(struct device *dev) int sdhci_pltfm_resume(struct device *dev)
{ {
struct sdhci_host *host = dev_get_drvdata(dev); struct sdhci_host *host = dev_get_drvdata(dev);
return sdhci_resume_host(host); return sdhci_resume_host(host);
} }
EXPORT_SYMBOL_GPL(sdhci_pltfm_resume);
const struct dev_pm_ops sdhci_pltfm_pmops = { const struct dev_pm_ops sdhci_pltfm_pmops = {
.suspend = sdhci_pltfm_suspend, .suspend = sdhci_pltfm_suspend,
......
...@@ -111,6 +111,8 @@ static inline void *sdhci_pltfm_priv(struct sdhci_pltfm_host *host) ...@@ -111,6 +111,8 @@ static inline void *sdhci_pltfm_priv(struct sdhci_pltfm_host *host)
} }
#ifdef CONFIG_PM #ifdef CONFIG_PM
extern int sdhci_pltfm_suspend(struct device *dev);
extern int sdhci_pltfm_resume(struct device *dev);
extern const struct dev_pm_ops sdhci_pltfm_pmops; extern const struct dev_pm_ops sdhci_pltfm_pmops;
#define SDHCI_PLTFM_PMOPS (&sdhci_pltfm_pmops) #define SDHCI_PLTFM_PMOPS (&sdhci_pltfm_pmops)
#else #else
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment