lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 7 Sep 2022 14:35:47 +0200 From: Philippe Schenker <dev@...henker.ch> To: Andy Whitcroft <apw@...onical.com>, Joe Perches <joe@...ches.com>, linux-kernel@...r.kernel.org Cc: Stephen Rothwell <sfr@...b.auug.org.au>, Dwaipayan Ray <dwaipayanray1@...il.com>, Lukas Bulwahn <lukas.bulwahn@...il.com>, Shawn Guo <shawnguo@...nel.org>, Philippe Schenker <philippe.schenker@...adex.com> Subject: [PATCH] checkpatch: add check for fixes: tag From: Philippe Schenker <philippe.schenker@...adex.com> The page about submitting patches in Documentation/process/submitting-patches.rst is very specific on how that tag should be formatted: 'Fixes: <12+ chars of sha1> (\"<title line>\")' Add a rule that warns if this format does not match. This commit is introduced as in the past commits have been sent multiple times with having the word commit also in the Fixes: tag which had to be corrected by the maintainers. [1] [1] https://lore.kernel.org/all/20220906073746.1f2713f7@canb.auug.org.au/ Signed-off-by: Philippe Schenker <philippe.schenker@...adex.com> --- scripts/checkpatch.pl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 79e759aac543..0d7ce0c3801a 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -3438,6 +3438,13 @@ sub process { } } +# Check fixes tag format + if ($in_commit_log && ($line =~ /^\s*Fixes:/i) && + !($line =~ /^\s*Fixes:\s[0-9a-f]{12,40}\s\(\".*\"\)/)) { + WARN("FIXES_TAG_FORMAT", + "Possible wrong format on Fixes: tag, please use format Fixes: <12+ chars of sha1> (\"<title line>\")\n" . $herecurr); + } + # ignore non-hunk lines and lines being removed next if (!$hunk_line || $line =~ /^-/); -- 2.37.2
Powered by blists - more mailing lists