OSDN Git Service

ANDROID: Revert "arm64: move ELF_ET_DYN_BASE to 4GB / 4MB"
authorEvgenii Stepanov <eugenis@google.com>
Wed, 1 Nov 2017 22:10:12 +0000 (15:10 -0700)
committerAmit Pundir <amit.pundir@linaro.org>
Tue, 14 Aug 2018 12:17:11 +0000 (17:47 +0530)
Part of the above change was reverted in c715b72c1ba406f133217b509044c38d8e714a37;
this change reverts the rest.

This ARM mmap change breaks AddressSanitizer:

Shadow memory range interleaves with an existing memory mapping. ASan cannot proceed correctly. ABORTING.

Revert it until ASAN runtime library is updated to handle it.

Bug: 67425063

Signed-off-by: Evgenii Stepanov <eugenis@google.com>
[AmitP: Updated the commit ID of the upstream commit]
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
arch/arm64/include/asm/elf.h

index 433b955..e05f48b 100644 (file)
@@ -186,7 +186,7 @@ extern int arch_setup_additional_pages(struct linux_binprm *bprm,
 #ifdef CONFIG_COMPAT
 
 /* PIE load location for compat arm. Must match ARM ELF_ET_DYN_BASE. */
-#define COMPAT_ELF_ET_DYN_BASE         0x000400000UL
+#define COMPAT_ELF_ET_DYN_BASE         (2 * TASK_SIZE_32 / 3)
 
 /* AArch32 registers. */
 #define COMPAT_ELF_NGREG               18