[PATCH V2 Incremental] sdhci-spear: ST SPEAr based SDHCI controller glue

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patch is a incremental patch over V1 of sdhci-spear patch.
It contains following changes from V1:
- dev_get_platdata is used to get dev->platform_data

Signed-off-by: Viresh Kumar <viresh.kumar@xxxxxx>
---
 drivers/mmc/host/sdhci-spear.c |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/mmc/host/sdhci-spear.c b/drivers/mmc/host/sdhci-spear.c
index 6d3f740..d70c54c 100644
--- a/drivers/mmc/host/sdhci-spear.c
+++ b/drivers/mmc/host/sdhci-spear.c
@@ -41,8 +41,7 @@ static irqreturn_t sdhci_gpio_irq(int irq, void *dev_id)
 {
 	struct platform_device *pdev = dev_id;
 	struct sdhci_host *host = platform_get_drvdata(pdev);
-	struct spear_sdhci *sdhci =
-		(struct spear_sdhci *)(pdev->dev.platform_data);
+	struct spear_sdhci *sdhci = dev_get_platdata(&pdev->dev);
 	unsigned long gpio_irq_type;
 	int val;
 
@@ -112,7 +111,7 @@ static int __devinit sdhci_probe(struct platform_device *pdev)
 	}
 
 	/* overwrite platform_data */
-	sdhci->data = (struct sdhci_plat_data *)(pdev->dev.platform_data);
+	sdhci->data = dev_get_platdata(&pdev->dev);
 	pdev->dev.platform_data = sdhci;
 
 	if (pdev->dev.parent)
@@ -241,8 +240,7 @@ static int __devexit sdhci_remove(struct platform_device *pdev)
 {
 	struct sdhci_host *host = platform_get_drvdata(pdev);
 	struct resource *iomem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	struct spear_sdhci *sdhci =
-		(struct spear_sdhci *)(pdev->dev.platform_data);
+	struct spear_sdhci *sdhci = dev_get_platdata(&pdev->dev);
 	int dead;
 	u32 scratch;
 
-- 
1.6.0.2

--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux