From: Dave Martin Date: Thu, 6 Jun 2019 10:33:43 +0000 (+0100) Subject: arm64: Silence gcc warnings about arch ABI drift X-Git-Tag: submit/tizen/20200102.014302~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F94%2F221394%2F1;p=platform%2Fkernel%2Flinux-rpi3.git arm64: Silence gcc warnings about arch ABI drift [ Upstream commit ebcc5928c5d925b1c8d968d9c89cdb0d0186db17 ] Since GCC 9, the compiler warns about evolution of the platform-specific ABI, in particular relating for the marshaling of certain structures involving bitfields. The kernel is a standalone binary, and of course nobody would be so stupid as to expose structs containing bitfields as function arguments in ABI. (Passing a pointer to such a struct, however inadvisable, should be unaffected by this change. perf and various drivers rely on that.) So these warnings do more harm than good: turn them off. We may miss warnings about future ABI drift, but that's too bad. Future ABI breaks of this class will have to be debugged and fixed the traditional way unless the compiler evolves finer-grained diagnostics. Signed-off-by: Dave Martin Signed-off-by: Will Deacon Signed-off-by: Sasha Levin [sw0312.kim: cherry-pick from stable linux-4.19.y commit 71d019a6dae9 for gcc 9 build] Signed-off-by: Seung-Woo Kim Change-Id: I6a6ca56261860468207555d869f5a90882565c4b --- diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index 853e565f8957..3a9c9a0e1e10 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -51,6 +51,7 @@ endif KBUILD_CFLAGS += -mgeneral-regs-only $(lseinstr) $(brokengasinst) KBUILD_CFLAGS += -fno-asynchronous-unwind-tables +KBUILD_CFLAGS += -Wno-psabi KBUILD_AFLAGS += $(lseinstr) $(brokengasinst) KBUILD_CFLAGS += $(call cc-option,-mabi=lp64)