aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/scripts/misc-check
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2025-06-13 01:08:48 +0900
committerMasahiro Yamada <masahiroy@kernel.org>2025-06-16 00:41:40 +0900
commita6a7946bd691940cfe7289ae6dfb1f077516df72 (patch)
tree879cdf432b6ab970b2068839dff506a50f9c231a /scripts/misc-check
parentLinux 6.16-rc1 (diff)
downloadwireguard-linux-a6a7946bd691940cfe7289ae6dfb1f077516df72.tar.xz
wireguard-linux-a6a7946bd691940cfe7289ae6dfb1f077516df72.zip
kbuild: move warnings about linux/export.h from W=1 to W=2
This hides excessive warnings, as nobody builds with W=2. Fixes: a934a57a42f6 ("scripts/misc-check: check missing #include <linux/export.h> when W=1") Fixes: 7d95680d64ac ("scripts/misc-check: check unnecessary #include <linux/export.h> when W=1") Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Nathan Chancellor <nathan@kernel.org> Acked-by: Heiko Carstens <hca@linux.ibm.com>
Diffstat (limited to '')
-rwxr-xr-xscripts/misc-check15
1 files changed, 12 insertions, 3 deletions
diff --git a/scripts/misc-check b/scripts/misc-check
index a74450e799d1..84f08da17b2c 100755
--- a/scripts/misc-check
+++ b/scripts/misc-check
@@ -62,6 +62,15 @@ check_unnecessary_include_linux_export_h () {
xargs -r printf "%s: warning: EXPORT_SYMBOL() is not used, but #include <linux/export.h> is present\n" >&2
}
-check_tracked_ignored_files
-check_missing_include_linux_export_h
-check_unnecessary_include_linux_export_h
+case "${KBUILD_EXTRA_WARN}" in
+*1*)
+ check_tracked_ignored_files
+ ;;
+esac
+
+case "${KBUILD_EXTRA_WARN}" in
+*2*)
+ check_missing_include_linux_export_h
+ check_unnecessary_include_linux_export_h
+ ;;
+esac