[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190323020103.GB17709@eros.localdomain>
Date: Sat, 23 Mar 2019 13:01:03 +1100
From: "Tobin C. Harding" <me@...in.cc>
To: Sean Christopherson <sean.j.christopherson@...el.com>
Cc: Jonathan Corbet <corbet@....net>,
Andy Whitcroft <apw@...onical.com>,
Joe Perches <joe@...ches.com>, linux-doc@...r.kernel.org,
linux-kernel@...r.kernel.org, Thomas Gleixner <tglx@...utronix.de>,
Jani Nikula <jani.nikula@...ux.intel.com>,
Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@...aro.org>,
Jonathan Cameron <jic23@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Niklas Cassel <niklas.cassel@...aro.org>
Subject: Re: [PATCH v5 2/2] checkpatch: Warn on improper usage of
Co-developed-by
On Fri, Mar 22, 2019 at 02:11:37PM -0700, Sean Christopherson wrote:
> The purpose of Co-developed-by: is to give attribution to authors who
> aren't already attributed by the From: tag, i.e. who aren't the nominal
> patch author. Because Co-developed-by: is essentially a variation of
> From:, it must be accompanied by a Signed-off-by: of the associated
> co-author. To ease the burden of determining whether or not co-authors
> have signed off, Co-developed-by and Signed-off-by: must be explicitly
> paired, i.e. on consecutive lines for a given co-author.
>
> Suggested-by: Joe Perches <joe@...ches.com>
> Cc: Tobin C. Harding <me@...in.cc>
> Cc: Thomas Gleixner <tglx@...utronix.de>
> Cc: Jani Nikula <jani.nikula@...ux.intel.com>
> Cc: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@...aro.org>
> Cc: Jonathan Cameron <jic23@...nel.org>
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Cc: Niklas Cassel <niklas.cassel@...aro.org>
> Cc: Jonathan Corbet <corbet@....net>
> Signed-off-by: Sean Christopherson <sean.j.christopherson@...el.com>
> ---
> scripts/checkpatch.pl | 18 ++++++++++++++++++
> 1 file changed, 18 insertions(+)
>
> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> index 5b756278df13..bbe71f017f6d 100755
> --- a/scripts/checkpatch.pl
> +++ b/scripts/checkpatch.pl
> @@ -2687,6 +2687,24 @@ sub process {
> } else {
> $signatures{$sig_nospace} = 1;
> }
> +
> +# Check Co-developed-by: immediately followed by Signed-off-by: with same name and email
> + if ($sign_off =~ /^co-developed-by:$/i) {
> + if ($email eq $author) {
> + WARN("BAD_SIGN_OFF",
> + "Co-developed-by: should not be used to attribute nominal patch author '$author'\n" . "$here\n" . $rawline);
> + }
> + if (!defined $lines[$linenr]) {
> + WARN("BAD_SIGN_OFF",
> + "Co-developed-by: must be immediately followed by Signed-off-by:\n" . "$here\n" . $rawline);
> + } elsif ($rawlines[$linenr] !~ /^\s*signed-off-by:\s*(.*)/i) {
> + WARN("BAD_SIGN_OFF",
> + "Co-developed-by: must be immediately followed by Signed-off-by:\n" . "$here\n" . $rawline . "\n" .$rawlines[$linenr]);
> + } elsif ($1 ne $email) {
> + WARN("BAD_SIGN_OFF",
> + "Co-developed-by and Signed-off-by: name/email do not match \n" . "$here\n" . $rawline . "\n" .$rawlines[$linenr]);
> + }
> + }
> }
>
> # Check email subject for common tools that don't need to be mentioned
> --
> 2.21.0
>
Works as advertised!
thanks,
Tobin.
Powered by blists - more mailing lists