* [PATCH V2] KVM: x86: disable stealtime on reboot to avoid mem corruption
@ 2012-08-15 14:00 Florian Westphal
2012-08-15 18:31 ` Marcelo Tosatti
0 siblings, 1 reply; 2+ messages in thread
From: Florian Westphal @ 2012-08-15 14:00 UTC (permalink / raw)
To: kvm; +Cc: mtosatti, linux-kernel, glommer, Florian Westphal
else, host continues to update stealtime after reboot,
which can corrupt e.g. initramfs area.
found when tracking down initramfs unpack error on initial reboot
(with qemu-kvm -smp 2, no problem with single-core).
Signed-off-by: Florian Westphal <fw@strlen.de>
---
arch/x86/kernel/kvm.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
Changes since v1:
- leave arch/x86/kernel/kvmclock.c as-is (requested by Marcelo)
diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c
index c1d61ee..1596cc8 100644
--- a/arch/x86/kernel/kvm.c
+++ b/arch/x86/kernel/kvm.c
@@ -354,6 +354,7 @@ static void kvm_pv_guest_cpu_reboot(void *unused)
if (kvm_para_has_feature(KVM_FEATURE_PV_EOI))
wrmsrl(MSR_KVM_PV_EOI_EN, 0);
kvm_pv_disable_apf();
+ kvm_disable_steal_time();
}
static int kvm_pv_reboot_notify(struct notifier_block *nb,
--
1.7.8.6
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH V2] KVM: x86: disable stealtime on reboot to avoid mem corruption
2012-08-15 14:00 [PATCH V2] KVM: x86: disable stealtime on reboot to avoid mem corruption Florian Westphal
@ 2012-08-15 18:31 ` Marcelo Tosatti
0 siblings, 0 replies; 2+ messages in thread
From: Marcelo Tosatti @ 2012-08-15 18:31 UTC (permalink / raw)
To: Florian Westphal; +Cc: kvm, linux-kernel, glommer
On Wed, Aug 15, 2012 at 04:00:40PM +0200, Florian Westphal wrote:
> else, host continues to update stealtime after reboot,
> which can corrupt e.g. initramfs area.
> found when tracking down initramfs unpack error on initial reboot
> (with qemu-kvm -smp 2, no problem with single-core).
>
> Signed-off-by: Florian Westphal <fw@strlen.de>
Applied, thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-08-15 18:31 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-15 14:00 [PATCH V2] KVM: x86: disable stealtime on reboot to avoid mem corruption Florian Westphal
2012-08-15 18:31 ` Marcelo Tosatti
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).