qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 0/2] linux-user: check clone flags for unsupported o


From: Peter Maydell
Subject: [Qemu-devel] [PATCH 0/2] linux-user: check clone flags for unsupported options
Date: Tue, 2 Aug 2016 18:41:25 +0100

This patchset adds checks on the flags passed to the clone syscall.
Previously we weren't checking the flags at all for the clone case,
which meant that some tests in the LTP testsuite would behave bizarrely
because we let the clone syscall succeed but didn't provide the
semantics requested by the flags. The patches add sanity checking
so that we fail (EINVAL) any flags or flag-combinations which we
can't support.

(Sadly we can't just implement clone by passing directly through
to the host syscall, because that would badly confuse libc, breaking
mutexes, getpid(), etc. So we can only support things we can
emulate via either fork() or pthread_create().)

The first patch is a minor cleanup; the second has the meat.

This is the last of the linux-user fixes I have on my plate
for fixing up LTP issues. (There are a pile of other LTP failures
but I don't think they're interesting enough to tackle until/unless
we get bug reports about real world programs which have the same
problems. I'll resend a summary report of remaining LTP failures
when the last of the patches eventually hits master, ie after
the 2.7 release.)

I don't think this patchset really needs to go into 2.7.

Git branch with this and all the rest at:
https://git.linaro.org/people/peter.maydell/qemu-arm.git linux-fixes

thanks
-- PMM


Peter Maydell (2):
  linux-user: Remove unnecessary nptl_flags variable from do_fork()
  linux-user: Sanity check clone flags

 linux-user/syscall.c | 82 ++++++++++++++++++++++++++++++++++++++++++++--------
 1 file changed, 70 insertions(+), 12 deletions(-)

-- 
1.9.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]