Search Linux Wireless

Re: [PATCH 1/4] iwlwifi: Add __printf argument checking to __iwl_dbg

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

 



On Thu, 2012-05-10 at 10:34 -0700, Joe Perches wrote:
> On Thu, 2012-05-10 at 18:50 +0200, Johannes Berg wrote:
> > On Thu, 2012-05-10 at 09:38 -0700, Joe Perches wrote:
> > > Add gcc format and argument printf checking
> > > to reduce future defect introduction.
> []
> > >  #if defined(CONFIG_IWLWIFI_DEBUG) || defined(CONFIG_IWLWIFI_DEVICE_TRACING)
> > > +__printf(5, 6)
> > >  void __iwl_dbg(struct device *dev,
> > >  	       u32 level, bool limit, const char *function,
> > >  	       const char *fmt, ...);
> > 
> > But that looks a bit odd to me? It would seem more natural to me to put
> > the attribute after the parameter list?
> 
> It's an attribute of the function and
> this style is used almost everywhere
> in the kernel.

I also found that for the inline, it *has* to be there. Checkpatch
doesn't like it though if I put it in the same line as "static inline
void" ;-)

johannes

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux