Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755790Ab1DFLMX (ORCPT ); Wed, 6 Apr 2011 07:12:23 -0400 Received: from mail-wy0-f174.google.com ([74.125.82.174]:52680 "EHLO mail-wy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755360Ab1DFLLO (ORCPT ); Wed, 6 Apr 2011 07:11:14 -0400 From: Jamie Iles To: linux-kernel@vger.kernel.org Cc: linux@arm.linux.org.uk, tglx@linutronix.de, cbouatmailru@gmail.com, grant.likely@secretlab.ca, arnd@arndb.de, nico@fluxnic.net, Jamie Iles Subject: [RFC PATCH 2/7] basic_mmio_gpio: convert to platform_{get,set}_drvdata() Date: Wed, 6 Apr 2011 12:10:58 +0100 Message-Id: <1302088263-12714-3-git-send-email-jamie@jamieiles.com> X-Mailer: git-send-email 1.7.4 In-Reply-To: <1302088263-12714-1-git-send-email-jamie@jamieiles.com> References: <1302088263-12714-1-git-send-email-jamie@jamieiles.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1285 Lines: 40 Use the platform drvdata helpers rather than working on the struct device itself. Signed-off-by: Jamie Iles Cc: Anton Vorontsov Cc: Grant Likely --- drivers/gpio/basic_mmio_gpio.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/basic_mmio_gpio.c b/drivers/gpio/basic_mmio_gpio.c index 26f84e2..e6cce48 100644 --- a/drivers/gpio/basic_mmio_gpio.c +++ b/drivers/gpio/basic_mmio_gpio.c @@ -296,7 +296,7 @@ static int __devinit bgpio_probe(struct platform_device *pdev) else bgc->gc.base = -1; - dev_set_drvdata(dev, bgc); + platform_set_drvdata(pdev, bgc); ret = gpiochip_add(&bgc->gc); if (ret) @@ -307,7 +307,7 @@ static int __devinit bgpio_probe(struct platform_device *pdev) static int __devexit bgpio_remove(struct platform_device *pdev) { - struct bgpio_chip *bgc = dev_get_drvdata(&pdev->dev); + struct bgpio_chip *bgc = platform_get_drvdata(pdev); return gpiochip_remove(&bgc->gc); } -- 1.7.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/