qemu/0034-kvmvapic-Enter-inactive-state-on-hardware-reset.patch
Cole Robinson 2983660f65 Rebase to pending 1.6.1 stable
CVE-2013-4377: Fix crash when unplugging virtio devices (bz #1012633, bz #1012641)
Fix 'new snapshot' slowness after the first snap (bz #988436)
Fix 9pfs xattrs on kernel 3.11 (bz #1013676)
CVE-2013-4344: buffer overflow in scsi_target_emulate_report_luns (bz #1015274, bz #1007330)
2013-10-06 14:33:55 -04:00

35 lines
1.1 KiB
Diff

From 7ea8a3c12aa49efc8f503a019dd764f8a0add2cb Mon Sep 17 00:00:00 2001
From: Jan Kiszka <jan.kiszka@siemens.com>
Date: Tue, 3 Sep 2013 18:08:51 +0200
Subject: [PATCH] kvmvapic: Enter inactive state on hardware reset
ROM layout may change after reset of devices are hotplugged, so we have
to pick up the physical address again when the ROM is initialized. This
is best achieved by resetting the state to INACTIVE.
CC: qemu-stable@nongnu.org
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
(cherry picked from commit c056bc3f3464cfae1c94b7dd633d3ec13b13b655)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
---
hw/i386/kvmvapic.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/hw/i386/kvmvapic.c b/hw/i386/kvmvapic.c
index 7ac0fe1..f2e335d 100644
--- a/hw/i386/kvmvapic.c
+++ b/hw/i386/kvmvapic.c
@@ -510,9 +510,7 @@ static void vapic_reset(DeviceState *dev)
{
VAPICROMState *s = VAPIC(dev);
- if (s->state == VAPIC_ACTIVE) {
- s->state = VAPIC_STANDBY;
- }
+ s->state = VAPIC_INACTIVE;
vapic_enable_tpr_reporting(false);
}