init: Kconfig (gcc13): disable -Warray-bounds on gcc-13 too
PATCH 1/1 init: Kconfig (gcc13): disable -Warray-bounds on gcc-13 too
Nobody took the chance to fix (or at least localize) the warnings since
commit f0be87c42cbd (gcc-12: disable '-Warray-bounds' universally for
now). The new compiler (gcc-13) still reports issues like:
drivers/gpu/drm/amd/display/dc/core/dc_stream.c: In function 'dc_stream_remove_writeback':
drivers/gpu/drm/amd/display/dc/core/dc_stream.c:531:55: error: array subscript -1 is below array bounds of 'struct dc_writeback_info[1]' [-Werror=array-bounds]
Note that 'j' can never be negative. So disable the warning on gcc-13 too until someone takes time to localize them.
Cc Linus Torvalds <[email protected]>
Cc Martin Liska <[email protected]>
Signed-off-by Jiri Slaby (SUSE) <[email protected]>
--- init/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
init/Kconfig +2 -2
@@ -900,14 +900,14 @@ config CC_IMPLICIT_FALLTHROUGH default "-Wimplicit-fallthrough=5" if CC_IS_GCC && $(cc-option,-Wimplicit-fallthrough=5) default "-Wimplicit-fallthrough" if CC_IS_CLANG && $(cc-option,-Wunreachable-code-fallthrough) -# Currently, disable gcc-12 array-bounds globally. +# Currently, disable gcc-12 & 13 array-bounds globally. # We may want to target only particular configurations some day. config GCC12_NO_ARRAY_BOUNDS def_bool y config CC_NO_ARRAY_BOUNDS bool - default y if CC_IS_GCC && GCC_VERSION >= 120000 && GCC_VERSION < 130000 && GCC12_NO_ARRAY_BOUNDS + default y if CC_IS_GCC && GCC_VERSION >= 120000 && GCC_VERSION < 140000 && GCC12_NO_ARRAY_BOUNDS # # For architectures that know their GCC __int128 support is sound
Signature · 1 line
2.38.1