mmc: fix for v2.6.36
author黄涛 <huangtao@rock-chips.com>
Mon, 1 Aug 2011 03:24:42 +0000 (11:24 +0800)
committer黄涛 <huangtao@rock-chips.com>
Mon, 1 Aug 2011 03:24:42 +0000 (11:24 +0800)
drivers/mmc/core/core.c
drivers/mmc/core/host.c

index 53b5b4b04ceffa89433fb5b1c2071fc72e485321..3c7e63b416ef96c0b1bc3ee8fb62733fbac52ff8 100644 (file)
@@ -1928,8 +1928,6 @@ int mmc_resume_host(struct mmc_host *host)
 }
 EXPORT_SYMBOL(mmc_resume_host);
 
-///old driver add the function reforming to kernel2.6.38
-#if defined(CONFIG_SDMMC_RK29) && defined(CONFIG_SDMMC_RK29_OLD) 
 /* Do the card removal on suspend if card is assumed removeable
  * Do that in pm notifier while userspace isn't yet frozen, so we will be able
    to sync the card.
@@ -1985,8 +1983,6 @@ int mmc_pm_notify(struct notifier_block *notify_block,
 
        return 0;
 }
-#endif// endif---defined(CONFIG_SDMMC_RK29) && defined(CONFIG_SDMMC_RK29_OLD) 
-
 #endif
 
 #ifdef CONFIG_MMC_EMBEDDED_SDIO
index 04607b1604c8b2e31a1f1d0f99002109d5543834..ba684e6d2b6b4ce8e7d530b3a17cb9ab9468f797 100644 (file)
@@ -86,10 +86,8 @@ 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);
-#if defined(CONFIG_SDMMC_RK29) && defined(CONFIG_SDMMC_RK29_OLD)  // old driver, add pm reform to kernel2.6.38 
 #ifdef CONFIG_PM
        host->pm_notify.notifier_call = mmc_pm_notify;
-#endif
 #endif
 
        /*
@@ -142,11 +140,6 @@ int mmc_add_host(struct mmc_host *host)
        if (!(host->pm_flags & MMC_PM_IGNORE_PM_NOTIFY))
                register_pm_notifier(&host->pm_notify);
 
-#if defined(CONFIG_SDMMC_RK29) && defined(CONFIG_SDMMC_RK29_OLD)  // old driver, add pm reform to kernel2.6.38         
-        if (!(host->pm_flags & MMC_PM_IGNORE_PM_NOTIFY))
-          register_pm_notifier(&host->pm_notify);
-#endif
-
        return 0;
 }
 
@@ -162,10 +155,8 @@ EXPORT_SYMBOL(mmc_add_host);
  */
 void mmc_remove_host(struct mmc_host *host)
 {
-#if defined(CONFIG_SDMMC_RK29) && defined(CONFIG_SDMMC_RK29_OLD)  // old driver, add pm reform to kernel2.6.38 
        if (!(host->pm_flags & MMC_PM_IGNORE_PM_NOTIFY))
                unregister_pm_notifier(&host->pm_notify);
-#endif
 
        mmc_stop_host(host);