mmc: sdio: remember new card RCA when redetecting card
[pandora-kernel.git] / drivers / mmc / core / sdio.c
index c9fbb77..db0f0b4 100644 (file)
@@ -395,6 +395,14 @@ static int mmc_sdio_init_card(struct mmc_host *host, u32 ocr,
                if (err)
                        goto remove;
 
+               /*
+                * Update oldcard with the new RCA received from the SDIO
+                * device -- we're doing this so that it's updated in the
+                * "card" struct when oldcard overwrites that later.
+                */
+               if (oldcard)
+                       oldcard->rca = card->rca;
+
                mmc_set_bus_mode(host, MMC_BUSMODE_PUSHPULL);
        }