From 1e680bc92e31321795dd0b69f579df927bb9da4a Mon Sep 17 00:00:00 2001
From: Liu Jinsong <jinsong.liu@intel.com>
Date: Wed, 18 Aug 2010 14:18:56 +0800
Subject: [PATCH] Fix bug for vcpu hotplug

Recently seabios implement vcpu hotplug infrastructure.
During test, we found qemu-kvm has a bug result in guestos shutdown when vcpu hotadd.
This patch is to fix the bug, allow hotplug for sysbus qdev.

Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
---
 hw/qdev.c        |    1 +
 pc-bios/bios.bin |  Bin 131072 -> 131072 bytes
 2 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/hw/qdev.c b/hw/qdev.c
index e99c73f..66a5f82 100644
--- a/hw/qdev.c
+++ b/hw/qdev.c
@@ -108,6 +108,7 @@ DeviceState *qdev_create(BusState *bus, const char *name)
     if (!bus) {
         if (!main_system_bus) {
             main_system_bus = qbus_create(&system_bus_info, NULL, "main-system-bus");
+            main_system_bus->allow_hotplug = 1;
         }
         bus = main_system_bus;
     }
diff --git a/pc-bios/bios.bin b/pc-bios/bios.bin
index d0d4b6a..e98f96c 100644
Binary files a/pc-bios/bios.bin and b/pc-bios/bios.bin differ
-- 
1.6.5.6

