aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy Whitcroft <[email protected]>2012-03-23 15:02:17 -0700
committerLinus Torvalds <[email protected]>2012-03-23 16:58:36 -0700
commitb9df76ac76da351cd4f6ba52369e9a64e9ab686d (patch)
treeb02d82a012dbf249d8b8f89b530681eaa26e52bd
parentdaebc534ac15f991961a5bb433e515988220e9bf (diff)
checkpatch: allow simple character constants in #defines
Signed-off-by: Andy Whitcroft <[email protected]> Cc: Joe Perches <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
-rwxr-xr-xscripts/checkpatch.pl1
1 files changed, 1 insertions, 0 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 061c28e7bcfa..95ba30a24dcf 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -2911,6 +2911,7 @@ sub process {
$dstat !~ /^(?:$Ident|-?$Constant),$/ && # 10, // foo(),
$dstat !~ /^(?:$Ident|-?$Constant);$/ && # foo();
$dstat !~ /^(?:$Ident|-?$Constant)$/ && # 10 // foo()
+ $dstat !~ /^'X'$/ && # character constants
$dstat !~ /$exceptions/ &&
$dstat !~ /^\.$Ident\s*=/ && # .foo =
$dstat !~ /^do\s*$Constant\s*while\s*$Constant;?$/ && # do {...} while (...); // do {...} while (...)