提交 d0e04938 编写于 作者: A Axel Lin 提交者: Chris Ball

mmc: sdhci-bcm2835: Use sdhci_pltfm_unregister instead of open coded

This avoid duplicated implementation.
Signed-off-by: NAxel Lin <axel.lin@ingics.com>
Acked-by: NStephen Warren <swarren@wwwdotorg.org>
Signed-off-by: NChris Ball <cjb@laptop.org>
上级 ff1acfd0
...@@ -178,13 +178,7 @@ static int bcm2835_sdhci_probe(struct platform_device *pdev) ...@@ -178,13 +178,7 @@ static int bcm2835_sdhci_probe(struct platform_device *pdev)
static int bcm2835_sdhci_remove(struct platform_device *pdev) static int bcm2835_sdhci_remove(struct platform_device *pdev)
{ {
struct sdhci_host *host = platform_get_drvdata(pdev); return sdhci_pltfm_unregister(pdev);
int dead = (readl(host->ioaddr + SDHCI_INT_STATUS) == 0xffffffff);
sdhci_remove_host(host, dead);
sdhci_pltfm_free(pdev);
return 0;
} }
static const struct of_device_id bcm2835_sdhci_of_match[] = { static const struct of_device_id bcm2835_sdhci_of_match[] = {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册