Re: [PATCH] kbuild: Do not run kernel-doc when building external modules

Jani Nikula
2026-02-04T10:39:29Z

On Wed, 04 Feb 2026, Nicolas Schier <nsc@kernel.org> wrote:
> Well, sounds straight forward at first, but where should we make the
> cut between kbuild and non-kbuild?

I'll reply hypothetically, just for the sake of discussion, because
realistically, I don't think any of this is going to happen.

IMO the cut should be, "Is this required for configuring and building
the kernel"?

scripts/ just sounds like a dumping ground for random scripts, and
kbuild should be somewhere else. And let scripts/ be the dumping ground
that it is. If kbuild was under kbuild/, nobody in their right mind
would suggest adding random unrelated scripts there.

If kbuild depends on some things like objtool from somewhere else, so be
it, but at least don't pollute kbuild with unrelated things.

> I admit that there are some scripts below scripts/ that I'd rather
> label as "contrib", but I don't think that these are too much.

I've got to disagree there. I think there's so much that it's hard to
follow what is and isn't actually required for build.

At a *very* quick glance, there are things like checkpatch.pl,
get_maintainer.pl, anything coccinelle, bash-completion, Lindent,
macro_checker.py, bloat-o-meter, bootgraph.pl, etc, etc.

BR,
Jani.

--
Jani Nikula, Intel