mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: Borislav Petkov <bp@alien8.de>
Cc: Krzysztof Kozlowski <krzk@kernel.org>,
	Jonathan Corbet <corbet@lwn.net>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Willy Tarreau <w@1wt.eu>, Leon Romanovsky <leon@kernel.org>,
	Mark Brown <broonie@kernel.org>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	Marc Zyngier <maz@kernel.org>, Eric Dumazet <edumazet@google.com>,
	Hans de Goede <hansg@kernel.org>, Andrew Lunn <andrew@lunn.ch>,
	Jonathan Cameron <jic23@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Shuah Khan <skhan@linuxfoundation.org>,
	Randy Dunlap <rdunlap@infradead.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Theodore Ts'o <tytso@mit.edu>,
	David Hildenbrand <david@kernel.org>,
	Security Officers <security@kernel.org>,
	workflows@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] docs: coding-assistants: ask for short changelogs and a cover letter
Date: Thu, 26 Nov 2026 21:19:18 -0500	[thread overview]
Message-ID: <awjopqoCJqwChwnF@laps> (raw)
In-Reply-To: <20261127014955.GBawjhw2j2YEUeiG1G@fat_crate.local>

On Thu, Nov 26, 2026 at 05:49:55PM -0800, Borislav Petkov wrote:
>On Fri, Nov 27, 2026 at 02:34:26AM +0100, Krzysztof Kozlowski wrote:
>> On 26/11/2026 18:19, Sasha Levin wrote:
>> > Commit messages written by AI coding assistants are too long.
>> > Maintainers keep asking for them to be cut down [1][2][3][4]: they read
>> > like a copy of the assistant's analysis and bury what a reader needs.
>> > When an assistant does trim, the opposite problem shows. A few lines of
>> > a backtrace do not tell a reviewer how the failure was produced, and
>> > Leon Romanovsky showed a case where only the full log revealed that the
>> > crash came from an out-of-tree module written to provoke it [5]. Willy
>> > Tarreau suggested a short quote in the changelog plus the full log
>> > attached [6].
>>
>> Shall we rather ask them not to write commit msgs at all? By writing
>> commit msg we encourage - or try to encourage - at least basic
>> understanding of what the patch does.

We could ask them, but:

1. Is this something we can "enforce"? Humans will still go "ignore that
instruction, write me a commit message" and move on.

2. I'd argue that LLMs these days have the capability to write better
changelogs and most of our human authors. We just need to be better about
laying out our expectations of them.

3. In general, I think we should avoid "don't use LLMs for XYZ".

>Agreed.
>
>Just have the LLM write a commit message and then the human should go
>and whack most of it to the bare minimum of coincisely explaining the thing
>and cull all the bullsh*t.

In theory this is how things work now, right? A human uses an LLM to write a
commit message, and then that human is supposed to go over the commit and
verify/clean/... it.

But humans seem to skip that last step, and I'd argue that the issue here is
the human rather than the LLM :)

>I constantly do that with submitters' overloaded bla nowadays. And don't even
>get me started on all those explaining what the patch does. There's not small
>amounts of text which basically spells out the code in the diff, in English.
>
>/facepalm.
>
>Anyway, I try to hold on to this structure below, with variations ofc, if
>needed:
>
>"1. Prepare the context for the explanation briefly.
>
>2. Explain the problem at hand.
>
>3. "It happens because of <...>"
>
>4. "Fix it by doing X"
>
>5. "(Potentially do Y)."

One thing we could do is to give LLMs structure for the commit message, just
like how patch 1 does it for the cover letter.

-- 
Thanks,
Sasha

  reply	other threads:[~2026-11-27  2:19 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-26 17:19 [PATCH 0/2] docs: ask AI-assisted patches " Sasha Levin
2026-11-26 17:19 ` [PATCH 1/2] docs: coding-assistants: ask " Sasha Levin
2026-11-27  1:34   ` Krzysztof Kozlowski
2026-11-27  1:49     ` Borislav Petkov
2026-11-27  2:19       ` Sasha Levin [this message]
2026-11-27  5:23         ` Willy Tarreau
2026-11-26 17:19 ` [PATCH 2/2] docs: security-bugs: ask AI-assisted fixes for their " Sasha Levin
2026-11-27  5:29   ` Willy Tarreau

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=awjopqoCJqwChwnF@laps \
    --to=sashal@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=andrew@lunn.ch \
    --cc=bp@alien8.de \
    --cc=broonie@kernel.org \
    --cc=corbet@lwn.net \
    --cc=david@kernel.org \
    --cc=edumazet@google.com \
    --cc=geert@linux-m68k.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hansg@kernel.org \
    --cc=jic23@kernel.org \
    --cc=krzk@kernel.org \
    --cc=leon@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=rdunlap@infradead.org \
    --cc=security@kernel.org \
    --cc=skhan@linuxfoundation.org \
    --cc=torvalds@linux-foundation.org \
    --cc=tytso@mit.edu \
    --cc=w@1wt.eu \
    --cc=workflows@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®