mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-12-11 16:00:50 -07:00
qdev/machine: Introduce hotplug_allowed hook
Introduce this new per-machine hook to give any machine class a chance to do a sanity check on the to-be-hotplugged device as a sanity test. This will be used for x86 to try to detect some illegal configuration of devices, e.g., possible conflictions between vfio-pci and x86 vIOMMU. Reviewed-by: Eric Auger <eric.auger@redhat.com> Signed-off-by: Peter Xu <peterx@redhat.com> Message-Id: <20190916080718.3299-3-peterx@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
28cf553afe
commit
d2321d31ff
4 changed files with 34 additions and 0 deletions
|
|
@ -280,6 +280,7 @@ void qdev_set_legacy_instance_id(DeviceState *dev, int alias_id,
|
|||
int required_for_version);
|
||||
HotplugHandler *qdev_get_bus_hotplug_handler(DeviceState *dev);
|
||||
HotplugHandler *qdev_get_machine_hotplug_handler(DeviceState *dev);
|
||||
bool qdev_hotplug_allowed(DeviceState *dev, Error **errp);
|
||||
/**
|
||||
* qdev_get_hotplug_handler: Get handler responsible for device wiring
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue