lkml.org 
[lkml]   [2008]   [Jul]   [22]   [last100]   RSS Feed
Views: [more markup]   [less markup]   [headers]   [forward]  
 
Messages in this thread
/
DateTue, 22 Jul 2008 16:50:56 -0700
FromAndrew Morton <>
SubjectRe: [patch 2.6.26-rc5] gpio: sysfs interface (updated)
On Tue, 22 Jul 2008 16:28:24 -0700
Greg KH <greg@kroah.com> wrote:

> On Tue, Jul 22, 2008 at 04:27:51PM -0700, Andrew Morton wrote:
> > On Thu, 12 Jun 2008 11:53:36 -0700
> > David Brownell <david-b@pacbell.net> wrote:
> > 
> > > This adds a simple sysfs interface for GPIOs.
> > 
> > device_create_drvdata() has magically vanished from today's linux-next,
> > so this code doesn't compile any more.
> > 
> > This:
> > 
> > --- a/drivers/gpio/gpiolib.c~gpio-sysfs-interface-updated-gpio-linux-next-fixes-for-sysfs-support-fix
> > +++ a/drivers/gpio/gpiolib.c
> > @@ -453,8 +453,8 @@ int gpio_export(unsigned gpio, bool dire
> >  	if (status == 0) {
> >  		struct device	*dev;
> > 
> > -		dev = device_create_drvdata(&gpio_class, desc->chip->dev, 0,
> > -				desc, "gpio%d", gpio);
> > +		dev = device_create(&gpio_class, desc->chip->dev, 0, desc,
> > +					"gpio%d", gpio);
> 
> Should be NULL instead of 0 there, otherwise sparse will complain.

The third arg to device_create is a dev_t, so 0 is correct

Confused.


\
 
 \ /
  Last update: 2008-07-23 01:53    [W:0.402 / U:0.600 seconds]
©2003-2008 Jasper Spaans