From: Paolo Bonzini <pbonzini@redhat.com>
To: Laszlo Ersek <lersek@redhat.com>, Max Reitz <mreitz@redhat.com>,
qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>, Stefan Hajnoczi <stefanha@redhat.com>
Subject: Re: [PATCH] coroutine-sigaltstack: Keep SIGUSR2 handler up
Date: Sat, 23 Jan 2021 23:13:09 +0100 [thread overview]
Message-ID: <063dd2a6-a3ae-0d7c-3e29-96a08a6d9a3d@redhat.com> (raw)
In-Reply-To: <cba8919b-0480-3520-6ad6-920bf9d4186e@redhat.com>
On 22/01/21 22:26, Laszlo Ersek wrote:
> That seems bogus, per POSIX, given that all signals except SIGUSR2 are
> included in the mask passed to sigsuspend().
What happens if you get a SIGSTOP at exactly the wrong time? (Yeah I
know how incredibly unlikely that would be).
BTW if we are in a mood for cleanup, there's no reason to use
pthread_key_t instead of __thread + qemu_thread_atexit_add (adding a
Notifier to struct CoroutineThreadState). That would fix the issue with
async-signal safety of pthread_getspecific.
(It makes sense for the function not to be async-signal safe since it
can in principle allocate memory for the data. In practice it's most
likely okay if the function has been called before on this thread).
Paolo
next prev parent reply other threads:[~2021-01-23 22:14 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-22 10:20 [PATCH] coroutine-sigaltstack: Keep SIGUSR2 handler up Max Reitz
2021-01-22 14:55 ` Eric Blake
2021-01-22 16:38 ` Laszlo Ersek
2021-01-22 17:58 ` Max Reitz
2021-01-22 18:19 ` Eric Blake
2021-01-22 18:28 ` Laszlo Ersek
2021-01-22 18:27 ` Laszlo Ersek
2021-01-22 19:02 ` Laszlo Ersek
2021-01-22 17:09 ` Laszlo Ersek
2021-01-22 18:05 ` Max Reitz
2021-01-22 18:29 ` Laszlo Ersek
2021-01-22 21:26 ` Laszlo Ersek
2021-01-23 0:41 ` Laszlo Ersek
2021-01-25 10:57 ` Max Reitz
2021-01-25 21:16 ` Laszlo Ersek
2021-01-23 22:13 ` Paolo Bonzini [this message]
2021-01-25 21:13 ` Laszlo Ersek
2021-01-25 22:08 ` Laszlo Ersek
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=063dd2a6-a3ae-0d7c-3e29-96a08a6d9a3d@redhat.com \
--to=pbonzini@redhat.com \
--cc=kwolf@redhat.com \
--cc=lersek@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
/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.