summaryrefslogtreecommitdiff
path: root/drivers/mmc/fsl_esdhc.c
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2015-02-17 10:42:44 -0200
committerStefano Babic <sbabic@denx.de>2015-02-23 09:11:42 +0100
commitee0c538951018759eff4038db75e61b1cd040307 (patch)
tree612e1d55c9acee5252d0166b79fc99c32234ccd5 /drivers/mmc/fsl_esdhc.c
parentf022d36e8a4517b2a9d25ff2d75bd2459d0c68b1 (diff)
downloadu-boot-imx-ee0c538951018759eff4038db75e61b1cd040307.zip
u-boot-imx-ee0c538951018759eff4038db75e61b1cd040307.tar.gz
u-boot-imx-ee0c538951018759eff4038db75e61b1cd040307.tar.bz2
mmc: fsl_esdhc: Add support to force VSELECT set
Some boards cannot do voltage negotiation but need to set the VSELECT bit forcely to ensure it to work at 1.8V. This commit adds CONFIG_SYS_FSL_ESDHC_FORCE_VSELECT flag for this use. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Diffstat (limited to 'drivers/mmc/fsl_esdhc.c')
-rw-r--r--drivers/mmc/fsl_esdhc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/mmc/fsl_esdhc.c b/drivers/mmc/fsl_esdhc.c
index 6a3e147..67ee179 100644
--- a/drivers/mmc/fsl_esdhc.c
+++ b/drivers/mmc/fsl_esdhc.c
@@ -523,6 +523,10 @@ static int esdhc_init(struct mmc *mmc)
/* Set timout to the maximum value */
esdhc_clrsetbits32(&regs->sysctl, SYSCTL_TIMEOUT_MASK, 14 << 16);
+#ifdef CONFIG_SYS_FSL_ESDHC_FORCE_VSELECT
+ esdhc_setbits32(&regs->vendorspec, ESDHC_VENDORSPEC_VSELECT);
+#endif
+
return 0;
}