SD1.00 wide-bus fix
authorAlagu Sankar <alagusankar@embwise.com>
Wed, 12 May 2010 09:38:24 +0000 (15:08 +0530)
committerAndy Fleming <afleming@freescale.com>
Wed, 13 Apr 2011 08:50:43 +0000 (03:50 -0500)
Fixed a bug wherein SD version 1.0 cards were not configured for 4-bit mode

Signed-off-by: Alagu Sankar <alagusankar@embwise.com>
drivers/mmc/mmc.c

index 6805b33f7a13285256c3a71f363e08fdb03d0199..9988cb1f242de1c7322b8e861f1a55ed1fb5b542 100644 (file)
@@ -512,6 +512,9 @@ retry_scr:
                        break;
        }
 
+       if (mmc->scr[0] & SD_DATA_4BIT)
+               mmc->card_caps |= MMC_MODE_4BIT;
+
        /* Version 1.0 doesn't support switching */
        if (mmc->version == SD_VERSION_1_0)
                return 0;
@@ -529,9 +532,6 @@ retry_scr:
                        break;
        }
 
-       if (mmc->scr[0] & SD_DATA_4BIT)
-               mmc->card_caps |= MMC_MODE_4BIT;
-
        /* If high-speed isn't supported, we return */
        if (!(__be32_to_cpu(switch_status[3]) & SD_HIGHSPEED_SUPPORTED))
                return 0;