summaryrefslogtreecommitdiffstats
path: root/drivers/mci/imx-esdhc.c
diff options
context:
space:
mode:
authorAndrey Panov <rockford@yandex.ru>2015-01-17 15:54:35 +0300
committerSascha Hauer <s.hauer@pengutronix.de>2015-01-19 08:38:12 +0100
commit58475f4599ebd556d47d7f632a78f666d2dfcfd4 (patch)
treef2a851469c496297cb73f9bf578530c1c2a30281 /drivers/mci/imx-esdhc.c
parent78582e53dcb2c6f42282ddf27b66e5bc5b7202cc (diff)
downloadbarebox-58475f4599ebd556d47d7f632a78f666d2dfcfd4.tar.gz
barebox-58475f4599ebd556d47d7f632a78f666d2dfcfd4.tar.xz
MMC: IMX: Reset MMC_BOOT register after controller reset.
This helps with EMMC detection when booting from EMMC directly. Taken from u-boot. Signed-off-by: Andrey Panov <rockford@yandex.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/mci/imx-esdhc.c')
-rw-r--r--drivers/mci/imx-esdhc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/mci/imx-esdhc.c b/drivers/mci/imx-esdhc.c
index 239cd375fa..23bdc1fb15 100644
--- a/drivers/mci/imx-esdhc.c
+++ b/drivers/mci/imx-esdhc.c
@@ -471,6 +471,9 @@ static int esdhc_init(struct mci_host *mci, struct device_d *dev)
esdhc_write32(regs + SDHCI_CLOCK_CONTROL__TIMEOUT_CONTROL__SOFTWARE_RESET,
SYSCTL_HCKEN | SYSCTL_IPGEN);
+ /* RSTA doesn't reset MMC_BOOT register, so manually reset it */
+ esdhc_write32(regs + SDHCI_MMC_BOOT, 0);
+
/* Set the initial clock speed */
set_sysctl(mci, 400000);