kbuild: drop -Wno-unknown-warning-option from clang options
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Wed, 12 Apr 2017 22:25:21 +0000 (07:25 +0900)
committerMasahiro Yamada <yamada.masahiro@socionext.com>
Sun, 23 Apr 2017 07:09:15 +0000 (16:09 +0900)
Since commit c3f0d0bc5b01 ("kbuild, LLVMLinux: Add -Werror to
cc-option to support clang"), cc-option and friends work nicely
for clang.

However, -Wno-unknown-warning-option makes clang happy with any
unknown warning options even if -Werror is specified.

Once -Wno-unknown-warning-option is added, any succeeding call of
cc-disable-warning is evaluated positive, then unknown warning
options are accepted.  This should be dropped.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Makefile
scripts/Makefile.extrawarn

index 245852f7b312d1842710c9f6247cced54ff05b9a..f178b9a7b56f5a6d23354f6e71aa0b6c533d7f9b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -689,7 +689,6 @@ KBUILD_CFLAGS += $(stackp-flag)
 
 ifeq ($(cc-name),clang)
 KBUILD_CPPFLAGS += $(call cc-option,-Qunused-arguments,)
-KBUILD_CPPFLAGS += $(call cc-option,-Wno-unknown-warning-option,)
 KBUILD_CFLAGS += $(call cc-disable-warning, unused-variable)
 KBUILD_CFLAGS += $(call cc-disable-warning, format-invalid-specifier)
 KBUILD_CFLAGS += $(call cc-disable-warning, gnu)
index 7c321a603b079d355bd127aebb04adc0294b4ba5..fb3522fd87029f8e841469d2bb300ef6eb7fe1cb 100644 (file)
@@ -64,7 +64,6 @@ ifeq ($(cc-name),clang)
 KBUILD_CFLAGS += $(call cc-disable-warning, initializer-overrides)
 KBUILD_CFLAGS += $(call cc-disable-warning, unused-value)
 KBUILD_CFLAGS += $(call cc-disable-warning, format)
-KBUILD_CFLAGS += $(call cc-disable-warning, unknown-warning-option)
 KBUILD_CFLAGS += $(call cc-disable-warning, sign-compare)
 KBUILD_CFLAGS += $(call cc-disable-warning, format-zero-length)
 KBUILD_CFLAGS += $(call cc-disable-warning, uninitialized)