lkml.org 
[lkml]   [2018]   [Dec]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] checkpatch.pl: Improve WARNING on Kconfig help
From
Date
On Wed, 2018-12-19 at 20:55 +0200, Igor Stoppa wrote:
> The checkpatch.pl script complains when the help section of a Kconfig
> entry is too short, but it doesn't really explain what it is looking
> for. Instead, it gives a generic warning that one should consider writing
> a paragraph.
>
> But what it *really* checks is that the help section is at least
> .$min_conf_desc_length lines long.
>
> Since the definition of what is a paragraph is not really carved in
> stone (and actually the primary descriptions is "5 sentences"), make the
> warning less ambiguous by expliciting the actual test condition, so that
> one doesn't have to read checkpatch.pl sources, to figure out the actual
> test.
[]
> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
[]
> @@ -2931,7 +2931,7 @@ sub process {
> }
> if ($is_start && $is_end && $length < $min_conf_desc_length) {
> WARN("CONFIG_DESCRIPTION",
> - "please write a paragraph that describes the config symbol fully\n" . $herecurr);
> + "expecting a 'help' section of " .$min_conf_desc_length . "+ lines\n" . $herecurr);

this could also be written without the concatenations

"expecting a 'help' section of $min_conf_desc_length or more lines\n" . $herecurr);
or maybe
"please write a paragraph that describes the config symbol fully ($min_conf_desc_length or more lines)\n" . $herecurr);

Andi?
You are the originator of this text.
Do you have an opinion?


\
 
 \ /
  Last update: 2018-12-19 20:18    [W:0.082 / U:1.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site