Re: [PATCH 0/4] checkpatch: improve exit criterias

From: Bjorn Andersson

Date: Tue Nov 10 2026 - 08:58:12 EST


On Sun, Nov 8, 2026 at 3:04 AM Joe Perches <joe@xxxxxxxxxxx> wrote:
>
> On Sun, 2026-11-08 at 04:21 +0000, Bjorn Andersson wrote:
> > When invoking checkpatch with the --mailback argument over a range of
> > patches the tool unexpectedly exits successfully on the first clean
> > patch. For example:
> >
> > ./scripts/checkpatch.pl --mailback --git v7.3-rc1..
>
> Why is it useful to do this?

My use case is that I create a maintainer branch off e.g. v7.3-rc1
(now v7.4-rc1), then apply a bunch of patches and before pushing that
out I run "checkpatch.pl --strict v7.3-rc1..".

But this is quite noisy, and the compressed "b4 prep --check" output
is more what I'm looking for. So, I borrowed the "checkpatch.pl -q
--terse --no-summary --mailback --showfile" from there and it took me
a while to realize the difference between:

--mailback only produce a report in case of warnings/errors

and "don't produce a report if the first commit is good".

So, might not be useful in itself, but the behavior tricked me and I
pushed patches into linux-next with checkpatch errors.

Regards,
Bjorn