Blame 0035-kvmvapic-Clear-also-physical-ROM-address-when-enteri.patch

298366
From 5d2de77798cacf1dadf6a4211972473e057cc6e5 Mon Sep 17 00:00:00 2001
298366
From: Jan Kiszka <jan.kiszka@siemens.com>
298366
Date: Tue, 3 Sep 2013 18:08:52 +0200
298366
Subject: [PATCH] kvmvapic: Clear also physical ROM address when entering
298366
 INACTIVE state
298366
298366
To avoid misinterpreting INACTIVE after migration as old qemu-kvm's
298366
STANDBY, also clear rom_state_paddr when going back to this state.
298366
298366
CC: qemu-stable@nongnu.org
298366
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
298366
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
298366
(cherry picked from commit 4357930b8a7d2fcff2d8121ec518117428a781e7)
298366
298366
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
298366
---
298366
 hw/i386/kvmvapic.c | 2 ++
298366
 1 file changed, 2 insertions(+)
298366
298366
diff --git a/hw/i386/kvmvapic.c b/hw/i386/kvmvapic.c
298366
index f2e335d..cf6c714 100644
298366
--- a/hw/i386/kvmvapic.c
298366
+++ b/hw/i386/kvmvapic.c
298366
@@ -511,6 +511,7 @@ static void vapic_reset(DeviceState *dev)
298366
     VAPICROMState *s = VAPIC(dev);
298366
 
298366
     s->state = VAPIC_INACTIVE;
298366
+    s->rom_state_paddr = 0;
298366
     vapic_enable_tpr_reporting(false);
298366
 }
298366
 
298366
@@ -664,6 +665,7 @@ static void vapic_write(void *opaque, hwaddr addr, uint64_t data,
298366
         }
298366
         if (vapic_prepare(s) < 0) {
298366
             s->state = VAPIC_INACTIVE;
298366
+            s->rom_state_paddr = 0;
298366
             break;
298366
         }
298366
         break;