Re: [PATCH] arm64: vdso32: force vdso32 to be compiled as -marm

From: Nick Desaulniers
Date: Wed May 27 2020 - 13:58:55 EST


On Wed, May 27, 2020 at 6:53 AM Dave Martin <Dave.Martin@xxxxxxx> wrote:
>
> On Tue, May 26, 2020 at 09:45:05PM +0100, Will Deacon wrote:
> > On Tue, 26 May 2020 10:31:14 -0700, Nick Desaulniers wrote:
> > > Custom toolchains that modify the default target to -mthumb cannot
>
> It's probably too late to water this down, but it's unfortunate to have
> this comment in the upstream commit history.
>
> It's not constructive to call the native compiler configuration of
> major distros for many years a "custom" toolchain. Unmodified GCC has

I don't think you know which toolchain or distro I'm referring to. ;)

> had a clean configure option for this for a very long time; it's not
> someone's dirty hack. (The wisdom of armhf's choice of -mthumb might
> be debated, but it is well established.)
>
> Ignoring the triplet and passing random options to a compiler in the
> hopes that it will do the right thing for an irregular usecase has never
> been reliable. Usecases don't get much more irregular than building
> vdso32.
>
> arch/arm has the proper options in its Makefiles.
>
> This patch is a kernel bugfix, plain and simple.

Borrowing from the Zen of Python: Explicit is better than Implicit.
Better not to rely on implicit defaults that may be changed at configure time.

> Does this need to go to stable?

Oh, probably. Need to wait until it hits mainline now. I don't think
the compat vdso series was backported to 5.4, but IIUC stable
maintains a branch for the latest release, which would have that
series.

--
Thanks,
~Nick Desaulniers