rk_emmc: fixed drmboot wr bug
authorkfx <kfx@rock-chips.com>
Tue, 10 Sep 2013 07:11:49 +0000 (15:11 +0800)
committerkfx <kfx@rock-chips.com>
Tue, 10 Sep 2013 07:11:49 +0000 (15:11 +0800)
drivers/mmc/card/block.c

index 38b0c374f7caf8affdd275096eb8eb7e0b6f8294..d2dfeaa9fe2c4753c0097fdf442fee69dbed0943 100644 (file)
@@ -2009,7 +2009,8 @@ static int mmc_blk_probe(struct mmc_card *card)
                        goto out;
        }
 #ifdef CONFIG_EMMC_RK
-       this_card = card;
+       if(HOST_IS_EMMC(card->host))
+               this_card = card;
 #endif
        return 0;
 
@@ -2024,7 +2025,8 @@ static void mmc_blk_remove(struct mmc_card *card)
        struct mmc_blk_data *md = mmc_get_drvdata(card);
 
 #ifdef CONFIG_EMMC_RK
-       this_card = NULL;
+       if(HOST_IS_EMMC(card->host))
+               this_card = NULL;
 #endif
        mmc_blk_remove_parts(card, md);
        mmc_claim_host(card->host);