aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2013-09-11 17:24:00 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-09-11 18:58:46 -0400
commitf95a7e6a462ed1338bd576ccb557ff86772a0776 (patch)
treead85c177e88e05a43b66bc519825ff291656410f /scripts
parent91bfe4843dff4426ca3a0dd1dab8454c1534022d (diff)
checkpatch: ignore #define TRACE_<foo> macros
The tracing subsystem uses slightly odd #defines to set path/directory locations for include files. These #defines can cause false positives for the complex macro tests so add exclusions for these specific #defines (TRACE_SYSTEM, TRACE_INCLUDE_FILE, TRACE_INCLUDE_PATH). Signed-off-by: Joe Perches <joe@perches.com> Cc: Sarah Sharp <sarah.a.sharp@linux.intel.com> Cc: Li Zefan <lizefan@huawei.com> Cc: Andy Whitcroft <apw@canonical.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/checkpatch.pl3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 3ba2db637384..db7778a8f414 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -3451,7 +3451,8 @@ sub process {
3451 $dstat !~ /^for\s*$Constant$/ && # for (...) 3451 $dstat !~ /^for\s*$Constant$/ && # for (...)
3452 $dstat !~ /^for\s*$Constant\s+(?:$Ident|-?$Constant)$/ && # for (...) bar() 3452 $dstat !~ /^for\s*$Constant\s+(?:$Ident|-?$Constant)$/ && # for (...) bar()
3453 $dstat !~ /^do\s*{/ && # do {... 3453 $dstat !~ /^do\s*{/ && # do {...
3454 $dstat !~ /^\({/) # ({... 3454 $dstat !~ /^\({/ && # ({...
3455 $ctx !~ /^.\s*#\s*define\s+TRACE_(?:SYSTEM|INCLUDE_FILE|INCLUDE_PATH)\b/)
3455 { 3456 {
3456 $ctx =~ s/\n*$//; 3457 $ctx =~ s/\n*$//;
3457 my $herectx = $here . "\n"; 3458 my $herectx = $here . "\n";