On Wed, Jan 25, 2023 at 1:20 AM Nathan Chancellor <nathan@xxxxxxxxxx> wrote: > > After commit 7bbf02b875b5 ("kbuild: Stop using '-Qunused-arguments' with > clang"), the PowerPC vDSO shows the following error with clang-13 and > older when CONFIG_INIT_STACK_ALL_ZERO is enabled: > > clang: error: argument unused during compilation: '-enable-trivial-auto-var-init-zero-knowing-it-will-be-removed-from-clang' [-Werror,-Wunused-command-line-argument] > > clang-14 added a change to make sure this flag never triggers > -Wunused-command-line-argument, so it is fixed with newer releases. For > older releases that the kernel still supports building with, just filter > out this flag, as has been done for other flags. > > Fixes: b174f4c26aa3 ("powerpc/vdso: Improve linker flags") > Fixes: 7bbf02b875b5 ("kbuild: Stop using '-Qunused-arguments' with clang") > Link: https://github.com/llvm/llvm-project/commit/ca6d5813d17598cd180995fb3bdfca00f364475f > Signed-off-by: Nathan Chancellor <nathan@xxxxxxxxxx> > --- > This should be the last flag that needs to be filtered (famous last > words...) but if any more come up, we should really just explore > switching the PowerPC vDSO to linking with $(LD) like every other part > of the kernel; for now, I hope this is fine. > > Cheers, > Nathan Applied to linux-kbuild. Thanks. Since I rebased the branch, the tags have been updated accordingly. powerpc/vdso: Filter clang's auto var init zero enabler when linking After commit 8d9acfce3332 ("kbuild: Stop using '-Qunused-arguments' with clang"), the PowerPC vDSO shows the following error with clang-13 and older when CONFIG_INIT_STACK_ALL_ZERO is enabled: clang: error: argument unused during compilation: '-enable-trivial-auto-var-init-zero-knowing-it-will-be-removed-from-clang' [-Werror,-Wunused-command-line-argument] clang-14 added a change to make sure this flag never triggers -Wunused-command-line-argument, so it is fixed with newer releases. For older releases that the kernel still supports building with, just filter out this flag, as has been done for other flags. Fixes: f0a42fbab447 ("powerpc/vdso: Improve linker flags") Fixes: 8d9acfce3332 ("kbuild: Stop using '-Qunused-arguments' with clang") Link: https://github.com/llvm/llvm-project/commit/ca6d5813d17598cd180995fb3bdfca00f364475f Signed-off-by: Nathan Chancellor <nathan@xxxxxxxxxx> Signed-off-by: Masahiro Yamada <masahiroy@xxxxxxxxxx> -- Best Regards Masahiro Yamada