[PATCH] pinctrl: bcm2835: Use existing pointer to struct device

Tobias Klauser tklauser at distanz.ch
Mon Oct 8 05:40:36 EDT 2012


The pointer to "pdev->dev" is already stored in "dev", so use it in
devm_request_and_ioremap().

Signed-off-by: Tobias Klauser <tklauser at distanz.ch>
---
 drivers/pinctrl/pinctrl-bcm2835.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/pinctrl/pinctrl-bcm2835.c b/drivers/pinctrl/pinctrl-bcm2835.c
index a4adee6..3e0cc0d 100644
--- a/drivers/pinctrl/pinctrl-bcm2835.c
+++ b/drivers/pinctrl/pinctrl-bcm2835.c
@@ -960,7 +960,7 @@ static int __devinit bcm2835_pinctrl_probe(struct platform_device *pdev)
 		return err;
 	}
 
-	pc->base = devm_request_and_ioremap(&pdev->dev, &iomem);
+	pc->base = devm_request_and_ioremap(dev, &iomem);
 	if (!pc->base)
 		return -EADDRNOTAVAIL;
 
-- 
1.7.5.4




More information about the linux-rpi-kernel mailing list