lkml.org 
[lkml]   [2017]   [Mar]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 001/001] drivers/staging/vt6656/main_usb.c: checkpatch warning
From
Date
On Sat, 2017-04-01 at 04:46 +0100, Al Viro wrote:
> On Fri, Mar 31, 2017 at 08:36:22PM -0700, Joe Perches wrote:
> > On Sat, 2017-04-01 at 04:32 +0100, Al Viro wrote:
> > > On Fri, Mar 31, 2017 at 06:59:19PM -0700, Chewie Lin wrote:
> > > > Replace string with formatted arguments in the dev_warn() call. It removes
> > > > the checkpatch warning:
> > > >
> > > > WARNING: Prefer using "%s", __func__ to embedded function names
> >
> > []
> > > Again, checkpatch warning is badly written
> >
> > In your opinion, what wording would be better?
>
> MILD SUGGESTION: don't spell the function name out in format strings;
> "this_function: foo is %d", n
> might be better off as
> "%s: foo is %d", __func__, n
> in case you ever move it to another function or rename your function.

Thank you sir, may I have another.

checkpatch messages are single line.

\
 
 \ /
  Last update: 2017-04-01 05:54    [W:0.159 / U:0.148 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site