Skip to content
Commit 9cd76049 authored by Jingju Hou's avatar Jingju Hou Committed by Ulf Hansson
Browse files

mmc: sdhci-pxav3: fix platform_data is not initialized



pdev->dev.platform_data is not initialized if match is true in function
sdhci_pxav3_probe. Just local variable pdata is assigned the return value
from function pxav3_get_mmc_pdata().

static int sdhci_pxav3_probe(struct platform_device *pdev) {

    struct sdhci_pxa_platdata *pdata = pdev->dev.platform_data;
    ...
    if (match) {
		ret = mmc_of_parse(host->mmc);
		if (ret)
			goto err_of_parse;
		sdhci_get_of_property(pdev);
		pdata = pxav3_get_mmc_pdata(dev);
     }
     ...
}

Signed-off-by: default avatarJingju Hou <houjingj@marvell.com>
Fixes: b650352d

("mmc: sdhci-pxa: Add device tree support")
Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
parent cae13e79
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment