]> git.proxmox.com Git - qemu.git/commitdiff
kvmvapic: Clear also physical ROM address when entering INACTIVE state
authorJan Kiszka <jan.kiszka@siemens.com>
Tue, 3 Sep 2013 16:08:52 +0000 (18:08 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 20 Sep 2013 10:37:52 +0000 (12:37 +0200)
To avoid misinterpreting INACTIVE after migration as old qemu-kvm's
STANDBY, also clear rom_state_paddr when going back to this state.

CC: qemu-stable@nongnu.org
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
hw/i386/kvmvapic.c

index e4cea34865b863a1ff124f75ee00b6cabb0e8ec2..1c2dbf59cf67112a70ed9137e7c1b0c7aeddebef 100644 (file)
@@ -511,6 +511,7 @@ static void vapic_reset(DeviceState *dev)
     VAPICROMState *s = VAPIC(dev);
 
     s->state = VAPIC_INACTIVE;
+    s->rom_state_paddr = 0;
     vapic_enable_tpr_reporting(false);
 }
 
@@ -664,6 +665,7 @@ static void vapic_write(void *opaque, hwaddr addr, uint64_t data,
         }
         if (vapic_prepare(s) < 0) {
             s->state = VAPIC_INACTIVE;
+            s->rom_state_paddr = 0;
             break;
         }
         break;