mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-24 13:43:28 +00:00
mmc: sti_sdhci: Fix sdhci_setup_cfg() call.
host->mmc, host->mmc->dev and host->mmc->priv must be set
before calling sdhci_setup_cfg() to avoid hang during mmc
initialization.
Thanks to commit 3d296365e4
("mmc: sdhci: Add support for sdhci-caps-mask") which put
this issue into evidence.
Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
This commit is contained in:
parent
23441fbf2b
commit
2e01fcf17c
1 changed files with 3 additions and 3 deletions
|
@ -97,14 +97,14 @@ static int sti_sdhci_probe(struct udevice *dev)
|
|||
SDHCI_QUIRK_NO_HISPD_BIT;
|
||||
|
||||
host->host_caps = MMC_MODE_DDR_52MHz;
|
||||
host->mmc = &plat->mmc;
|
||||
host->mmc->dev = dev;
|
||||
host->mmc->priv = host;
|
||||
|
||||
ret = sdhci_setup_cfg(&plat->cfg, host, 50000000, 400000);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
host->mmc = &plat->mmc;
|
||||
host->mmc->priv = host;
|
||||
host->mmc->dev = dev;
|
||||
upriv->mmc = host->mmc;
|
||||
|
||||
return sdhci_probe(dev);
|
||||
|
|
Loading…
Reference in a new issue