OpenVZ / Virtuozzo kernel development (devel@openvz.org)
 help / color / mirror / Atom feed
From: no-reply@sashiko.virtuozzo.com
To: Konstantin Khorenko <khorenko@virtuozzo.com>, devel@openvz.org
Subject: Re: [Devel] [PATCH hci-8.1 1/2] ms/checkpatch: add support for Assisted-by tag
Date: Fri, 16 Oct 2026 21:37:37 +0000	[thread overview]
Message-ID: <010701a146a6294d-d68b8cc6-1874-481a-886f-ebe63ba79324-000000@eu-central-1.amazonses.com> (raw)
In-Reply-To: <20261016-checkpatch-v1-1-3aceda8d9600@virtuozzo.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] checkpatch: Assisted-by block's unconditional next skips later per-line checks
--

commit 5a811b60fe8be1a0a89ee89ba84a4ed4223a05c3
Author: Sasha Levin <sashal@kernel.org>

ms/checkpatch: add support for Assisted-by tag

This commit teaches checkpatch.pl to recognize the Assisted-by tag. It adds
the tag to $signature_tags and skips email validation for Assisted-by lines.
It also warns when the value doesn't look like AGENT_NAME:MODEL_VERSION.

Link: https://lkml.kernel.org/r/20260311215818.518930-1-sashal@kernel.org

> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> --- a/scripts/checkpatch.pl
> +++ b/scripts/checkpatch.pl

[ ... ]

> @@ -3072,6 +3073,15 @@ sub process {
>  				}
>  			}
>  
> +			# Assisted-by uses AGENT_NAME:MODEL_VERSION format, not email
> +			if ($sign_off =~ /^Assisted-by:/i) {
> +				if ($email !~ /^\S+:\S+/) {
> +					WARN("BAD_SIGN_OFF",
> +					     "Assisted-by expects 'AGENT_NAME:MODEL_VERSION [TOOL1] [TOOL2]' format\n" . $herecurr);
> +				}
> +				next;
> +			}
> +

[Severity: Low]
Does the unconditional next; here skip checks that should still run for
Assisted-by lines?

In process(), this block sits inside the per-line loop. For a line such as
"Assisted-by: X", $sign_off is "Assisted-by:", so the new block ends with
next; and jumps to the next input line.

That skips the "# Check for duplicate signatures" code that records
$signatures{$sig_nospace}, so duplicate Assisted-by lines would never be
reported as "Duplicate signature". It also skips the other per-line checks
that follow the signature block, such as the repeated-word check.

The follow-up patch 7d898d23 ("ms/checkpatch.pl: adapt to new Assisted-by:
format") changes only the value check, to an empty-value check with
different warning text. It keeps the unconditional next;, so the final
series state still skips those checks.

Would an if/else around the email validation, instead of next;, avoid this?

>  			my ($email_name, $name_comment, $email_address, $comment) = parse_email($email);
>  			my $suggested_email = format_email(($email_name, $name_comment, $email_address, $comment));
>  			if ($suggested_email eq "") {

[ ... ]

-- 
Sashiko AI review · https://sashiko.vzint.dev/#/patchset/20261016-checkpatch-v1-0-3aceda8d9600@virtuozzo.com?part=1

_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

  reply	other threads:[~2026-10-16 21:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-16 21:33 [Devel] [PATCH hci-8.1 0/2] ms/checkpatch: accept the Assisted-by: LLM tag Konstantin Khorenko
2026-10-16 21:33 ` [Devel] [PATCH hci-8.1 1/2] ms/checkpatch: add support for Assisted-by tag Konstantin Khorenko
2026-10-16 21:37   ` no-reply [this message]
2026-10-16 21:33 ` [Devel] [PATCH hci-8.1 2/2] ms/checkpatch.pl: adapt to new Assisted-by: format Konstantin Khorenko
2026-10-16 21:36   ` no-reply
2026-10-16 21:54 ` [Devel] [PATCH hci-8.1 0/2] ms/checkpatch: accept the Assisted-by: LLM tag Konstantin Khorenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=010701a146a6294d-d68b8cc6-1874-481a-886f-ebe63ba79324-000000@eu-central-1.amazonses.com \
    --to=no-reply@sashiko.virtuozzo.com \
    --cc=devel@openvz.org \
    --cc=khorenko@virtuozzo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox