From patchwork Wed Feb 28 05:03:10 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leo Yan X-Patchwork-Id: 129918 Delivered-To: patch@linaro.org Received: by 10.46.66.2 with SMTP id p2csp609254lja; Tue, 27 Feb 2018 21:03:33 -0800 (PST) X-Google-Smtp-Source: AH8x227qYfgSlI1BhPbUB1cV17XDFSJRLmenIO32zA7Z2T4Gy4jRfU/arkTE2DolbOwma4M/hrfJ X-Received: by 2002:a17:902:848e:: with SMTP id c14-v6mr17061208plo.139.1519794213348; Tue, 27 Feb 2018 21:03:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519794213; cv=none; d=google.com; s=arc-20160816; b=AFkl0/F6C7BwDJIh/G7O5nueGv0ic/UaJwelwQIfu2/PdLE+ItzsqRlwzyka6+9Bo2 KvB6JnvfKv+Qt9GVzgM97sffppdMPoTG+NGAckcMknNaq5v9/ML0X4u2Vn+ijU7tRJp/ EYU/+EOS9HdghayroOWjlszPnRrAZCUgCC+2tgQ4pfrDYdWX7x0aS+SuhJFp4ZIHkj3u B29vYWDvGGAkSSKlexJx76JiYeFH+xWhXGtlwK48OGpGXW6Imdq8X3nZbtvdsWn7J4X3 Ju85gw3VAg/menoPoIDgycH/tv161fZrEVExUyaOtukGVUzGxwDnNxHMCFm11gPdhNV/ SYGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=PpPGTKHwekDmakOzk9DroM+ct7hqSCW44JGx0/MRfYA=; b=HIpg4AyYy9Te4kk1Qp7qsM7o2x0wOjzQRyZMM2Y5rYesO7fhlmSkM2meaQXU5P2AGo HwGmkJsFIw+O/W9+jhI0MA6MfvYWkjfBMs+ckC/ryZA/URnSXmcoS1vREN3LI0Of65Qt IOqDqhkJofPq6VLrqel9tASopTrbgJlWyITMvtWqYC+QI9caIiqlbsvrR4DwRNYP62V4 1bIYjchonuEhwa9arQZJFDF44Ikd5G7a2yhV24Ygcve+9NOcoz69FHsxAt2/qcDupxPa D95g+m/jQlgUfG8Nd86VSx/0SutH2+l+cxM9TUNc5P+YByJ7UY1RXSTgFGIcKUUScmgx rW8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dikec847; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d21si625632pfk.328.2018.02.27.21.03.32; Tue, 27 Feb 2018 21:03:33 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dikec847; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751472AbeB1FD2 (ORCPT + 28 others); Wed, 28 Feb 2018 00:03:28 -0500 Received: from mail-qk0-f180.google.com ([209.85.220.180]:43736 "EHLO mail-qk0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750756AbeB1FD1 (ORCPT ); Wed, 28 Feb 2018 00:03:27 -0500 Received: by mail-qk0-f180.google.com with SMTP id j4so1492806qke.10 for ; Tue, 27 Feb 2018 21:03:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=PpPGTKHwekDmakOzk9DroM+ct7hqSCW44JGx0/MRfYA=; b=dikec847i14MMJy9rqS1HF/bz2JMnEmeKKdEvWWuFNHZ8THS0K8aEY3vtm4oUO4Oi+ Cco+cnOTDwuoSNdw41matKalWfIYvlew0B/Xle4JGtEM+fOmHZB3VnUG+Elxzo64C8hb rtfxfos7sXE0jnHvUiv3qd/eClpKnapxl5HSw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=PpPGTKHwekDmakOzk9DroM+ct7hqSCW44JGx0/MRfYA=; b=fhr5DEsiuzhBIxu9Kbti+xJMwH1gqD8NPREK1eMnWuhovPzYUeXu3DfAlE0LPIfsmQ q6eWeKSAGCLMGPZkHWJQSQjobYYcC4N6Vflw+PczRJo8Z57NQD31SBNBFxhU6meZFYig jb6umRiUJRhTGS/zHCX5yZXLDWg9UX5MlqCrUEG0Pr0iiaVHleirjn/xPVfE6a+ONRTl rv7R1JMVdKLu6ZrzwmfDeSyR2hP9k/DR854KLrXLDHfMW3vpjUMEeP2ELytsFTExieOp 3zlizMPnI/LD8j61zV6Jx/kBriZSXfsxikkoZVCrZiKDvWtmqyILH9V+NQrjAPjeoebe 0lKg== X-Gm-Message-State: APf1xPB8Dspuf53jv7GUKncSgM3dbUOpeRe2ploe2jk71fl1VMFePJlc 1qEG8vlIaGW4kq446E9ovTxD4Q== X-Received: by 10.55.81.138 with SMTP id f132mr26711636qkb.163.1519794207066; Tue, 27 Feb 2018 21:03:27 -0800 (PST) Received: from localhost.localdomain ([45.77.212.61]) by smtp.gmail.com with ESMTPSA id u17sm574057qka.46.2018.02.27.21.03.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 27 Feb 2018 21:03:25 -0800 (PST) From: Leo Yan To: Andy Whitcroft , Joe Perches , linux-kernel@vger.kernel.org Cc: Leo Yan Subject: [PATCH RESEND v3] checkpatch: Fix checks for Kconfig help text Date: Wed, 28 Feb 2018 13:03:10 +0800 Message-Id: <1519794190-21416-1-git-send-email-leo.yan@linaro.org> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org If one patch has Kconfig section, the check script variable '$is_start' will be set by first 'config' line and the variable '$is_end' is to be set by the second 'config' line. But patches often has only one 'config' line so we have no chance to set '$is_end', as result below condition is invalid and it skips check for Kconfig description: if ($is_start && $is_end && $length < $min_conf_desc_length) { ...... } When script runs to this condition sentence it means the Kconfig section parsing has been completed, whatever '$is_end' is true or not. So removes '$is_end' from condition sentence. Signed-off-by: Leo Yan --- scripts/checkpatch.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 1.9.1 diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 3d40403..5cbc887 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -2828,7 +2828,7 @@ sub process { } $length++; } - if ($is_start && $is_end && $length < $min_conf_desc_length) { + if ($is_start && $length < $min_conf_desc_length) { WARN("CONFIG_DESCRIPTION", "please write a paragraph that describes the config symbol fully\n" . $herecurr); }