mmc: sd: Handle SD3.0 cards not supporting UHS-I bus speed mode
authorChuanxiao Dong <chuanxiao.dong@intel.com>
Fri, 4 May 2012 09:54:55 +0000 (17:54 +0800)
committerbuildbot <buildbot@intel.com>
Tue, 8 May 2012 12:00:36 +0000 (05:00 -0700)
commitdb3aa310b0027604eeeddeff5aa489c554e1827b
tree18efa42182fc92bd7f25e860d7f3d09fcfcec16b
parent22680b90854f6f6c775df9a32d14cd09c39fc269
mmc: sd: Handle SD3.0 cards not supporting UHS-I bus speed mode

BZ: 34834

This patch is a variant of an upstream patch. It fixed SD cannot
change high spee mode issue. Below is the original commit info:

Here is Essential conditions to indicate Version 3.00 Card
(SD_SPEC=2 and SD_SPEC3=1) :
(1) The card shall support CMD6
(2) The card shall support CMD8
(3) The card shall support CMD42
(4) User area capacity shall be up to 2GB (SDSC) or 32GB (SDHC)
User area capacity shall be more than or equal to 32GB and
up to 2TB (SDXC)
(5) Speed Class shall be supported (SDHC or SDXC)

So even if SD card doesn't support any of the newly defined
UHS-I bus speed mode, it can advertise itself as SD3.0 cards
as long as it supports all the essential conditions of
SD3.0 cards. Given this, these type of cards should atleast
run in High Speed mode @50MHZ if it supports HS.

But current initialization sequence for SD3.0 cards is
such that these non-UHS-I SD3.0 cards runs in Default
Speed mode @25MHz.

This patch makes sure that these non-UHS-I SD3.0 cards run
in High Speed Mode @50MHz.

Change-Id: I780ac5d2d076fe56b8079bfd98fc234d301eef4b
Signed-off-by: Chuanxiao Dong <chuanxiao.dong@intel.com>
Reviewed-on: http://android.intel.com:8080/47435
Reviewed-by: Tang, Richard <richard.tang@intel.com>
Tested-by: Sun, Jianhua <jianhua.sun@intel.com>
Reviewed-by: buildbot <buildbot@intel.com>
Tested-by: buildbot <buildbot@intel.com>
drivers/mmc/core/sd.c
include/linux/mmc/card.h