mmc: sdhci-s3c: Fix compilation warning
authorSachin Kamat <sachin.kamat@linaro.org>
Tue, 4 Dec 2012 11:33:07 +0000 (17:03 +0530)
committerChris Ball <cjb@laptop.org>
Fri, 7 Dec 2012 18:54:57 +0000 (13:54 -0500)
'sc' is used only when CONFIG_PM_RUNTIME is defined. Hence define it
conditionally.

Silences the following warning:
drivers/mmc/host/sdhci-s3c.c: In function ‘sdhci_s3c_notify_change’:
drivers/mmc/host/sdhci-s3c.c:378:20: warning: unused variable ‘sc’ [-Wunused-variable]

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
drivers/mmc/host/sdhci-s3c.c

index 99697696e7eb3e48f5851df4cfccd75b73cd40cf..82b7a7ad42172b28f50e7d509ad1eeb174c33ccb 100644 (file)
@@ -375,7 +375,9 @@ static struct sdhci_ops sdhci_s3c_ops = {
 static void sdhci_s3c_notify_change(struct platform_device *dev, int state)
 {
        struct sdhci_host *host = platform_get_drvdata(dev);
+#ifdef CONFIG_PM_RUNTIME
        struct sdhci_s3c *sc = sdhci_priv(host);
+#endif
        unsigned long flags;
 
        if (host) {