Messages in this thread | | | From | Masahiro Yamada <> | Date | Thu, 26 Jan 2023 13:23:53 +0900 | Subject | Re: [PATCH] powerpc/vdso: Filter clang's auto var init zero enabler when linking |
| |
On Wed, Jan 25, 2023 at 1:20 AM Nathan Chancellor <nathan@kernel.org> 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@kernel.org> > --- > 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@kernel.org> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
-- Best Regards Masahiro Yamada
| |