Re: [PATCH v1 04/10] kconfig: Introduce checkconfig target

From: Nicolas Schier

Date: Wed Nov 11 2026 - 01:43:13 EST


On Mon, Nov 09, 2026 at 02:18:49PM +0100, Ahmed S. Darwish wrote:
> On Sun, 08 Nov 2026, Nathan Chancellor wrote:
> >
> > On Sun, Nov 08, 2026 at 06:59:45PM +0000, Julian Braha wrote:
> > >
> > > I think this tool may belong in scripts/ due to the kbuild integration,
> > > as was mentioned in the past on another tool review:
> > >
> > > https://lore.kernel.org/linux-kbuild/20260428183101.GA3304253@ax162/
> >
> > Yeah, while I would prefer for the script to live in scripts/ due to
> > being called from Kbuild, I am not sure if the rules/schemas belong
> > there?
> >
> > It might be better to keep everything in tools/ for that reason,
> > especially if this may be called externally, but I am open to other
> > thoughts.
> >
>
> I would prefer to keep it under tools/ as well. Because of the PREEMPT_RT
> policy, and the possible extra policies from ELISA, etc.
>
> This is why one of the development rules at the top of the Python script,
> at patch 03/10, is:
>
> The tool must not depend on being run inside the kernel source tree.
> This simplifies invocation, testing and possible future packaging.

Then, please move the argument checking from Makefile to the script
itself. Handling wrong arguments is good native feature for the script.

As far as I have seen when skimming through the kconfig policy checker
code, it does not use any Kbuild variables. So, if it is being placed
below tools/ and does not use Kbuild at all, and is expected to be run
w/o Linux tree context at all: why do we need an additional top-level
Makefile target for it at all (alongside of
'make tools/kconfig-policy-checker')?

--
Nicolas