summaryrefslogtreecommitdiff
path: root/drivers/mmc/host/jz4740_mmc.c
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2013-06-09 21:10:03 +0200
committerChris Ball <cjb@laptop.org>2013-06-27 12:39:13 -0400
commit5d5c0350fc9533a1af3a43ee2331fec412679fcf (patch)
tree681237e1da92f5212bb7d2c5779dda06387ea7c8 /drivers/mmc/host/jz4740_mmc.c
parent8a489aa10cf84e54de812bd964f3520504460b94 (diff)
mmc: jz4740: Use SIMPLE_DEV_PM_OPS
It's a bit shorter than open-conding it. While we are at it also make jz4740_mmc_pm_ops static. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc/host/jz4740_mmc.c')
-rw-r--r--drivers/mmc/host/jz4740_mmc.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/mmc/host/jz4740_mmc.c b/drivers/mmc/host/jz4740_mmc.c
index 3f86592e97a2..c97ef6dd5fb6 100644
--- a/drivers/mmc/host/jz4740_mmc.c
+++ b/drivers/mmc/host/jz4740_mmc.c
@@ -967,7 +967,7 @@ static int jz4740_mmc_remove(struct platform_device *pdev)
return 0;
}
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
static int jz4740_mmc_suspend(struct device *dev)
{
@@ -991,13 +991,8 @@ static int jz4740_mmc_resume(struct device *dev)
return 0;
}
-const struct dev_pm_ops jz4740_mmc_pm_ops = {
- .suspend = jz4740_mmc_suspend,
- .resume = jz4740_mmc_resume,
- .poweroff = jz4740_mmc_suspend,
- .restore = jz4740_mmc_resume,
-};
-
+static SIMPLE_DEV_PM_OPS(jz4740_mmc_pm_ops, jz4740_mmc_suspend,
+ jz4740_mmc_resume);
#define JZ4740_MMC_PM_OPS (&jz4740_mmc_pm_ops)
#else
#define JZ4740_MMC_PM_OPS NULL