From 74c4b7ca17f3a63f8fd8437c2c8d181cdceec88c Mon Sep 17 00:00:00 2001 From: Vikram Mulukutla Date: Mon, 1 May 2017 14:32:04 -0700 Subject: [PATCH] checkpatch: Use upstream commit text length checks Upstream has merged a few commit text length checks that make our own checks redundant. Furthermore, upstream also has a newer exception list (such as allowing Fixes: lines to be >75 characters) that we should take advantage of. Change-Id: I894482c1a4182ad71146d5d433610d4cb210cb1d Signed-off-by: Vikram Mulukutla Signed-off-by: Rishabh Bhatnagar --- scripts/checkpatch.pl | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 1315e049d475..0fdb0738cdf4 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -2591,16 +2591,10 @@ sub process { $herecurr); } $shorttext = AFTER_SHORTTEXT; - } elsif (length($line) > (SHORTTEXT_LIMIT + - $shorttext_exspc) - && $line !~ /^:([0-7]{6}\s){2} - ([[:xdigit:]]+\.* - \s){2}\w+\s\w+/xms) { - WARN("LONG_COMMIT_TEXT", - "commit text line over " . - SHORTTEXT_LIMIT . - " characters\n" . $herecurr); - } elsif ($line=~/^\s*[\x21-\x39\x3b-\x7e]+:/) { + } elsif ($line=~/^\s*change-id:/i || + $line=~/^\s*signed-off-by:/i || + $line=~/^\s*crs-fixed:/i || + $line=~/^\s*acked-by:/i) { # this is a tag, there must be commit # text by now if ($commit_text_present == 0) {