Commit 3d6a7b99 authored by Andrew Pinski's avatar Andrew Pinski Committed by Catalin Marinas

arm64: ensure the kernel is compiled for LP64

The kernel needs to be compiled as a LP64 binary for ARM64, even when
using a compiler that defaults to code-generation for the ILP32 ABI.
Consequently, we need to explicitly pass '-mabi=lp64' (supported on
gcc-4.9 and newer).
Signed-off-by: default avatarAndrew Pinski <>
Signed-off-by: Philipp Tomsich's avatarPhilipp Tomsich <>
Signed-off-by: default avatarChristoph Muellner <>
Signed-off-by: default avatarYury Norov <>
Reviewed-by: default avatarDavid Daney <>
Signed-off-by: default avatarCatalin Marinas <>
parent c73cc120
......@@ -50,17 +50,22 @@ KBUILD_CFLAGS += -fno-asynchronous-unwind-tables
KBUILD_CFLAGS += $(call cc-option, -mpc-relative-literal-loads)
KBUILD_AFLAGS += $(lseinstr) $(brokengasinst)
KBUILD_CFLAGS += $(call cc-option,-mabi=lp64)
KBUILD_AFLAGS += $(call cc-option,-mabi=lp64)
KBUILD_CPPFLAGS += -mbig-endian
AS += -EB
LD += -EB
LDFLAGS += -maarch64linuxb
UTS_MACHINE := aarch64_be
KBUILD_CPPFLAGS += -mlittle-endian
AS += -EL
LD += -EL
LDFLAGS += -maarch64linux
UTS_MACHINE := aarch64
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment