From: B38613 Date: Wed, 25 Apr 2012 05:51:44 +0000 (+0800) Subject: ENGR00180768 sd:detect some sd2.0 cards to sd1.0 X-Git-Tag: v3.0.35-fsl~1004 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=dbfae2c1b2b21a204192e6a0cf0a934f92ea2d7b;p=karo-tx-linux.git ENGR00180768 sd:detect some sd2.0 cards to sd1.0 when SD_SPEC=2, no matter Physical Layer Spec v3.0 is supported or not, should both be recognized as SD2.0card. Signed-off-by: Zhou Jianzheng (cherry picked from commit 59f5c06bba9e426326346fc00c1524cb789d695a) --- diff --git a/drivers/mmc/core/sd.c b/drivers/mmc/core/sd.c index 5d9d7529e130..ae4b1af47f22 100644 --- a/drivers/mmc/core/sd.c +++ b/drivers/mmc/core/sd.c @@ -306,6 +306,9 @@ static int mmc_read_switch(struct mmc_card *card) goto out; } + if (status[13] & 0x02) + card->sw_caps.hs_max_dtr = 50000000; + if (card->scr.sda_spec3) { card->sw_caps.sd3_bus_mode = status[13]; @@ -348,9 +351,6 @@ static int mmc_read_switch(struct mmc_card *card) } card->sw_caps.sd3_curr_limit = status[7]; - } else { - if (status[13] & 0x02) - card->sw_caps.hs_max_dtr = 50000000; } out: