From: Gleb Natapov <gleb@redhat.com>
To: Jan Kiszka <jan.kiszka@web.de>
Cc: kvm <kvm@vger.kernel.org>, qemu-devel <qemu-devel@nongnu.org>
Subject: Re: qemu-kvm vs. qemu: Terminate cpu loop on reset?
Date: Fri, 7 Jan 2011 18:53:59 +0200 [thread overview]
Message-ID: <20110107165359.GA10205@redhat.com> (raw)
In-Reply-To: <4D2737EB.6070002@web.de>
On Fri, Jan 07, 2011 at 04:57:31PM +0100, Jan Kiszka wrote:
> Hi,
>
> does anyone immediately know if this hunk from vl.c
>
> @@ -1278,6 +1197,10 @@ void qemu_system_reset_request(void)
> } else {
> reset_requested = 1;
> }
> + if (cpu_single_env) {
> + cpu_single_env->stopped = 1;
> + cpu_exit(cpu_single_env);
> + }
> qemu_notify_event();
> }
>
> is (semantically) relevant for upstream as well? IIUC, it ensures that
> the kvm cpu loop is not continued if an IO access called into
> qemu_system_reset_request.
>
I don't know TCG enough to tell. If TCG can continue vcpu execution
after io without checking reset_requested then it is relevant for
upstream too.
> If yes, then it would be a good time to push a patch: these bits will
> fall to dust on next merge from upstream (vl.c no longer has access to
> the cpu state).
>
On a next merge cpu state will have to be exposed to vl.c then. This
code cannot be dropped in qemu-kvm.
--
Gleb.
WARNING: multiple messages have this Message-ID (diff)
From: Gleb Natapov <gleb@redhat.com>
To: Jan Kiszka <jan.kiszka@web.de>
Cc: qemu-devel <qemu-devel@nongnu.org>, kvm <kvm@vger.kernel.org>
Subject: [Qemu-devel] Re: qemu-kvm vs. qemu: Terminate cpu loop on reset?
Date: Fri, 7 Jan 2011 18:53:59 +0200 [thread overview]
Message-ID: <20110107165359.GA10205@redhat.com> (raw)
In-Reply-To: <4D2737EB.6070002@web.de>
On Fri, Jan 07, 2011 at 04:57:31PM +0100, Jan Kiszka wrote:
> Hi,
>
> does anyone immediately know if this hunk from vl.c
>
> @@ -1278,6 +1197,10 @@ void qemu_system_reset_request(void)
> } else {
> reset_requested = 1;
> }
> + if (cpu_single_env) {
> + cpu_single_env->stopped = 1;
> + cpu_exit(cpu_single_env);
> + }
> qemu_notify_event();
> }
>
> is (semantically) relevant for upstream as well? IIUC, it ensures that
> the kvm cpu loop is not continued if an IO access called into
> qemu_system_reset_request.
>
I don't know TCG enough to tell. If TCG can continue vcpu execution
after io without checking reset_requested then it is relevant for
upstream too.
> If yes, then it would be a good time to push a patch: these bits will
> fall to dust on next merge from upstream (vl.c no longer has access to
> the cpu state).
>
On a next merge cpu state will have to be exposed to vl.c then. This
code cannot be dropped in qemu-kvm.
--
Gleb.
next prev parent reply other threads:[~2011-01-07 16:54 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-07 15:57 qemu-kvm vs. qemu: Terminate cpu loop on reset? Jan Kiszka
2011-01-07 15:57 ` [Qemu-devel] " Jan Kiszka
2011-01-07 16:53 ` Gleb Natapov [this message]
2011-01-07 16:53 ` [Qemu-devel] " Gleb Natapov
2011-01-07 16:59 ` Jan Kiszka
2011-01-07 16:59 ` [Qemu-devel] " Jan Kiszka
2011-01-07 17:16 ` Gleb Natapov
2011-01-07 17:16 ` [Qemu-devel] " Gleb Natapov
2011-01-07 17:30 ` Jan Kiszka
2011-01-07 17:30 ` [Qemu-devel] " Jan Kiszka
2011-01-07 17:53 ` Gleb Natapov
2011-01-07 17:53 ` [Qemu-devel] " Gleb Natapov
2011-01-07 18:24 ` Jan Kiszka
2011-01-07 18:24 ` [Qemu-devel] " Jan Kiszka
2011-01-07 18:32 ` Jan Kiszka
2011-01-07 18:32 ` [Qemu-devel] " Jan Kiszka
2011-01-07 19:10 ` Gleb Natapov
2011-01-07 19:10 ` [Qemu-devel] " Gleb Natapov
2011-01-07 19:33 ` Jan Kiszka
2011-01-07 19:33 ` [Qemu-devel] " Jan Kiszka
2011-01-07 21:19 ` Gleb Natapov
2011-01-07 21:19 ` [Qemu-devel] " Gleb Natapov
2011-01-08 9:12 ` Jan Kiszka
2011-01-08 9:12 ` [Qemu-devel] " 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=20110107165359.GA10205@redhat.com \
--to=gleb@redhat.com \
--cc=jan.kiszka@web.de \
--cc=kvm@vger.kernel.org \
--cc=qemu-devel@nongnu.org \
/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.