Skip to content
Snippets Groups Projects
Commit eb9d3ca3 authored by Mateusz Kulikowski's avatar Mateusz Kulikowski Committed by Tom Rini
Browse files

mmc: msm_sdhci: Set mmc->dev pointer in msm_sdc_probe()


MMC core expects (now) valid mmc->dev pointer.
During conversion in commit cffe5d86 not every driver was updated.

This patch fixes crash while accessing MMC on
boards using Qualcomm SDHCI controller.

Signed-off-by: default avatarMateusz Kulikowski <mateusz.kulikowski@gmail.com>
Acked-by: default avatarSimon Glass <sjg@chromium.org>
parent abbaa23f
No related branches found
No related tags found
No related merge requests found
...@@ -136,7 +136,12 @@ static int msm_sdc_probe(struct udevice *dev) ...@@ -136,7 +136,12 @@ static int msm_sdc_probe(struct udevice *dev)
host->version = sdhci_readw(host, SDHCI_HOST_VERSION); host->version = sdhci_readw(host, SDHCI_HOST_VERSION);
/* automatically detect max and min speed */ /* automatically detect max and min speed */
return add_sdhci(host, 0, 0); ret = add_sdhci(host, 0, 0);
if (ret)
return ret;
host->mmc->dev = dev;
return 0;
} }
static int msm_sdc_remove(struct udevice *dev) static int msm_sdc_remove(struct udevice *dev)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment