mmc: build fix: mmc_pm_notify is only available with CONFIG_PM=y
authorUwe Kleine-König <[email protected]>
Wed, 18 Aug 2010 16:25:38 +0000 (09:25 -0700)
committerLinus Torvalds <[email protected]>
Wed, 18 Aug 2010 16:34:05 +0000 (09:34 -0700)
This fixes a build breakage introduced by commit 4c2ef25fe0b8 ("mmc: fix
all hangs related to mmc/sd card insert/removal during suspend/resume")

Cc: David Brownell <[email protected]>
Cc: Alan Stern <[email protected]>
Cc: [email protected]
Cc: Andrew Morton <[email protected]>
Signed-off-by: Uwe Kleine-König <[email protected]>
Acked-by: Kukjin Kim <[email protected]>
Acked-by: Maxim Levitsky <[email protected]>
Acked-by: Randy Dunlap <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
drivers/mmc/core/host.c

index 0efe631e50cab2ddda5e6a98022e5b8e49f46705..d80cfdc8edd2663841894348fa33e7dc4e597b1e 100644 (file)
@@ -86,7 +86,9 @@ struct mmc_host *mmc_alloc_host(int extra, struct device *dev)
        init_waitqueue_head(&host->wq);
        INIT_DELAYED_WORK(&host->detect, mmc_rescan);
        INIT_DELAYED_WORK_DEFERRABLE(&host->disable, mmc_host_deeper_disable);
+#ifdef CONFIG_PM
        host->pm_notify.notifier_call = mmc_pm_notify;
+#endif
 
        /*
         * By default, hosts do not support SGIO or large requests.