|
|
0a7476 |
From 91b7c36af5d91f9ddfe47a3a2b1b35368ef171a4 Mon Sep 17 00:00:00 2001
|
|
|
0a7476 |
Message-Id: <91b7c36af5d91f9ddfe47a3a2b1b35368ef171a4@dist-git>
|
|
|
0a7476 |
From: Andrea Bolognani <abologna@redhat.com>
|
|
|
0a7476 |
Date: Fri, 5 Apr 2019 10:57:40 +0200
|
|
|
0a7476 |
Subject: [PATCH] qemu: Drop QEMU_CAPS_ENABLE_KVM
|
|
|
0a7476 |
|
|
|
0a7476 |
It was already available in 1.5.0.
|
|
|
0a7476 |
|
|
|
0a7476 |
Moreover, we're not even formatting it on the QEMU command
|
|
|
0a7476 |
line, ever: we just use it as part of some logic that decides
|
|
|
0a7476 |
whether KVM support should be advertised, and as it turns out
|
|
|
0a7476 |
that logic is actually buggy and dropping this capability
|
|
|
0a7476 |
fixes it.
|
|
|
0a7476 |
|
|
|
0a7476 |
https://bugzilla.redhat.com/show_bug.cgi?id=1628469
|
|
|
0a7476 |
|
|
|
0a7476 |
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
|
|
|
0a7476 |
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
|
|
|
0a7476 |
(cherry picked from commit 88983855d5496a74b97551860db737c2b17b100e)
|
|
|
0a7476 |
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
|
|
|
0a7476 |
Message-Id: <20190405085744.8179-4-abologna@redhat.com>
|
|
|
0a7476 |
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
|
|
|
0a7476 |
---
|
|
|
0a7476 |
src/qemu/qemu_capabilities.c | 3 ---
|
|
|
0a7476 |
src/qemu/qemu_capabilities.h | 2 +-
|
|
|
0a7476 |
tests/qemuxml2argvtest.c | 11 +++++------
|
|
|
0a7476 |
3 files changed, 6 insertions(+), 10 deletions(-)
|
|
|
0a7476 |
|
|
|
0a7476 |
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
|
|
|
0a7476 |
index 4f2051a2bb..c31c991a6f 100644
|
|
|
0a7476 |
--- a/src/qemu/qemu_capabilities.c
|
|
|
0a7476 |
+++ b/src/qemu/qemu_capabilities.c
|
|
|
0a7476 |
@@ -834,7 +834,6 @@ virQEMUCapsInitGuestFromBinary(virCapsPtr caps,
|
|
|
0a7476 |
|
|
|
0a7476 |
if (virFileExists("/dev/kvm") &&
|
|
|
0a7476 |
(virQEMUCapsGet(qemubinCaps, QEMU_CAPS_KVM) ||
|
|
|
0a7476 |
- virQEMUCapsGet(qemubinCaps, QEMU_CAPS_ENABLE_KVM) ||
|
|
|
0a7476 |
kvmbin))
|
|
|
0a7476 |
haskvm = true;
|
|
|
0a7476 |
|
|
|
0a7476 |
@@ -2604,7 +2603,6 @@ virQEMUCapsProbeQMPKVMState(virQEMUCapsPtr qemuCaps,
|
|
|
0a7476 |
virQEMUCapsClear(qemuCaps, QEMU_CAPS_KVM);
|
|
|
0a7476 |
} else if (!enabled) {
|
|
|
0a7476 |
virQEMUCapsClear(qemuCaps, QEMU_CAPS_KVM);
|
|
|
0a7476 |
- virQEMUCapsSet(qemuCaps, QEMU_CAPS_ENABLE_KVM);
|
|
|
0a7476 |
}
|
|
|
0a7476 |
|
|
|
0a7476 |
return 0;
|
|
|
0a7476 |
@@ -3912,7 +3910,6 @@ virQEMUCapsIsValid(void *data,
|
|
|
0a7476 |
priv->runUid, priv->runGid) == 0;
|
|
|
0a7476 |
|
|
|
0a7476 |
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_KVM) &&
|
|
|
0a7476 |
- virQEMUCapsGet(qemuCaps, QEMU_CAPS_ENABLE_KVM) &&
|
|
|
0a7476 |
kvmUsable) {
|
|
|
0a7476 |
VIR_DEBUG("KVM was not enabled when probing '%s', "
|
|
|
0a7476 |
"but it should be usable now",
|
|
|
0a7476 |
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
|
|
|
0a7476 |
index 9e8ad5f5c3..98668115d6 100644
|
|
|
0a7476 |
--- a/src/qemu/qemu_capabilities.h
|
|
|
0a7476 |
+++ b/src/qemu/qemu_capabilities.h
|
|
|
0a7476 |
@@ -79,7 +79,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */
|
|
|
0a7476 |
X_QEMU_CAPS_XEN_DOMID, /* -xen-domid */
|
|
|
0a7476 |
X_QEMU_CAPS_MIGRATE_QEMU_UNIX, /* qemu migration via unix sockets */
|
|
|
0a7476 |
X_QEMU_CAPS_CHARDEV, /* Is the new -chardev arg available */
|
|
|
0a7476 |
- QEMU_CAPS_ENABLE_KVM, /* -enable-kvm flag */
|
|
|
0a7476 |
+ X_QEMU_CAPS_ENABLE_KVM, /* -enable-kvm flag */
|
|
|
0a7476 |
X_QEMU_CAPS_MONITOR_JSON, /* JSON mode for monitor */
|
|
|
0a7476 |
|
|
|
0a7476 |
/* 25 */
|
|
|
0a7476 |
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
|
|
|
0a7476 |
index 7a731e2f40..f401076731 100644
|
|
|
0a7476 |
--- a/tests/qemuxml2argvtest.c
|
|
|
0a7476 |
+++ b/tests/qemuxml2argvtest.c
|
|
|
0a7476 |
@@ -912,16 +912,15 @@ mymain(void)
|
|
|
0a7476 |
DO_TEST("clock-france", NONE);
|
|
|
0a7476 |
DO_TEST("clock-hpet-off", NONE);
|
|
|
0a7476 |
DO_TEST("clock-catchup", QEMU_CAPS_KVM_PIT_TICK_POLICY);
|
|
|
0a7476 |
- DO_TEST("cpu-kvmclock", QEMU_CAPS_ENABLE_KVM);
|
|
|
0a7476 |
- DO_TEST("cpu-host-kvmclock", QEMU_CAPS_ENABLE_KVM);
|
|
|
0a7476 |
+ DO_TEST("cpu-kvmclock", NONE);
|
|
|
0a7476 |
+ DO_TEST("cpu-host-kvmclock", NONE);
|
|
|
0a7476 |
DO_TEST("kvmclock", QEMU_CAPS_KVM);
|
|
|
0a7476 |
DO_TEST("clock-timer-hyperv-rtc", QEMU_CAPS_KVM);
|
|
|
0a7476 |
|
|
|
0a7476 |
- DO_TEST("cpu-eoi-disabled", QEMU_CAPS_ENABLE_KVM);
|
|
|
0a7476 |
- DO_TEST("cpu-eoi-enabled", QEMU_CAPS_ENABLE_KVM);
|
|
|
0a7476 |
+ DO_TEST("cpu-eoi-disabled", NONE);
|
|
|
0a7476 |
+ DO_TEST("cpu-eoi-enabled", NONE);
|
|
|
0a7476 |
DO_TEST("controller-order",
|
|
|
0a7476 |
QEMU_CAPS_KVM,
|
|
|
0a7476 |
- QEMU_CAPS_ENABLE_KVM,
|
|
|
0a7476 |
QEMU_CAPS_PIIX3_USB_UHCI,
|
|
|
0a7476 |
QEMU_CAPS_CCID_PASSTHRU,
|
|
|
0a7476 |
QEMU_CAPS_SPICE,
|
|
|
0a7476 |
@@ -933,7 +932,7 @@ mymain(void)
|
|
|
0a7476 |
DO_TEST("eoi-enabled", NONE);
|
|
|
0a7476 |
DO_TEST("pv-spinlock-disabled", NONE);
|
|
|
0a7476 |
DO_TEST("pv-spinlock-enabled", NONE);
|
|
|
0a7476 |
- DO_TEST("kvmclock+eoi-disabled", QEMU_CAPS_ENABLE_KVM);
|
|
|
0a7476 |
+ DO_TEST("kvmclock+eoi-disabled", NONE);
|
|
|
0a7476 |
|
|
|
0a7476 |
DO_TEST("hyperv", NONE);
|
|
|
0a7476 |
DO_TEST("hyperv-off", NONE);
|
|
|
0a7476 |
--
|
|
|
0a7476 |
2.21.0
|
|
|
0a7476 |
|