From 314992b1a48a5a2a0f2b14195f959ad2c3f5b3ff Mon Sep 17 00:00:00 2001 From: Alexander Graf Date: Thu, 3 Jan 2013 14:17:18 +0100 Subject: [PATCH] linux-user: fix mips 32-on-64 prealloc case MIPS only supports 31 bits of virtual address space for user space, so let's make sure we stay within that limit with our preallocated memory block. This fixes the MIPS user space targets when executed without command line option. Signed-off-by: Alexander Graf Signed-off-by: Aurelien Jarno --- linux-user/main.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/linux-user/main.c b/linux-user/main.c index f6c4c8d7a3..9ade1bfabd 100644 --- a/linux-user/main.c +++ b/linux-user/main.c @@ -57,7 +57,12 @@ int have_guest_base; * This way we will never overlap with our own libraries or binaries or stack * or anything else that QEMU maps. */ +# ifdef TARGET_MIPS +/* MIPS only supports 31 bits of virtual address space for user space */ +unsigned long reserved_va = 0x77000000; +# else unsigned long reserved_va = 0xf7000000; +# endif #else unsigned long reserved_va; #endif -- GitLab