From: Justin M. Forbes Date: Wed, 29 Jan 2025 21:50:02 +0000 (-0700) Subject: rust: kbuild: add -fzero-init-padding-bits to bindgen_skip_cflags X-Git-Tag: v6.12.16~54 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=86f563c7431a6f98f4b37b1bd653004e08ce4b1b;p=thirdparty%2Fkernel%2Fstable.git rust: kbuild: add -fzero-init-padding-bits to bindgen_skip_cflags [ Upstream commit a9c621a217128eb3fb7522cf763992d9437fd5ba ] This seems to break the build when building with gcc15: Unable to generate bindings: ClangDiagnostic("error: unknown argument: '-fzero-init-padding-bits=all'\n") Thus skip that flag. Signed-off-by: Justin M. Forbes Fixes: dce4aab8441d ("kbuild: Use -fzero-init-padding-bits=all") Reviewed-by: Kees Cook Link: https://lore.kernel.org/r/20250129215003.1736127-1-jforbes@fedoraproject.org [ Slightly reworded commit. - Miguel ] Signed-off-by: Miguel Ojeda Signed-off-by: Sasha Levin --- diff --git a/rust/Makefile b/rust/Makefile index 9f59baacaf773..45779a064fa4f 100644 --- a/rust/Makefile +++ b/rust/Makefile @@ -229,6 +229,7 @@ bindgen_skip_c_flags := -mno-fp-ret-in-387 -mpreferred-stack-boundary=% \ -fzero-call-used-regs=% -fno-stack-clash-protection \ -fno-inline-functions-called-once -fsanitize=bounds-strict \ -fstrict-flex-arrays=% -fmin-function-alignment=% \ + -fzero-init-padding-bits=% \ --param=% --param asan-% # Derived from `scripts/Makefile.clang`.