Skip to contentSkip to conversation

checkpatch: don't check c99 types like uint8_t under tools

PATCH New [email protected] 1 participant 1 message Dec 13, 2016 Checkpatch

lore
Share & tools
lore
#0 lore raw

PATCH 120/123 checkpatch: don't check c99 types like uint8_t under tools

From: Tomas Winkler <[email protected]>
Subject: checkpatch: don't check c99 types like uint8_t under tools

Tools contains user space code so uintX_t types are just fine.

---

 scripts/checkpatch.pl |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
scripts/checkpatch.pl renamed from scripts/checkpatch.pl~checkpatch-dont-check-c99-types-like-uint8_t-under-tools +2 -1
diff -puN scripts/checkpatch.pl~checkpatch-dont-check-c99-types-like-uint8_t-under-tools scripts/checkpatch.pl
@@ -5560,8 +5560,9 @@ sub process {
 			      "Using weak declarations can have unintended link defects\n" . $herecurr);
 		}
 
-# check for c99 types like uint8_t used outside of uapi/
+# check for c99 types like uint8_t used outside of uapi/ and tools/
 		if ($realfile !~ m@\binclude/uapi/@ &&
+		    $realfile !~ m@\btools/@ &&
 		    $line =~ /\b($Declare)\s*$Ident\s*[=;,\[]/) {
 			my $type = $1;
 			if ($type =~ /\b($typeC99Typedefs)\b/) {

_