[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200303065210.1279-2-zhenzhong.duan@gmail.com>
Date: Tue, 3 Mar 2020 14:52:09 +0800
From: Zhenzhong Duan <zhenzhong.duan@...il.com>
To: linux-kernel@...r.kernel.org
Cc: x86@...nel.org, tglx@...utronix.de, mingo@...hat.com, bp@...en8.de,
zhenzhong.duan@...il.com, "H. Peter Anvin" <hpa@...or.com>
Subject: [PATCH 1/2] x86/boot: Add -Wunused to KBUILD_CFLAGS
Compile warning option in arch/x86/boot/compressed is different from
other part of the kernel for some history reason. But "-Wunused" is
safe to be added to point out unused variable issue.
Link: https://lore.kernel.org/patchwork/patch/1175001/#1379873
Suggested-by: Borislav Petkov <bp@...en8.de>
Signed-off-by: Zhenzhong Duan <zhenzhong.duan@...il.com>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: Ingo Molnar <mingo@...hat.com>
Cc: "H. Peter Anvin" <hpa@...or.com>
---
arch/x86/boot/compressed/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile
index 26050ae0b27e..cb9743ec453a 100644
--- a/arch/x86/boot/compressed/Makefile
+++ b/arch/x86/boot/compressed/Makefile
@@ -37,7 +37,7 @@ KBUILD_CFLAGS += $(call cc-option,-ffreestanding)
KBUILD_CFLAGS += $(call cc-option,-fno-stack-protector)
KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member)
KBUILD_CFLAGS += $(call cc-disable-warning, gnu)
-KBUILD_CFLAGS += -Wno-pointer-sign
+KBUILD_CFLAGS += -Wno-pointer-sign -Wunused
KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=)
KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__
--
2.17.1
Powered by blists - more mailing lists