Patch 1~3 fix acmd23 unwork issue.
Currently the eMMC chip integrated on i.MX6Q SabreSD boards does not work.
(It's easily reproduced once you enable usdhc4 on sabresd, see patch 3)
It's caused by acmd setting bits are never cleared once it's been set
which cause the next normal commands to work abnormally.
Patch 4~6 fix DDR not supported on SabreSD board.
The SabreSD board does not have 1.8v signal voltage switch support for uSDHC,
thus it can not support UHS_DDR50 mode which can only run at 1.8v signal voltage.
The issue is that current mmc DDR mode support implemented in MMC core depends
on UHS_DDR50, which then cause such controller like uSDHC on SabreSD without 1.8v
capability can not support eMMC DDR mode too.
(But the SabreSD board does support eMMC DDR mode since the eMMC DDR mode can
work on either 1.8v or 3.3v)
So this patch gets rid of this limitation to let controller not support
1.8v signal voltage can also support eMMC DDR mode.
ChangeLog:
v1->v2: a minor change on patch1, switch the order of patch 4&5.
dropped patch 7: mmc: sdhci-esdhc-imx: add eMMC HS200 mode support
which will be in another series together with another extra fix on tuning
broken issue in latest Chris' tree.
Dong Aisheng (6):
mmc: sdhci: clear auto cmd setting bits for no data cmds
mmc: sdhci-esdhc-imx: add SDHCI_TRANSFER_MODE read function
ARM: dts: sabresd: add usdhc4 support
mmc: sdhci-esdhc-imx: fix cpas over write issue
mmc: sdhci-esdhc-imx: add MMC_CAP_1_8V_DDR for mx6
mmc: core: mmc DDR mode should not depend on UHS_DDR50
arch/arm/boot/dts/imx6qdl-sabresd.dtsi | 9 +++++++++
drivers/mmc/core/mmc.c | 8 ++------
drivers/mmc/host/sdhci-esdhc-imx.c | 19 ++++++++++++++++++-
drivers/mmc/host/sdhci.c | 7 ++++++-
4 files changed, 35 insertions(+), 8 deletions(-)
--
1.7.2.rc3
The auto cmd settings bits should be cleared before sending new commands
or we may receive command timeout error for normal commands due to wrongly
pre-sent auto cmd.
e.g. we receive CMD13 timeout error due to ACMD23 is wrongly enabled
by former data commands.
mmc2: new high speed DDR MMC card at address 0001
mmcblk1: mmc2:0001 SEM08G 7.39 GiB
mmcblk1boot0: mmc2:0001 SEM08G partition 1 2.00 MiB
mmcblk1boot1: mmc2:0001 SEM08G partition 2 2.00 MiB
mmcblk1rpmb: mmc2:0001 SEM08G partition 3 128 KiB
mmcblk1: p1 p2 p3 p4 < p5 p6 p7 >
mmc2: Timeout waiting for hardware interrupt.
mmcblk1boot1: unknown partition table
mmc2: Timeout waiting for hardware interrupt.
mmcblk1boot0: unknown partition table
Signed-off-by: Dong Aisheng <redacted>
---
drivers/mmc/host/sdhci.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
@@ -903,8 +903,13 @@ static void sdhci_set_transfer_mode(struct sdhci_host *host,u16mode;structmmc_data*data=cmd->data;-if(data==NULL)+if(data==NULL){+/* clear Auto CMD settings for no data CMDs */+mode=sdhci_readw(host,SDHCI_TRANSFER_MODE);+sdhci_writew(host,mode&~(SDHCI_TRNS_AUTO_CMD12|+SDHCI_TRNS_AUTO_CMD23),SDHCI_TRANSFER_MODE);return;+}WARN_ON(!host->data);
On Wed, Oct 30, 2013 at 12:09 PM, Dong Aisheng [off-list ref] wrote:
The auto cmd settings bits should be cleared before sending new commands
or we may receive command timeout error for normal commands due to wrongly
pre-sent auto cmd.
e.g. we receive CMD13 timeout error due to ACMD23 is wrongly enabled
by former data commands.
mmc2: new high speed DDR MMC card at address 0001
mmcblk1: mmc2:0001 SEM08G 7.39 GiB
mmcblk1boot0: mmc2:0001 SEM08G partition 1 2.00 MiB
mmcblk1boot1: mmc2:0001 SEM08G partition 2 2.00 MiB
mmcblk1rpmb: mmc2:0001 SEM08G partition 3 128 KiB
mmcblk1: p1 p2 p3 p4 < p5 p6 p7 >
mmc2: Timeout waiting for hardware interrupt.
mmcblk1boot1: unknown partition table
mmc2: Timeout waiting for hardware interrupt.
mmcblk1boot0: unknown partition table
Signed-off-by: Dong Aisheng <redacted>
Thanks for the patch, Dong.
This fixes the eMMC interrupt timeout issue on mx6qsabresd.
I think we should mark it for stable. At least 3.11 and 3.12 have this
issue and your patch fixes it.
Regards,
Fabio Estevam
Used to read out the correct value of SDHCI_TRANSFER_MODE register
for upper layer.
Signed-off-by: Dong Aisheng <redacted>
---
drivers/mmc/host/sdhci-esdhc-imx.c | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
We should use '|=' instead '=', or it may over write
the original caps assigned before this line.
Signed-off-by: Dong Aisheng <redacted>
---
drivers/mmc/host/sdhci-esdhc-imx.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
The MMC_CAP_UHS_DDR50 must work on 1.8v.
However, the eMMC DDR mode can work on either 1.8v or 3.3v and
should not depend on UHS_DDR50.
So get rid of this limitation to let controller without 1.8v
signal voltage support can also work for eMMC DDR mode if it claims.
Signed-off-by: Dong Aisheng <redacted>
---
drivers/mmc/core/mmc.c | 8 ++------
1 files changed, 2 insertions(+), 6 deletions(-)
On 30 October 2013 15:09, Dong Aisheng [off-list ref] wrote:
The MMC_CAP_UHS_DDR50 must work on 1.8v.
However, the eMMC DDR mode can work on either 1.8v or 3.3v and
should not depend on UHS_DDR50.
So get rid of this limitation to let controller without 1.8v
signal voltage support can also work for eMMC DDR mode if it claims.
Signed-off-by: Dong Aisheng <redacted>
1.7.2.rc3
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, Oct 30, 2013 at 10:09:47PM +0800, Dong Aisheng wrote:
Dong Aisheng (6):
mmc: sdhci: clear auto cmd setting bits for no data cmds
mmc: sdhci-esdhc-imx: add SDHCI_TRANSFER_MODE read function
ARM: dts: sabresd: add usdhc4 support
mmc: sdhci-esdhc-imx: fix cpas over write issue
mmc: sdhci-esdhc-imx: add MMC_CAP_1_8V_DDR for mx6
mmc: core: mmc DDR mode should not depend on UHS_DDR50
Hi Chris,
On Thu, Oct 31, 2013 at 3:04 PM, Shawn Guo [off-list ref] wrote:
On Wed, Oct 30, 2013 at 10:09:47PM +0800, Dong Aisheng wrote:
quoted
Dong Aisheng (6):
mmc: sdhci: clear auto cmd setting bits for no data cmds
mmc: sdhci-esdhc-imx: add SDHCI_TRANSFER_MODE read function
ARM: dts: sabresd: add usdhc4 support
mmc: sdhci-esdhc-imx: fix cpas over write issue
mmc: sdhci-esdhc-imx: add MMC_CAP_1_8V_DDR for mx6
mmc: core: mmc DDR mode should not depend on UHS_DDR50
For the series:
Acked-by: Shawn Guo <redacted>
Would you help pick up this series?
Regards
Dong Aisheng