]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
arm64: vdso32: Fix broken compat vDSO build warnings
authorVincenzo Frascino <vincenzo.frascino@arm.com>
Thu, 3 Oct 2019 17:48:33 +0000 (18:48 +0100)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 12 Nov 2019 17:47:09 +0000 (18:47 +0100)
commit5b042a3970f13d1d10ba443786ada1cbeea3a2dd
treebc9fc4a6b9af28f36d2880cad3dfccc3fb81ea88
parentaf25f68fc40082b84ca6b5ce49200a9effc088c6
arm64: vdso32: Fix broken compat vDSO build warnings

BugLink: https://bugs.launchpad.net/bugs/1851550
[ Upstream commit e0de01aafc3dd7b73308106b056ead2d48391905 ]

The .config file and the generated include/config/auto.conf can
end up out of sync after a set of commands since
CONFIG_CROSS_COMPILE_COMPAT_VDSO is not updated correctly.

The sequence can be reproduced as follows:

$ make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- defconfig
[...]
$ make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- menuconfig
[set CONFIG_CROSS_COMPILE_COMPAT_VDSO="arm-linux-gnueabihf-"]
$ make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu-

Which results in:

arch/arm64/Makefile:62: CROSS_COMPILE_COMPAT not defined or empty,
the compat vDSO will not be built

even though the compat vDSO has been built:

$ file arch/arm64/kernel/vdso32/vdso.so
arch/arm64/kernel/vdso32/vdso.so: ELF 32-bit LSB pie executable, ARM,
EABI5 version 1 (SYSV), dynamically linked,
BuildID[sha1]=c67f6c786f2d2d6f86c71f708595594aa25247f6, stripped

A similar case that involves changing the configuration parameter
multiple times can be reconducted to the same family of problems.

Remove the use of CONFIG_CROSS_COMPILE_COMPAT_VDSO altogether and
instead rely on the cross-compiler prefix coming from the environment
via CROSS_COMPILE_COMPAT, much like we do for the rest of the kernel.

Cc: Will Deacon <will@kernel.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Reported-by: Will Deacon <will@kernel.org>
Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Signed-off-by: Will Deacon <will@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
arch/arm64/Kconfig
arch/arm64/Makefile
arch/arm64/kernel/vdso32/Makefile