public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* checkpatch false positive.
@ 2010-08-11 16:35 Dave Jones
  2010-08-11 17:29 ` [PATCH] scripts/checkpatch.pl: Add additional attribute #defines Joe Perches
  0 siblings, 1 reply; 3+ messages in thread
From: Dave Jones @ 2010-08-11 16:35 UTC (permalink / raw)
  To: apw; +Cc: Linux Kernel

I just got this from a patch I merged..

ERROR: need consistent spacing around '*' (ctx:WxV)
#121: FILE: arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c:113:
+static struct pcc_cpu __percpu *pcc_cpu_info;
                                ^
which doesn't seem right.

	Dave


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH] scripts/checkpatch.pl: Add additional attribute #defines
  2010-08-11 16:35 checkpatch false positive Dave Jones
@ 2010-08-11 17:29 ` Joe Perches
  2010-08-18 11:30   ` Andy Whitcroft
  0 siblings, 1 reply; 3+ messages in thread
From: Joe Perches @ 2010-08-11 17:29 UTC (permalink / raw)
  To: Dave Jones; +Cc: apw, Linux Kernel, Andrew Morton

On Wed, 2010-08-11 at 12:35 -0400, Dave Jones wrote:
> I just got this from a patch I merged..
> 
> ERROR: need consistent spacing around '*' (ctx:WxV)
> #121: FILE: arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c:113:
> +static struct pcc_cpu __percpu *pcc_cpu_info;
>                                 ^
> which doesn't seem right.

Perhaps these need to be added to checkpatch.

Signed-off-by: Joe Perches <joe@perches.com>
---
 scripts/checkpatch.pl |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 2039acd..51ba019 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -150,6 +150,20 @@ our $Sparse	= qr{
 # We need \b after 'init' otherwise 'initconst' will cause a false positive in a check
 our $Attribute	= qr{
 			const|
+			__percpu|
+			__nocast|
+			__safe|
+			__bitwise__|
+			__packed__|
+			__packed2__|
+			__naked|
+			__maybe_unused|
+			__always_unused|
+			__noreturn|
+			__used|
+			__cold|
+			__noclone|
+			__deprecated|
 			__read_mostly|
 			__kprobes|
 			__(?:mem|cpu|dev|)(?:initdata|initconst|init\b)|





^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] scripts/checkpatch.pl: Add additional attribute #defines
  2010-08-11 17:29 ` [PATCH] scripts/checkpatch.pl: Add additional attribute #defines Joe Perches
@ 2010-08-18 11:30   ` Andy Whitcroft
  0 siblings, 0 replies; 3+ messages in thread
From: Andy Whitcroft @ 2010-08-18 11:30 UTC (permalink / raw)
  To: Joe Perches; +Cc: Dave Jones, Linux Kernel, Andrew Morton

On Wed, Aug 11, 2010 at 10:29:08AM -0700, Joe Perches wrote:
> On Wed, 2010-08-11 at 12:35 -0400, Dave Jones wrote:
> > I just got this from a patch I merged..
> > 
> > ERROR: need consistent spacing around '*' (ctx:WxV)
> > #121: FILE: arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c:113:
> > +static struct pcc_cpu __percpu *pcc_cpu_info;
> >                                 ^
> > which doesn't seem right.
> 
> Perhaps these need to be added to checkpatch.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

This one looks sane to me, I've pulled this into my tree.  The version
at the URL below should contain it for testing:

  http://www.kernel.org/pub/linux/kernel/people/apw/checkpatch/checkpatch.pl-testing

-apw

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-08-18 11:30 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-11 16:35 checkpatch false positive Dave Jones
2010-08-11 17:29 ` [PATCH] scripts/checkpatch.pl: Add additional attribute #defines Joe Perches
2010-08-18 11:30   ` Andy Whitcroft

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox