[U-Boot] [RFC] [MMC] Is the HIGH_SPEED_SUPPORT bit checked wrong in mmc.c?
馬克泡
macpaul at gmail.com
Thu Nov 3 12:56:33 CET 2011
Hi all,
I have a problem on reading low speed card on my platform.
While high speed card were all correct.
However I have only SD 1.0 specification in hand, I'll try to get 3.0
version tomorrow.
But, I've found that in include/mmc.h
/* SCR definitions in different words */
#define SD_HIGHSPEED_BUSY 0x00020000
#define SD_HIGHSPEED_SUPPORTED 0x00020000
The both of these 2 defined the same value.
Then I've force the driver/mmc/mmc.c return 0 before
checking SD_HIGHSPEED_SUPPORTED bit. (workaround)
All operations on low speed card get correct now.
The mmcinfo, fatls and fatload works normally like high speed cards.
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -784,6 +784,7 @@ retry_scr:
}
/* If high-speed isn't supported, we return */
+ return 0;
if (!(__be32_to_cpu(switch_status[3]) & SD_HIGHSPEED_SUPPORTED))
return 0;
Because I have no specification in hand, I cannot check the bit fields
and send correct
patch if there is a problem until next week.
Could someone help to check it before this weekend ?
Thanks.
--
Best regards,
Macpaul Lin
More information about the U-Boot
mailing list