All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Vivier <laurent@vivier.eu>
To: qemu-devel@nongnu.org
Cc: Aleksandar Rikalo <arikalo@wavecomp.com>,
	Riku Voipio <riku.voipio@iki.fi>,
	Richard Henderson <richard.henderson@linaro.org>,
	Laurent Vivier <laurent@vivier.eu>,
	Aleksandar Markovic <amarkovic@wavecomp.com>,
	Aurelien Jarno <aurelien@aurel32.net>
Subject: [Qemu-devel] [PULL 09/10] linux-user: Align mmap_find_vma to host page size
Date: Thu, 23 May 2019 16:43:35 +0200	[thread overview]
Message-ID: <20190523144336.13960-10-laurent@vivier.eu> (raw)
In-Reply-To: <20190523144336.13960-1-laurent@vivier.eu>

From: Richard Henderson <richard.henderson@linaro.org>

This can avoid stack allocation failures for i386 guest
on ppc64 (64k page) host.

Suggested-by: Laurent Vivier <laurent@vivier.eu>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20190519201953.20161-14-richard.henderson@linaro.org>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
---
 linux-user/mmap.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/linux-user/mmap.c b/linux-user/mmap.c
index 10796b37ac7b..af41339d576b 100644
--- a/linux-user/mmap.c
+++ b/linux-user/mmap.c
@@ -262,6 +262,8 @@ abi_ulong mmap_find_vma(abi_ulong start, abi_ulong size, abi_ulong align)
     abi_ulong addr;
     int wrapped, repeat;
 
+    align = MAX(align, qemu_host_page_size);
+
     /* If 'start' == 0, then a default start address is used. */
     if (start == 0) {
         start = mmap_next_start;
-- 
2.20.1



  parent reply	other threads:[~2019-05-23 14:52 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-23 14:43 [Qemu-devel] [PULL 00/10] Linux user for 4.1 patches Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 01/10] linux-user: add pseudo /proc/cpuinfo for sparc Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 02/10] linux-user: add pseudo /proc/hardware for m68k Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 03/10] linux-user: Fix support for SIOCATMARK and SIOCGPGRP ioctls for xtensa Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 04/10] linux-user: Add support for SIOCSPGRP ioctl for all targets Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 05/10] linux-user: Add support for SIOC<G|S>IFPFLAGS ioctls " Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 06/10] linux-user: Sanitize interp_info and, for mips only, init field fp_abi Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 07/10] linux-user: Add support for setsockopt() options IPV6_<ADD|DROP>_MEMBERSHIP Laurent Vivier
2019-05-23 14:43 ` [Qemu-devel] [PULL 08/10] linux-user: Fix shmat emulation by honoring host SHMLBA Laurent Vivier
2019-05-23 14:43 ` Laurent Vivier [this message]
2019-05-23 14:43 ` [Qemu-devel] [PULL 10/10] linux-user: Pass through nanosecond timestamp components for stat syscalls Laurent Vivier
2019-05-23 16:36 ` [Qemu-devel] [PULL 00/10] Linux user for 4.1 patches no-reply
2019-05-23 17:31   ` Aleksandar Markovic
2019-05-24 11:07 ` Peter Maydell
2019-05-24 11:19   ` Laurent Vivier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190523144336.13960-10-laurent@vivier.eu \
    --to=laurent@vivier.eu \
    --cc=amarkovic@wavecomp.com \
    --cc=arikalo@wavecomp.com \
    --cc=aurelien@aurel32.net \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=riku.voipio@iki.fi \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.