From e98e78b52a5c376700bb8862582de3878e991741 Mon Sep 17 00:00:00 2001 From: Peter Griffin Date: Thu, 20 Jul 2023 20:47:12 +0000 Subject: [PATCH] ANDROID: Revert "kbuild: Enable -fstrict-flex-arrays=3" This reverts commit df8fc4e934c12b906d08050d7779f292b9c5c6b5. The P21 drivers currently get UBSAN array out of bounds traps at runtime. To unblock android-mainline whilst we investigate and fixup the P21 drivers temporarily revert this commit/ Bug: 292051371 Change-Id: Iaa68ff6aada72fc39f725906e4604d5025e05daf Signed-off-by: Peter Griffin Signed-off-by: Greg Kroah-Hartman --- Makefile | 6 ------ 1 file changed, 6 deletions(-) diff --git a/Makefile b/Makefile index 5a2a4c204273..85d240b3b6c7 100644 --- a/Makefile +++ b/Makefile @@ -1052,12 +1052,6 @@ KBUILD_CFLAGS += -Wno-pointer-sign # globally built with -Wcast-function-type. KBUILD_CFLAGS += $(call cc-option, -Wcast-function-type) -# To gain proper coverage for CONFIG_UBSAN_BOUNDS and CONFIG_FORTIFY_SOURCE, -# the kernel uses only C99 flexible arrays for dynamically sized trailing -# arrays. Enforce this for everything that may examine structure sizes and -# perform bounds checking. -KBUILD_CFLAGS += $(call cc-option, -fstrict-flex-arrays=3) - # disable stringop warnings in gcc 8+ KBUILD_CFLAGS += $(call cc-disable-warning, stringop-truncation)