Re: [PATCH v10 05/13] kbuild: remove MODULE_LICENSE/AUTHOR/DESCRIPTION in non-modules
From: Geert Uytterhoeven
Date: Tue Dec 06 2022 - 04:11:39 EST
Hi Nick,
Thanks for your patch!
On Mon, Dec 5, 2022 at 5:34 PM Nick Alcock <nick.alcock@xxxxxxxxxx> wrote:
> Since commit 8b41fc4454e ("kbuild: create modules.builtin without
> Makefile.modbuiltin or tristate.conf"), MODULE_LICENSE declarations in
> non-modules will cause modprobe to misidentify their containing object
> file as a module when it is not, which might cause it to spuriously fail
> when trying to load something that is built in to the kernel. They
> also cause misconstruction of modules.builtin.objs, leading to incorrect
> output in kallmodsyms (notating things as being in modules when they
> actually cannot be built as a module at all).
>
> Automatically identified with the new tristate checker, and purged with
> sed and a subsequent make allmodconfig to double-check.
>
> Signed-off-by: Nick Alcock <nick.alcock@xxxxxxxxxx>
I can (sort of) agree with the MODULE_LICENSE(), as it duplicates the
SPDX-License-Identifier at the top.
However, you don't explain why it is a good thing to remove the
MODULE_{AUTHOR,DESCRIPTION}, too. This is useful information, in an
easy-to-parse format.
Moreover, many of the affected drivers might be converted into modules
in the near or far future.
If the presence of these causes issues for the tooling, perhaps the
tooling can be fixed instead?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds