From patchwork Sun Jan 29 12:34:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Jonathan_Neusch=C3=A4fer?= X-Patchwork-Id: 49965 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp1727329wrn; Sun, 29 Jan 2023 04:37:50 -0800 (PST) X-Google-Smtp-Source: AK7set9fG+pA5u1TL50yMMPspzr2VFUuzqeHjt2exrae/8KQGTlLhlFvCCovpHGSiPIYBFe56j/d X-Received: by 2002:a17:906:b310:b0:878:52cd:9006 with SMTP id n16-20020a170906b31000b0087852cd9006mr14338730ejz.69.1674995869817; Sun, 29 Jan 2023 04:37:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674995869; cv=none; d=google.com; s=arc-20160816; b=c6XVvf+Hmyr+RCpPaAECnq9hOAbMXJ5B03ifGyzeVQrF4epOk2mj19K+Lzbr+7qsLj 7efq73uaG5TiqhJleBIxaVVx8gkNAP2H+0jPSIQAehD0u1IFM5wn6NYIuKJejiSq80h7 2F6J607EL2DODCu7RoRgzB310nN7f0go4ih6QYGgN5DtebUgtpZL06ehE5zlvvCPCtR9 uvBAEkEOmMW5tzDJDPrE4z1jnIbCsO2UBbS67VRNAEUdPUa76DXC+fUS5h6M0/vQonN/ OtpfqVnEJHlx+XGnZqUi8lgRDZQ2ph3n4DJLuYz6cohgRPSsvW+bAyGHL8YBLWUGgj27 /iTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:ui-outboundreport:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=8JVR003H/CTyyYzKfG6Cl5xk+z3T9FBTR7QdQbCzz+w=; b=qcSd9yHzUqCczwfMPDFzqxL98WLsT7yIbWBwpVI8ml6BckNEsulUTlPF8PohPAk8hf dsOO11s3IB0R9iCEW3wZAAXCtQGbBWS5wp/t5Q8v4g2cl9dwQ//Vmuizc3gMyQl1jy/P Ukaz7UOXNFJThROtGTe5zKDeICCtVhRyRpkDc1aGBhXMqiPPRSw4jmoG7FJNLH2pOWAK 9MFenztCYONkm+uJ3Gwq7nBb+0QyGq8GT5yOE7muZKGlkkO8cT0CGeJiKa4WSHhwZed3 FZRqBrLNE0UJRDYcR2P49BAiVjnOvgS91F7dZKpA/CggluDTLD9tJ7NscwMxFqZHmhYU 0CKw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmx.net header.s=s31663417 header.b=SLpHvAsj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmx.net Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gi30-20020a1709070c9e00b008610c1703cesi10677449ejc.228.2023.01.29.04.37.25; Sun, 29 Jan 2023 04:37:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmx.net header.s=s31663417 header.b=SLpHvAsj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmx.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232698AbjA2Meu (ORCPT + 99 others); Sun, 29 Jan 2023 07:34:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37392 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230240AbjA2Meq (ORCPT ); Sun, 29 Jan 2023 07:34:46 -0500 Received: from mout.gmx.net (mout.gmx.net [212.227.17.22]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4668422001 for ; Sun, 29 Jan 2023 04:34:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=s31663417; t=1674995677; bh=gQt9VX1KvePgNEJAJdcWhPr0Jz5WN6TRoAAoW9znZzs=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date; b=SLpHvAsjJ3SNOYugkehJl3+gRnBB6gZXIN7L7DX9xyIxkNHxYXOROtXbqfQpEYBud PkdAKQr7DxjmGg9CuZJaVWDYC/GvBLlTk+cd6jmMEDOsdkrwzoSf2Tj1o+Z8GuY59d y0qfBWJRgOWnnAvC4sc9FF3P9L+6wBRouWiXM6psRUteq1nd6tHjwrACPQJ93p/MCo RGvH+ylI7jvMq5iSanUQ8LSD/6/2PlKmU6Wsykks4ILXAlKm0OS10+xq+5vBcmi6km kJjDlKJ48oM09EE6iH68fwGlvYzeQdLzFVW1DqS7YSkV/bvnxaCy0jfxSw2FliuQKf wm/QDZCETm5pg== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from probook ([95.223.44.193]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1Mz9Ux-1oQikB3vOt-00wE9X; Sun, 29 Jan 2023 13:34:37 +0100 From: =?utf-8?q?Jonathan_Neusch=C3=A4fer?= To: linux-kernel@vger.kernel.org Cc: =?utf-8?q?Jonathan_Neusch=C3=A4fer?= , Andy Whitcroft , Joe Perches , Dwaipayan Ray , Lukas Bulwahn Subject: [PATCH] checkpatch.pl: Relax commit ID check to allow more than 12 chars Date: Sun, 29 Jan 2023 13:34:31 +0100 Message-Id: <20230129123431.1282427-1-j.neuschaefer@gmx.net> X-Mailer: git-send-email 2.39.0 MIME-Version: 1.0 X-Provags-ID: V03:K1:To8aw2cJRT9HKi99D3nDKzAF7HB6D3EVKkUCpVvmnu4s8/G9skO 9B70RmrjYJKUhi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5XW6roouhalvfWdblY0Md5DfJ R2CLHFWJKs1QnBwNXP5r7LBPPeMr/J2jzb9WX9AtFHodqKzdK6W7FlTZ9JF49v30f3PYwkCXz OsPPf7xnyFuC+R9ndPPpa6XGbmg= X-Spam-Status: No, score=0.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,RCVD_IN_SBL_CSS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1756360469143699135?= X-GMAIL-MSGID: =?utf-8?q?1756360469143699135?= By now, `git log --pretty=%h` (on my copy of linux.git) prints commit hashes with 13 digits, because of the number of objects. Relax the rule in checkpatch.pl to allow a few more digits (up to 16). Signed-off-by: Jonathan Neuschäfer --- scripts/checkpatch.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.39.0 diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 78cc595b98ce1..3a2c8b5426191 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -3177,7 +3177,7 @@ sub process { $tag_case = 0 if $tag eq "Fixes:"; $tag_space = 0 if ($line =~ /^fixes:? [0-9a-f]{5,} ($balanced_parens)/i); - $id_length = 0 if ($orig_commit =~ /^[0-9a-f]{12}$/i); + $id_length = 0 if ($orig_commit =~ /^[0-9a-f]{12,16}$/i); $id_case = 0 if ($orig_commit !~ /[A-F]/); # Always strip leading/trailing parens then double quotes if existing @@ -3194,7 +3194,7 @@ sub process { if ($ctitle ne $title || $tag_case || $tag_space || $id_length || $id_case || !$title_has_quotes) { if (WARN("BAD_FIXES_TAG", - "Please use correct Fixes: style 'Fixes: <12 chars of sha1> (\"\")' - ie: 'Fixes: $cid (\"$ctitle\")'\n" . $herecurr) && + "Please use correct Fixes: style 'Fixes: <12-16 chars of sha1> (\"<title line>\")' - ie: 'Fixes: $cid (\"$ctitle\")'\n" . $herecurr) && $fix) { $fixed[$fixlinenr] = "Fixes: $cid (\"$ctitle\")"; }