Skip to content

Commit 8d9acfc

Browse files
nathanchancemasahir0y
authored andcommitted
kbuild: Stop using '-Qunused-arguments' with clang
This option masks all unused command line argument warnings, which can hide potential issues, such as an architecture Makefile adding an unsupported flag to KBUILD_AFLAGS or KBUILD_CFLAGS, which will cause all as-option and cc-options to silently fail due to -Werror with no indication as to why in the main kernel build. Remove this flag so that warnings of this nature can be caught early and obviously in a build. Signed-off-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Nick Desaulniers <ndesaulniers@google.com> Tested-by: Linux Kernel Functional Testing <lkft@linaro.org> Tested-by: Anders Roxell <anders.roxell@linaro.org> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
1 parent db1547c commit 8d9acfc

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -870,7 +870,6 @@ KBUILD_RUSTFLAGS-$(CONFIG_WERROR) += -Dwarnings
870870
KBUILD_RUSTFLAGS += $(KBUILD_RUSTFLAGS-y)
871871

872872
ifdef CONFIG_CC_IS_CLANG
873-
KBUILD_CPPFLAGS += -Qunused-arguments
874873
# The kernel builds with '-std=gnu11' so use of GNU extensions is acceptable.
875874
KBUILD_CFLAGS += -Wno-gnu
876875
else

0 commit comments

Comments
 (0)