Re: [2.6 patch] drivers/base/: proper prototypes

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

 



On Thu, Jan 19, 2006 at 04:28:08AM +0100, Adrian Bunk wrote:
> On Wed, Jan 18, 2006 at 06:51:47PM -0800, Greg KH wrote:
> > On Thu, Jan 19, 2006 at 02:32:42AM +0100, Adrian Bunk wrote:
> > > This patch contains the following changes:
> > > - move prototypes to base.h
> > > - sys.c should #include "base.h" for getting the prototype of it's
> > >   global function system_bus_init()
> > > 
> > > Note that hidden in this patch there's a bugfix:
> > > 
> > > Caller and callee disagreed regarding the return type of 
> > > sysdev_shutdown().
> > > 
> > > 
> > > Signed-off-by: Adrian Bunk <[email protected]>
> > > 
> > > ---
> > > 
> > >  drivers/base/base.h           |    6 ++++++
> > >  drivers/base/power/resume.c   |    3 +--
> > >  drivers/base/power/shutdown.c |    2 +-
> > >  drivers/base/power/suspend.c  |    3 +--
> > >  drivers/base/sys.c            |    2 ++
> > >  5 files changed, 11 insertions(+), 5 deletions(-)
> > > 
> > > --- linux-2.6.16-rc1-mm1-full/drivers/base/base.h.old	2006-01-18 23:17:52.000000000 +0100
> > > +++ linux-2.6.16-rc1-mm1-full/drivers/base/base.h	2006-01-18 23:41:33.000000000 +0100
> > > @@ -1,6 +1,8 @@
> > >  
> > >  /* initialisation functions */
> > >  
> > > +#include <linux/device.h>
> > > +
> > 
> > Why is this extra #include needed?  It shouldn't be.
> 
> struct class_device and struct class_device_attribute are needed since 
> they are used in base.h .

But anyone who includes base.h will have already included this header
file, right?  That was my point.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux