[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <E2CAE7F7B064EA49B5CE7EE9A4BB167D152EB8925D@KCINPUNHJCMS01.kpit.com>
Date: Thu, 30 Jun 2011 17:10:31 +0530
From: Ashish Jangam <Ashish.Jangam@...tcummins.com>
To: Mark Brown <broonie@...nsource.wolfsonmicro.com>
CC: "jic23@....ac.uk" <jic23@....ac.uk>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Dajun <dajun.chen@...semi.com>,
"grant@...retlab.ca" <grant@...retlab.ca>
Subject: RE: [PATCH 02/11] GPIO: DA9052 GPIO module v1
> -----Original Message-----
> From: Mark Brown [mailto:broonie@...nsource.wolfsonmicro.com]
> Sent: Thursday, June 30, 2011 11:07 AM
> To: Ashish Jangam
> Cc: jic23@....ac.uk; linux-kernel@...r.kernel.org; Dajun; grant@...retlab.ca
> Subject: Re: [PATCH 02/11] GPIO: DA9052 GPIO module v1
>
> On Wed, Jun 29, 2011 at 07:23:11PM +0530, ashishj3 wrote:
>
> > DA9052 PMIC has 16 bit GPIO bus for peripheral control.
> >
> > This patch add support for the GPIO pins on the DA9052.
>
> > + gpio->da9052 = dev_get_drvdata(pdev->dev.parent);
> > + pdata = gpio->da9052->dev->platform_data;
> > +
> > + if (pdata == NULL) {
> > + dev_err(&pdev->dev, "Failed no platform data for GPIO\n");
> > + ret = -ENOMEM;
> > + goto err_mem;
> > + }
>
> Why insist on platform data? gpiolib can dynamically allocate a GPIO
> range to the device.
Do you mean to use gpiochip_reserve() in machine file and not to have ngpio
and base defined in GPIO platform driver but, this will fail the call to gpiochip_add()?
Can you elaborate on it?
Powered by blists - more mailing lists