Skip to content

Commit

Permalink
checkpatch.pl: be silent when -q and --ignore is given
Browse files Browse the repository at this point in the history
Fix checkpatch.pl when both -q and --ignore are given and prevents it from
printing a

NOTE: Ignored message types: blah

messages.

E.g., if I use -q --ignore PREFER_PACKED,PREFER_ALIGNED, i see:

NOTE: Ignored message types: PREFER_ALIGNED PREFER_PACKED

It makes no sense to print this when -q is given.

Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Cc: Andy Whitcroft <apw@canonical.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Artem Bityutskiy authored and Linus Torvalds committed Mar 23, 2012
1 parent d1fe9c0 commit 1123268
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions scripts/checkpatch.pl
Original file line number Diff line number Diff line change
Expand Up @@ -3474,13 +3474,12 @@ sub process {
}
}

if (keys %ignore_type) {
if ($quiet == 0 && keys %ignore_type) {
print "NOTE: Ignored message types:";
foreach my $ignore (sort keys %ignore_type) {
print " $ignore";
}
print "\n";
print "\n" if ($quiet == 0);
print "\n\n";
}

if ($clean == 1 && $quiet == 0) {
Expand Down

0 comments on commit 1123268

Please sign in to comment.