public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] checkpatch: Emit "NOTE: <types>" message only once after multiple files
@ 2015-06-17 17:08 Joe Perches
  0 siblings, 0 replies; only message in thread
From: Joe Perches @ 2015-06-17 17:08 UTC (permalink / raw)
  To: Andrew Morton; +Cc: Andy Whitcroft, LKML

Make this message similar to the "false positives" message
and emit it only once when scanning multiple files instead
of after each file scanned.

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

diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 69c4716..cb896a5 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -203,7 +203,7 @@ sub hash_save_array_words {
 sub hash_show_words {
 	my ($hashRef, $prefix) = @_;
 
-	if ($quiet == 0 && keys %$hashRef) {
+	if (keys %$hashRef) {
 		print "\nNOTE: $prefix message types:";
 		foreach my $word (sort keys %$hashRef) {
 			print " $word";
@@ -770,6 +770,9 @@ for my $filename (@ARGV) {
 }
 
 if (!$quiet) {
+	hash_show_words(\%use_type, "Used");
+	hash_show_words(\%ignore_type, "Ignored");
+
 	if ($^V lt 5.10.0) {
 		print << "EOM"
 
@@ -5644,9 +5647,6 @@ EOM
 		}
 	}
 
-	hash_show_words(\%use_type, "Used");
-	hash_show_words(\%ignore_type, "Ignored");
-
 	if ($clean == 0 && $fix &&
 	    ("@rawlines" ne "@fixed" ||
 	     $#fixed_inserted >= 0 || $#fixed_deleted >= 0)) {



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2015-06-17 17:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-17 17:08 [PATCH] checkpatch: Emit "NOTE: <types>" message only once after multiple files Joe Perches

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