Re: [PATCH resend] Make the dev_*() family of macros in device.hcomplete

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

 



On Thu, Nov 01, 2007 at 04:57:00PM -0700, Andrew Morton wrote:
> On Tue, 30 Oct 2007 08:40:08 -0700
> Greg KH <[email protected]> wrote:
> 
> > On Tue, Oct 30, 2007 at 05:11:24AM -0700, Medve Emilian-EMMEDVE1 wrote:
> > > Hi Greg K-H,
> > > 
> > > 
> > > > > +#define dev_info(dev, format, arg...)		\
> > > > > +	dev_printk(KERN_INFO, dev, format, ## arg)
> > > > > +
> > > > >  #ifdef DEBUG
> > > > >  #define dev_dbg(dev, format, arg...)		\
> > > > > -	dev_printk(KERN_DEBUG , dev , format , ## arg)
> > > > > +	dev_printk(KERN_DEBUG, dev, format, ## arg)
> > > > 
> > > > Those extra spaces are there for a good reason, older versions of gcc
> > > > are broken without it.  So please, put them all back...
> > > 
> > > You mean I should add spaces before commas only where they were
> > > initially or to all new code and/or macros?
> > 
> > Put it back where it was, and do the same for all other macros.
> > 
> > > I've observed other kernel code and more often there are no spaces
> > > before commas. I'm asking because the CodingStyle document is not very
> > > explicit about this rule.
> > 
> > This is a gcc rule, for variable length macros, not a CodingStyle
> > guideline.  It just will not work without it :)
> > 
> 
> The space-before-a-comma requirement was for gcc-2.95, iirc.
> 
> It got to the stage where I was the only person testing with gcc-2.95 so I
> spent inordinate amounts of time adding spaces before people's newly-added
> commas.  Fortunately we abamdoned that gcc version so the space-before-a-comma
> requirement no longer exists.

Ah, ok, that's good to remember in the future, 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