From: Jan Kiszka <jan.kiszka@web.de>
To: Avi Kivity <avi@redhat.com>, Marcelo Tosatti <mtosatti@redhat.com>
Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org,
Huang Ying <ying.huang@intel.com>
Subject: [Qemu-devel] [PATCH 11.5/21] Synchronize VCPU states before reset
Date: Wed, 05 Jan 2011 13:18:53 +0100 [thread overview]
Message-ID: <4D2461AD.3060907@web.de> (raw)
In-Reply-To: <cover.1294129949.git.jan.kiszka@web.de>
From: Jan Kiszka <jan.kiszka@siemens.com>
This is required to support keeping VCPU states across a system reset.
If we do not read the current state before the reset,
cpu_synchronize_all_post_reset may write back incorrect state
information.
The first user of this will be MCE MSR synchronization which currently
works around the missing cpu_synchronize_all_states.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
This must be applied before "Drop MCE MSRs write back restrictions" (I
don't want to resend the whole series for this).
vl.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/vl.c b/vl.c
index 768dbf4..20e5dda 100644
--- a/vl.c
+++ b/vl.c
@@ -1422,6 +1422,7 @@ static void main_loop(void)
}
if (qemu_reset_requested()) {
pause_all_vcpus();
+ cpu_synchronize_all_states();
qemu_system_reset();
resume_all_vcpus();
}
next prev parent reply other threads:[~2011-01-05 12:19 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-04 8:32 [Qemu-devel] [PATCH v3 00/21] [uq/master] Prepare for more qemu-kvm merging Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 01/21] kvm: Fix coding style violations Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 02/21] kvm: Drop return value of kvm_cpu_exec Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 03/21] kvm: Stop on all fatal exit reasons Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 04/21] kvm: Improve reporting of fatal errors Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 05/21] x86: Optionally dump code bytes on cpu_dump_state Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 06/21] kvm: x86: Align kvm_arch_put_registers code with comment Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 07/21] kvm: x86: Prepare kvm_get_mp_state for in-kernel irqchip Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 08/21] kvm: x86: Remove redundant mp_state initialization Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 09/21] kvm: x86: Fix xcr0 reset mismerge Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 10/21] kvm: x86: Refactor msr_star/hsave_pa setup and checks Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 11/21] kvm: x86: Reset paravirtual MSRs Jan Kiszka
2011-01-04 11:06 ` [Qemu-devel] " Glauber Costa
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 12/21] kvm: x86: Drop MCE MSRs write back restrictions Jan Kiszka
2011-01-05 6:42 ` [Qemu-devel] " Huang Ying
2011-01-05 8:07 ` Jan Kiszka
2011-01-05 8:33 ` Huang Ying
2011-01-05 9:06 ` Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 13/21] kvm: Eliminate KVMState arguments Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 14/21] kvm: x86: Fix !CONFIG_KVM_PARA build Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 15/21] kvm: x86: Introduce kvmclock device to save/restore its state Jan Kiszka
2011-01-04 11:08 ` [Qemu-devel] " Glauber Costa
2011-01-04 11:34 ` Jan Kiszka
2011-01-04 11:43 ` Glauber Costa
2011-01-04 11:45 ` Jan Kiszka
2011-01-04 11:48 ` Glauber Costa
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 16/21] kvm: Drop smp_cpus argument from init functions Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 17/21] kvm: Consolidate must-have capability checks Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 18/21] kvm: x86: Rework identity map and TSS setup for larger BIOS sizes Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 19/21] kvm: Flush coalesced mmio buffer on IO window exits Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 20/21] kvm: Do not use qemu_fair_mutex Jan Kiszka
2011-01-04 8:32 ` [Qemu-devel] [PATCH v3 21/21] kvm: x86: Implicitly clear nmi_injected/pending on reset Jan Kiszka
2011-01-05 12:18 ` Jan Kiszka [this message]
2011-01-05 12:28 ` [Qemu-devel] [PATCH 22/21] kvm: x86: Only read/write MSR_KVM_ASYNC_PF_EN if supported Jan Kiszka
2011-01-05 16:32 ` [Qemu-devel] Re: [PATCH v3 00/21] [uq/master] Prepare for more qemu-kvm merging Marcelo Tosatti
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=4D2461AD.3060907@web.de \
--to=jan.kiszka@web.de \
--cc=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=ying.huang@intel.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 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).