From patchwork Thu May 14 12:30:02 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Rini X-Patchwork-Id: 245804 List-Id: U-Boot discussion From: trini at konsulko.com (Tom Rini) Date: Thu, 14 May 2020 08:30:02 -0400 Subject: [PATCH 03/10] Don't start ad-hoc games with -Wno-maybe-initialized In-Reply-To: <20200514123009.5721-1-trini@konsulko.com> References: <20200514123009.5721-1-trini@konsulko.com> Message-ID: <20200514123009.5721-3-trini@konsulko.com> Borrowing from Linux commit 78a5255ffb6a ("Stop the ad-hoc games with -Wno-maybe-initialized") move to have maybe-initialized warnings be handled with building with W=2 instead of playing more guessing games with newer compilers. Signed-off-by: Tom Rini --- Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Makefile b/Makefile index a9d58ca7a0dc..951ecbd41cef 100644 --- a/Makefile +++ b/Makefile @@ -683,6 +683,9 @@ KBUILD_CFLAGS += $(call cc-option,-fno-delete-null-pointer-checks) # disable stringop warnings in gcc 8+ KBUILD_CFLAGS += $(call cc-disable-warning, stringop-truncation) +# Enabled with W=2, disabled by default as noisy +KBUILD_CFLAGS += $(call cc-disable-warning, maybe-uninitialized) + # change __FILE__ to the relative path from the srctree KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=)