qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH for-8.1 0/2] linux-user: Fix MAP_SHARED_VALIDATE, MAP_FIXED_NOREPLACE
@ 2023-08-08  2:55 Richard Henderson
  2023-08-08  2:55 ` [PATCH 1/2] linux-user: Split out do_mmap Richard Henderson
  2023-08-08  2:55 ` [PATCH 2/2] linux-user: Use ARRAY_SIZE with bitmask_transtbl Richard Henderson
  0 siblings, 2 replies; 5+ messages in thread
From: Richard Henderson @ 2023-08-08  2:55 UTC (permalink / raw)
  To: qemu-devel; +Cc: mjt, laurent

Fixes LTP mmap17 (MAP_FIXED_NOREPLACE) and mmap20 (MAP_SHARED_VALIDATE),
both of which were added to linux-user during the 8.1 cycle, and so
would be nice to fix right away.

Does not fix mmap18, which will fail depending on the guest memory map.
The real kernel avoids placing new maps immediately prior to GROWSDOWN
regions (leaving them no room into which to expand) and qemu does not.
This is a long-standing problem and will not be fixable for 8.1.

Reported-by: Michael Tokarev <mjt@tls.msk.ru>


r~


Richard Henderson (2):
  linux-user: Split out do_mmap
  linux-user: Use ARRAY_SIZE with bitmask_transtbl

 bsd-user/syscall_defs.h   |  2 +
 include/exec/user/thunk.h | 15 ++++--
 linux-user/syscall.c      | 96 +++++++++++++++++++++++++++++----------
 linux-user/thunk.c        | 24 +++++-----
 4 files changed, 98 insertions(+), 39 deletions(-)

-- 
2.34.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-08-09  9:16 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-08  2:55 [PATCH for-8.1 0/2] linux-user: Fix MAP_SHARED_VALIDATE, MAP_FIXED_NOREPLACE Richard Henderson
2023-08-08  2:55 ` [PATCH 1/2] linux-user: Split out do_mmap Richard Henderson
2023-08-09  9:15   ` Alex Bennée
2023-08-08  2:55 ` [PATCH 2/2] linux-user: Use ARRAY_SIZE with bitmask_transtbl Richard Henderson
2023-08-09  9:14   ` Alex Bennée

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).