diff options
author | Joe Perches <joe@perches.com> | 2014-08-07 01:10:46 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-08-07 03:01:27 +0200 |
commit | 8d73e0e7dc18a39b120cb85ec675d59516e0af1a (patch) | |
tree | 3b8910111c525a14ffe1acc77c22a86a8e0eeaad /scripts/checkpatch.pl | |
parent | checkpatch: change blank line after declaration type to "LINE_SPACING" (diff) | |
download | linux-8d73e0e7dc18a39b120cb85ec675d59516e0af1a.tar.xz linux-8d73e0e7dc18a39b120cb85ec675d59516e0af1a.zip |
checkpatch: quiet Kconfig help message checking
Editing Kconfig dependencies can emit unnecessary messages about missing
or too short help entries.
Only emit the message when adding help sections to Kconfig files.
Signed-off-by: Joe Perches <joe@perches.com>
Reported-by: Jean Delvare <jdelvare@suse.de>
Tested-by: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to '')
-rwxr-xr-x | scripts/checkpatch.pl | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 146e9f907280..df4250a8ad51 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -2052,7 +2052,7 @@ sub process { # Only applies when adding the entry originally, after that we do not have # sufficient context to determine whether it is indeed long enough. if ($realfile =~ /Kconfig/ && - $line =~ /.\s*config\s+/) { + $line =~ /^\+\s*config\s+/) { my $length = 0; my $cnt = $realcnt; my $ln = $linenr + 1; @@ -2065,10 +2065,11 @@ sub process { $is_end = $lines[$ln - 1] =~ /^\+/; next if ($f =~ /^-/); + last if (!$file && $f =~ /^\@\@/); - if ($lines[$ln - 1] =~ /.\s*(?:bool|tristate)\s*\"/) { + if ($lines[$ln - 1] =~ /^\+\s*(?:bool|tristate)\s*\"/) { $is_start = 1; - } elsif ($lines[$ln - 1] =~ /.\s*(?:---)?help(?:---)?$/) { + } elsif ($lines[$ln - 1] =~ /^\+\s*(?:---)?help(?:---)?$/) { $length = -1; } |