checkpatch: Treat duplicate signatures as a different error class

If code is merged upstream first it is possible that the same author
may end up attempting to merge the same code into a downstream kernel.
Since code coming from upstream is always a backport and may involve
modifications it is appropriate for the author to add another
Signed-off-by line to the bottom of the commit log but this will
cause checkpatch to complain about duplicate signatures.  By making
the duplicate signature warning a different error class
(DUPLICATE_SIGN_OFF instead of BAD_SIGN_OFF) this will let us ignore
this error with --ignore DUPLICATE_SIGN_OFF without losing the benefits
of the other signature checks.

Change-Id: Ic0dedbadcc1b319061db324f88740e5320bfff09
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
This commit is contained in:
Jordan Crouse 2018-08-08 13:01:36 -06:00 • committed by Raghavendra Rao Ananta
commit cfba54476b

View file

@ -2787,7 +2787,7 @@ sub process {
$sig_nospace =~ s/\s//g;
$sig_nospace = lc($sig_nospace);
if (defined $signatures{$sig_nospace}) {
WARN("BAD_SIGN_OFF",
WARN("DUPLICATE_SIGN_OFF",
"Duplicate signature\n" . $herecurr);
} else {
$signatures{$sig_nospace} = 1;