mmc: sdhci-pci: Use SET_RUNTIME_PM_OPS macro to set runtime pm callbacks
authorPeter Griffin <peter.griffin@linaro.org>
Tue, 12 Aug 2014 16:14:28 +0000 (17:14 +0100)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 9 Sep 2014 11:59:06 +0000 (13:59 +0200)
This allows us to get rid of the #else condition, as the macro compiles
away to nothing if not enabled.

Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/sdhci-pci.c

index c3a1debc9289860755a207cf1315ef544bdda21c..310ecbcdfb7fa07f571adc82e05e257c47fcaefa 100644 (file)
@@ -1269,20 +1269,13 @@ static int sdhci_pci_runtime_idle(struct device *dev)
        return 0;
 }
 
-#else
-
-#define sdhci_pci_runtime_suspend      NULL
-#define sdhci_pci_runtime_resume       NULL
-#define sdhci_pci_runtime_idle         NULL
-
 #endif
 
 static const struct dev_pm_ops sdhci_pci_pm_ops = {
        .suspend = sdhci_pci_suspend,
        .resume = sdhci_pci_resume,
-       .runtime_suspend = sdhci_pci_runtime_suspend,
-       .runtime_resume = sdhci_pci_runtime_resume,
-       .runtime_idle = sdhci_pci_runtime_idle,
+       SET_RUNTIME_PM_OPS(sdhci_pci_runtime_suspend,
+                       sdhci_pci_runtime_resume, sdhci_pci_runtime_idle)
 };
 
 /*****************************************************************************\
This page took 0.027501 seconds and 5 git commands to generate.