qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH v6 27/27] bootindex: delete bootindex when device is


From: arei.gonglei
Subject: [Qemu-devel] [PATCH v6 27/27] bootindex: delete bootindex when device is removed
Date: Sat, 30 Aug 2014 18:00:27 +0800

From: Gonglei <address@hidden>

Device should be removed from global boot list when
it is hot-unplugged.

Signed-off-by: Gonglei <address@hidden>
Signed-off-by: Chenliang <address@hidden>
---
 hw/core/qdev.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/hw/core/qdev.c b/hw/core/qdev.c
index da1ba48..70294ad 100644
--- a/hw/core/qdev.c
+++ b/hw/core/qdev.c
@@ -972,6 +972,10 @@ static void device_finalize(Object *obj)
     NamedGPIOList *ngl, *next;
 
     DeviceState *dev = DEVICE(obj);
+
+    /* remove device's bootindex from global boot order list */
+    del_boot_device_path(dev);
+
     if (dev->opts) {
         qemu_opts_del(dev->opts);
     }
-- 
1.7.12.4





reply via email to

[Prev in Thread] Current Thread [Next in Thread]