From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-devel@nongnu.org
Cc: Riku Voipio <riku.voipio@iki.fi>, patches@linaro.org
Subject: [Qemu-devel] [PATCH 0/2] linux-user: check clone flags for unsupported options
Date: Tue, 2 Aug 2016 18:41:25 +0100 [thread overview]
Message-ID: <1470159687-16428-1-git-send-email-peter.maydell@linaro.org> (raw)
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
next reply other threads:[~2016-08-02 17:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-02 17:41 Peter Maydell [this message]
2016-08-02 17:41 ` [Qemu-devel] [PATCH 1/2] linux-user: Remove unnecessary nptl_flags variable from do_fork() Peter Maydell
2016-08-02 17:41 ` [Qemu-devel] [PATCH 2/2] linux-user: Sanity check clone flags Peter Maydell
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=1470159687-16428-1-git-send-email-peter.maydell@linaro.org \
--to=peter.maydell@linaro.org \
--cc=patches@linaro.org \
--cc=qemu-devel@nongnu.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 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).