提交 2c9054dc 编写于 作者: S Simon Baatz 提交者: Chris Ball

mmc: sh_mmcif: handle mmc_of_parse() errors during probe

Signed-off-by: NSimon Baatz <gmbnomis@gmail.com>
Acked-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: NChris Ball <cjb@laptop.org>
上级 ec0a7517
......@@ -1370,7 +1370,11 @@ static int sh_mmcif_probe(struct platform_device *pdev)
ret = -ENOMEM;
goto ealloch;
}
mmc_of_parse(mmc);
ret = mmc_of_parse(mmc);
if (ret < 0)
goto eofparse;
host = mmc_priv(mmc);
host->mmc = mmc;
host->addr = reg;
......@@ -1465,6 +1469,7 @@ static int sh_mmcif_probe(struct platform_device *pdev)
clk_put(host->hclk);
eclkget:
pm_runtime_disable(&pdev->dev);
eofparse:
mmc_free_host(mmc);
ealloch:
iounmap(reg);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册