ANDROID: 16K: x86_64: Set ELF_EXEC_PAGESIZE to __PAGE_SIZE

In page-compat mode, set ELF_EXEC_PAGESIZE to the emulated page size.
This is the page size used by the kernel to determine the alignment
for ELF loading; and is what the kernel presents to userspace via the
auxillary vector.

Bug: 383389337
Bug: 315325080
Bug: 302403436
Change-Id: I4ea69a5d5cfc68760cff503019b4a4f44a333f23
Signed-off-by: Kalesh Singh <kaleshsingh@google.com>
This commit is contained in:
Kalesh Singh
2024-02-08 21:58:17 -08:00
committed by Carlos Llamas
parent 58e2fa4ec4
commit 80e2a42d97

View File

@@ -5,6 +5,7 @@
/*
* ELF register definitions..
*/
#include <linux/page_size_compat.h>
#include <linux/thread_info.h>
#include <asm/ia32.h>
@@ -228,7 +229,7 @@ extern int force_personality32;
#endif /* !CONFIG_X86_32 */
#define CORE_DUMP_USE_REGSET
#define ELF_EXEC_PAGESIZE 4096
#define ELF_EXEC_PAGESIZE __PAGE_SIZE
/*
* This is the base location for PIE (ET_DYN with INTERP) loads. On