Commit graph

6 commits

Author SHA1 Message Date
Geert Uytterhoeven
66128f4287
kbuild: uapi: Strip comments before size type check
On m68k, check_sizetypes in headers_check reports:

    ./usr/include/asm/bootinfo-amiga.h:17: found __[us]{8,16,32,64} type without #include <linux/types.h>

This header file does not use any of the Linux-specific integer types,
but merely refers to them from comments, so this is a false positive.
As of commit c3a9d74ee4 ("kbuild: uapi: upgrade check_sizetypes()
warning to error"), this check was promoted to an error, breaking m68k
all{mod,yes}config builds.

Fix this by stripping simple comments before looking for Linux-specific
integer types.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Link: https://patch.msgid.link/949f096337e28d50510e970ae3ba3ec9c1342ec0.1759753998.git.geert@linux-m68k.org
[nathan: Adjust comment and remove unnecessary escaping from slashes in
         regex]
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
2025-10-06 11:31:19 -07:00
Thomas Weißschuh
b8d762c983
kbuild: uapi: upgrade check_declarations() warning to error
No problematic declarations exist anymore.

Make sure it stays this way.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Reviewed-by: Nicolas Schier <nsc@kernel.org>
Link: https://lore.kernel.org/r/20250813-kbuild-hdrtest-fixes-v2-5-8a7921ca3a03@linutronix.de
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
2025-08-13 14:00:35 -07:00
Thomas Weißschuh
c3a9d74ee4
kbuild: uapi: upgrade check_sizetypes() warning to error
No problematic type usages exist anymore.

Make sure it stays this way.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Reviewed-by: Nicolas Schier <nsc@kernel.org>
Link: https://lore.kernel.org/r/20250813-kbuild-hdrtest-fixes-v2-4-8a7921ca3a03@linutronix.de
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
2025-08-13 14:00:34 -07:00
Thomas Weißschuh
24b1bd64ee
kbuild: uapi: upgrade warning on asm/types.h inclusion to error
No usages of '#include <asm/types.h> in the UAPI headers exist anymore.

Make sure it stays this way.

Add a semicolon to the end of the previous printf call to keep the
syntax valid.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Reviewed-by: Nicolas Schier <nsc@kernel.org>
Link: https://lore.kernel.org/r/20250813-kbuild-hdrtest-fixes-v2-3-8a7921ca3a03@linutronix.de
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
2025-08-13 14:00:34 -07:00
Geert Uytterhoeven
d67393f4d2 kbuild: Drop support for include/asm-<arch> in headers_check.pl
"include/asm-<arch>" was replaced by "arch/<arch>/include/asm" a long
time ago.  All assembler header files are now included using
"#include <asm/*>", so there is no longer a need to rewrite paths.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2024-12-21 11:43:17 +09:00
Masahiro Yamada
50a483405c kbuild: move headers_check.pl to usr/include/
This script is only used by usr/include/Makefile. Make it local to
the directory.

Update the comment in include/uapi/linux/soundcard.h because
'make headers_check' is no longer functional.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2022-01-08 17:41:00 +09:00
Renamed from scripts/headers_check.pl (Browse further)