From 014176f914ab8e41a88225e8f26569ef0e0bf223 Mon Sep 17 00:00:00 2001 From: Igor Mammedov Date: Fri, 26 Sep 2014 09:28:21 +0000 Subject: qdev: Add simple/generic unplug callback for HotplugHandler It will be used in shallow conversion from legacy hotplug mechanism and eventually replace all the uses of old mechanism DeviceClass::unplug = qdev_simple_unplug_cb() Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini Signed-off-by: Andreas Färber --- hw/core/qdev.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'hw/core') diff --git a/hw/core/qdev.c b/hw/core/qdev.c index 6479194498..9f18520219 100644 --- a/hw/core/qdev.c +++ b/hw/core/qdev.c @@ -286,6 +286,11 @@ int qdev_simple_unplug_cb(DeviceState *dev) return 0; } +void qdev_simple_device_unplug_cb(HotplugHandler *hotplug_dev, + DeviceState *dev, Error **errp) +{ + qdev_simple_unplug_cb(dev); +} /* Like qdev_init(), but terminate program via error_report() instead of returning an error value. This is okay during machine creation. -- cgit v1.2.3-55-g7522