Skip to content

Commit d433dc6

Browse files
Dong Aishengcjb
authored andcommitted
mmc: sdhci-pltfm: export pltfm suspend/resume api
It is helpful for platform code to use to eliminate duplicated code. Signed-off-by: Dong Aisheng <[email protected]> Acked-by: Ulf Hansson <[email protected]> Signed-off-by: Chris Ball <[email protected]>
1 parent 429a5b4 commit d433dc6

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

drivers/mmc/host/sdhci-pltfm.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,19 +237,21 @@ int sdhci_pltfm_unregister(struct platform_device *pdev)
237237
EXPORT_SYMBOL_GPL(sdhci_pltfm_unregister);
238238

239239
#ifdef CONFIG_PM
240-
static int sdhci_pltfm_suspend(struct device *dev)
240+
int sdhci_pltfm_suspend(struct device *dev)
241241
{
242242
struct sdhci_host *host = dev_get_drvdata(dev);
243243

244244
return sdhci_suspend_host(host);
245245
}
246+
EXPORT_SYMBOL_GPL(sdhci_pltfm_suspend);
246247

247-
static int sdhci_pltfm_resume(struct device *dev)
248+
int sdhci_pltfm_resume(struct device *dev)
248249
{
249250
struct sdhci_host *host = dev_get_drvdata(dev);
250251

251252
return sdhci_resume_host(host);
252253
}
254+
EXPORT_SYMBOL_GPL(sdhci_pltfm_resume);
253255

254256
const struct dev_pm_ops sdhci_pltfm_pmops = {
255257
.suspend = sdhci_pltfm_suspend,

drivers/mmc/host/sdhci-pltfm.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,8 @@ static inline void *sdhci_pltfm_priv(struct sdhci_pltfm_host *host)
111111
}
112112

113113
#ifdef CONFIG_PM
114+
extern int sdhci_pltfm_suspend(struct device *dev);
115+
extern int sdhci_pltfm_resume(struct device *dev);
114116
extern const struct dev_pm_ops sdhci_pltfm_pmops;
115117
#define SDHCI_PLTFM_PMOPS (&sdhci_pltfm_pmops)
116118
#else

0 commit comments

Comments
 (0)