From c2c00148ec54f77c9432fec16585834e1d677fda Mon Sep 17 00:00:00 2001 From: Pavel Dovgalyuk Date: Thu, 28 Aug 2014 15:18:57 +0400 Subject: apic_common: migrate missing fields This patch adds missed sipi_vector and wait_for_sipi fields to a new subsection of the vmstate of the apic_common module. Saving and loading of these fields makes migration of the apic state deterministic. Signed-off-by: Pavel Dovgalyuk [Initialize the field in pre_load and kvm_apic_realize. - Paolo] Signed-off-by: Paolo Bonzini --- hw/i386/kvm/apic.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'hw/i386/kvm/apic.c') diff --git a/hw/i386/kvm/apic.c b/hw/i386/kvm/apic.c index e873b509a5..271e97f86f 100644 --- a/hw/i386/kvm/apic.c +++ b/hw/i386/kvm/apic.c @@ -175,6 +175,9 @@ static void kvm_apic_realize(DeviceState *dev, Error **errp) { APICCommonState *s = APIC_COMMON(dev); + /* Not used by KVM, which uses the CPU mp_state instead. */ + s->wait_for_sipi = 0; + memory_region_init_io(&s->io_memory, NULL, &kvm_apic_io_ops, s, "kvm-apic-msi", APIC_SPACE_SIZE); -- cgit 1.4.1