Signed-off-by: Jiri Denemark <jdenemar@xxxxxxxxxx> --- Notes: Version 3: - new patch src/qemu/qemu_capabilities.c | 28 ++++++++++++++-------------- src/qemu/qemu_capabilities.h | 3 --- 2 files changed, 14 insertions(+), 17 deletions(-) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index b9307730f1..0f3c061003 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -2429,6 +2429,20 @@ virQEMUCapsProbeQMPMachineTypes(virQEMUCapsPtr qemuCaps, } +static bool +virQEMUCapsIsMachineSupported(virQEMUCapsPtr qemuCaps, + const char *canonical_machine) +{ + size_t i; + + for (i = 0; i < qemuCaps->nmachineTypes; i++) { + if (STREQ(canonical_machine, qemuCaps->machineTypes[i].name)) + return true; + } + return false; +} + + static int virQEMUCapsProbeQMPMachineProps(virQEMUCapsPtr qemuCaps, qemuMonitorPtr mon) @@ -5146,20 +5160,6 @@ virQEMUCapsSupportsVmport(virQEMUCapsPtr qemuCaps, } -bool -virQEMUCapsIsMachineSupported(virQEMUCapsPtr qemuCaps, - const char *canonical_machine) -{ - size_t i; - - for (i = 0; i < qemuCaps->nmachineTypes; i++) { - if (STREQ(canonical_machine, qemuCaps->machineTypes[i].name)) - return true; - } - return false; -} - - /* * The preferred machine to use if none is listed explicitly * Note that this may differ from QEMU's own default machine diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index ee779d90ed..c0e1ce41e3 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -642,9 +642,6 @@ bool virQEMUCapsSupportsGICVersion(virQEMUCapsPtr qemuCaps, virDomainVirtType virtType, virGICVersion version); -bool virQEMUCapsIsMachineSupported(virQEMUCapsPtr qemuCaps, - const char *canonical_machine); - const char *virQEMUCapsGetPreferredMachine(virQEMUCapsPtr qemuCaps); int virQEMUCapsInitGuestFromBinary(virCapsPtr caps, -- 2.23.0 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list