diff options
author | Yann Gautier <yann.gautier@foss.st.com> | 2022-09-13 14:23:45 +0300 |
---|---|---|
committer | Jaehoon Chung <jh80.chung@samsung.com> | 2022-10-24 12:02:07 +0300 |
commit | 27fbce4326a4d2134791784e054c7acb62ee6761 (patch) | |
tree | 90316aedd731d707bba9e9fe985bc724c99fea70 | |
parent | be1872982e425375a7da6ac75da946f9d15df405 (diff) | |
download | u-boot-27fbce4326a4d2134791784e054c7acb62ee6761.tar.xz |
mmc: stm32_sdmmc2: protect against unsupported modes
The UHS modes for SD, HS200 and HS400 modes for eMMC are not supported
by the stm32_sdmmc2 driver.
Make it clear by removing the corresponding caps after parsing the DT.
Signed-off-by: Yann Gautier <yann.gautier@foss.st.com>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
-rw-r--r-- | drivers/mmc/stm32_sdmmc2.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mmc/stm32_sdmmc2.c b/drivers/mmc/stm32_sdmmc2.c index 952d02f9b8..d42262c14f 100644 --- a/drivers/mmc/stm32_sdmmc2.c +++ b/drivers/mmc/stm32_sdmmc2.c @@ -675,6 +675,8 @@ static int stm32_sdmmc2_of_to_plat(struct udevice *dev) if (ret) return ret; + cfg->host_caps &= ~(UHS_CAPS | MMC_MODE_HS200 | MMC_MODE_HS400 | MMC_MODE_HS400_ES); + ret = clk_get_by_index(dev, 0, &plat->clk); if (ret) return ret; |