mirror of https://gitee.com/openkylin/libvirt.git
qemu: Introduce qemuDomainNeedsVFIO
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
parent
f988128cc1
commit
78f0f2d273
|
@ -29,6 +29,7 @@
|
|||
#include "qemu_dbus.h"
|
||||
#include "qemu_process.h"
|
||||
#include "qemu_capabilities.h"
|
||||
#include "qemu_hostdev.h"
|
||||
#include "qemu_migration.h"
|
||||
#include "qemu_migration_params.h"
|
||||
#include "qemu_security.h"
|
||||
|
@ -12712,6 +12713,14 @@ qemuDomainSupportsVideoVga(virDomainVideoDefPtr video,
|
|||
}
|
||||
|
||||
|
||||
bool
|
||||
qemuDomainNeedsVFIO(const virDomainDef *def)
|
||||
{
|
||||
return virDomainDefHasVFIOHostdev(def) ||
|
||||
virDomainDefHasMdevHostdev(def);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* qemuDomainGetHostdevPath:
|
||||
* @def: domain definition
|
||||
|
|
|
@ -1070,6 +1070,8 @@ int qemuDomainCheckMonitor(virQEMUDriverPtr driver,
|
|||
bool qemuDomainSupportsVideoVga(virDomainVideoDefPtr video,
|
||||
virQEMUCapsPtr qemuCaps);
|
||||
|
||||
bool qemuDomainNeedsVFIO(const virDomainDef *def);
|
||||
|
||||
int qemuDomainGetHostdevPath(virDomainDefPtr def,
|
||||
virDomainHostdevDefPtr dev,
|
||||
bool teardown,
|
||||
|
|
Loading…
Reference in New Issue