提交 cc601cb7 编写于 作者: M Markus Armbruster 提交者: Aurelien Jarno

qdev: Convert qdev_unplug() to QError

Note: our device unplug methods don't need conversion work, because
they can't currently fail.
Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
上级 07a5d95a
......@@ -287,8 +287,7 @@ int qdev_init(DeviceState *dev)
int qdev_unplug(DeviceState *dev)
{
if (!dev->parent_bus->allow_hotplug) {
error_report("Bus %s does not support hotplugging",
dev->parent_bus->name);
qerror_report(QERR_BUS_NO_HOTPLUG, dev->parent_bus->name);
return -1;
}
assert(dev->info->unplug != NULL);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册