[RFC PATCH 06/21] mmc: sdhci-of-esdhc: consolidate parsing path
From: Shawn Lin
Date: Wed Jan 27 2016 - 00:11:56 EST
This patch remove mmc_of_parse and check return value
of sdhci_get_of_property.
Cc: yangbo lu <yangbo.lu@xxxxxxxxxxxxx>
Signed-off-by: Shawn Lin <shawn.lin@xxxxxxxxxxxxxx>
---
drivers/mmc/host/sdhci-of-esdhc.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/mmc/host/sdhci-of-esdhc.c b/drivers/mmc/host/sdhci-of-esdhc.c
index 83b1226..7fc0edc 100644
--- a/drivers/mmc/host/sdhci-of-esdhc.c
+++ b/drivers/mmc/host/sdhci-of-esdhc.c
@@ -600,7 +600,9 @@ static int sdhci_esdhc_probe(struct platform_device *pdev)
esdhc_init(pdev, host);
- sdhci_get_of_property(pdev);
+ ret = sdhci_get_of_property(pdev);
+ if (ret)
+ goto err;
pltfm_host = sdhci_priv(host);
esdhc = pltfm_host->priv;
@@ -629,11 +631,6 @@ static int sdhci_esdhc_probe(struct platform_device *pdev)
host->quirks2 |= SDHCI_QUIRK2_BROKEN_HOST_CONTROL;
}
- /* call to generic mmc_of_parse to support additional capabilities */
- ret = mmc_of_parse(host->mmc);
- if (ret)
- goto err;
-
mmc_of_parse_voltage(np, &host->ocr_mask);
ret = sdhci_add_host(host);
--
2.3.7