diff mbox series

[6/6] mmc: core: Extend mmc_of_parse() to check for mmc-ddr-3_3v

Message ID 1485357143-23280-7-git-send-email-ulf.hansson@linaro.org
State New
Headers show
Series mmc: core: Enable mmc hosts to specify support for eMMC DDR 3.3V | expand

Commit Message

Ulf Hansson Jan. 25, 2017, 3:12 p.m. UTC
When mmc_of_parse() finds the binding, it sets the mmc cap,
MMC_CAP_3_3V_DDR, which informs the core whether eMMC DDR at 3.3V I/O is
supported by the mmc host.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

---
 drivers/mmc/core/host.c | 2 ++
 1 file changed, 2 insertions(+)

-- 
1.9.1
diff mbox series

Patch

diff --git a/drivers/mmc/core/host.c b/drivers/mmc/core/host.c
index 98f25ff..8f75a84 100644
--- a/drivers/mmc/core/host.c
+++ b/drivers/mmc/core/host.c
@@ -301,6 +301,8 @@  int mmc_of_parse(struct mmc_host *host)
 	if (of_property_read_bool(np, "wakeup-source") ||
 	    of_property_read_bool(np, "enable-sdio-wakeup")) /* legacy */
 		host->pm_caps |= MMC_PM_WAKE_SDIO_IRQ;
+	if (of_property_read_bool(np, "mmc-ddr-3_3v"))
+		host->caps |= MMC_CAP_3_3V_DDR;
 	if (of_property_read_bool(np, "mmc-ddr-1_8v"))
 		host->caps |= MMC_CAP_1_8V_DDR;
 	if (of_property_read_bool(np, "mmc-ddr-1_2v"))