All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alex Bennée" <alex.bennee@linaro.org>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
	qemu-devel@nongnu.org, Stefan Hajnoczi <stefanha@redhat.com>,
	patches@linaro.org
Subject: Re: [Qemu-devel] [PATCH] main-loop.c: Handle SIGINT, SIGHUP and SIGTERM synchronously
Date: Fri, 26 Sep 2014 11:37:13 +0100	[thread overview]
Message-ID: <87mw9m1xhg.fsf@linaro.org> (raw)
In-Reply-To: <1411660269-11081-1-git-send-email-peter.maydell@linaro.org>


Peter Maydell <peter.maydell@linaro.org> writes:

> Add the termination signals SIGINT, SIGHUP and SIGTERM to the
> list of signals which we handle synchronously via a signalfd.
> This avoids a race condition where if we took the SIGTERM
> in the middle of qemu_shutdown_requested:
>     int r = shutdown_requested;
> [SIGTERM here...]
>     shutdown_requested = 0;
>
> then the setting of the shutdown_requested flag by
> termsig_handler() would be lost and QEMU would fail to
> shut down. This was causing 'make check' to hang occasionally.
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> Cc: qemu-stable@nongnu.org
<snip>

I've been testing it with my latest Travis patches (- the make check
once patch) and it seems a lot better now:

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Tested-by: Alex Bennée <alex.bennee@linaro.org>

-- 
Alex Bennée

  parent reply	other threads:[~2014-09-26 10:37 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-25 15:51 [Qemu-devel] [PATCH] main-loop.c: Handle SIGINT, SIGHUP and SIGTERM synchronously Peter Maydell
2014-09-25 15:54 ` Paolo Bonzini
2014-09-26 10:37 ` Alex Bennée [this message]
2014-09-26 11:25   ` Peter Maydell
2014-10-25 11:34 ` Gonglei
2014-10-25 12:08   ` Jan Kiszka

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=87mw9m1xhg.fsf@linaro.org \
    --to=alex.bennee@linaro.org \
    --cc=patches@linaro.org \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --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.