]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
cpu: Drop KVM_ from hyperv feature macros
authorJiri Denemark <jdenemar@redhat.com>
Thu, 25 Jul 2019 15:07:18 +0000 (17:07 +0200)
committerJiri Denemark <jdenemar@redhat.com>
Mon, 29 Jul 2019 13:41:50 +0000 (15:41 +0200)
All the features are hyperv features even though they are provided by
KVM with QEMU. The "KVM" part in the macro names does not make a lot of
sense.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Tested-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/cpu/cpu_x86.c
src/cpu/cpu_x86_data.h
src/qemu/qemu_command.c

index 55b55da784036c32d4438a76c7bdc93da645a043..f8a51dedf64bbb99d7ac3f15a922b560cc49eeb5 100644 (file)
@@ -91,31 +91,32 @@ KVM_FEATURE_DEF(VIR_CPU_x86_KVM_PV_UNHALT,
                 0x40000001, 0x00000080);
 KVM_FEATURE_DEF(VIR_CPU_x86_KVM_CLOCKSOURCE_STABLE_BIT,
                 0x40000001, 0x01000000);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_RUNTIME,
+
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_RUNTIME,
                 0x40000003, 0x00000001);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_SYNIC,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_SYNIC,
                 0x40000003, 0x00000004);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_STIMER,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_STIMER,
                 0x40000003, 0x00000008);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_RELAXED,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_RELAXED,
                 0x40000003, 0x00000020);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_SPINLOCKS,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_SPINLOCKS,
                 0x40000003, 0x00000022);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_VAPIC,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_VAPIC,
                 0x40000003, 0x00000030);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_VPINDEX,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_VPINDEX,
                 0x40000003, 0x00000040);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_RESET,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_RESET,
                 0x40000003, 0x00000080);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_FREQUENCIES,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_FREQUENCIES,
                 0x40000003, 0x00000800);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_REENLIGHTENMENT,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_REENLIGHTENMENT,
                 0x40000003, 0x00002000);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_TLBFLUSH,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_TLBFLUSH,
                 0x40000004, 0x00000004);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_IPI,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_IPI,
                 0x40000004, 0x00000400);
-KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_EVMCS,
+KVM_FEATURE_DEF(VIR_CPU_x86_HV_EVMCS,
                 0x40000004, 0x00004000);
 
 static virCPUx86Feature x86_kvm_features[] =
@@ -129,19 +130,19 @@ static virCPUx86Feature x86_kvm_features[] =
     KVM_FEATURE(VIR_CPU_x86_KVM_PV_EOI),
     KVM_FEATURE(VIR_CPU_x86_KVM_PV_UNHALT),
     KVM_FEATURE(VIR_CPU_x86_KVM_CLOCKSOURCE_STABLE_BIT),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_RUNTIME),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_SYNIC),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_STIMER),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_RELAXED),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_SPINLOCKS),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_VAPIC),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_VPINDEX),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_RESET),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_FREQUENCIES),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_REENLIGHTENMENT),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_TLBFLUSH),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_IPI),
-    KVM_FEATURE(VIR_CPU_x86_KVM_HV_EVMCS),
+    KVM_FEATURE(VIR_CPU_x86_HV_RUNTIME),
+    KVM_FEATURE(VIR_CPU_x86_HV_SYNIC),
+    KVM_FEATURE(VIR_CPU_x86_HV_STIMER),
+    KVM_FEATURE(VIR_CPU_x86_HV_RELAXED),
+    KVM_FEATURE(VIR_CPU_x86_HV_SPINLOCKS),
+    KVM_FEATURE(VIR_CPU_x86_HV_VAPIC),
+    KVM_FEATURE(VIR_CPU_x86_HV_VPINDEX),
+    KVM_FEATURE(VIR_CPU_x86_HV_RESET),
+    KVM_FEATURE(VIR_CPU_x86_HV_FREQUENCIES),
+    KVM_FEATURE(VIR_CPU_x86_HV_REENLIGHTENMENT),
+    KVM_FEATURE(VIR_CPU_x86_HV_TLBFLUSH),
+    KVM_FEATURE(VIR_CPU_x86_HV_IPI),
+    KVM_FEATURE(VIR_CPU_x86_HV_EVMCS),
 };
 
 typedef struct _virCPUx86Model virCPUx86Model;
index bb781707aad71f1fc7873be3f670f9d3f3378643..85aaab709c564858df2681e1b866af74c9b10c40 100644 (file)
@@ -58,19 +58,19 @@ struct _virCPUx86MSR {
  * ones defined for virDomainHyperv in domain_conf.c.
  * E.g "hv-runtime" -> "runtime", "hv-spinlocks" -> "spinlocks" etc.
 */
-#define VIR_CPU_x86_KVM_HV_RUNTIME   "hv-runtime"
-#define VIR_CPU_x86_KVM_HV_SYNIC     "hv-synic"
-#define VIR_CPU_x86_KVM_HV_STIMER    "hv-stimer"
-#define VIR_CPU_x86_KVM_HV_RELAXED   "hv-relaxed"
-#define VIR_CPU_x86_KVM_HV_SPINLOCKS "hv-spinlocks"
-#define VIR_CPU_x86_KVM_HV_VAPIC     "hv-vapic"
-#define VIR_CPU_x86_KVM_HV_VPINDEX   "hv-vpindex"
-#define VIR_CPU_x86_KVM_HV_RESET     "hv-reset"
-#define VIR_CPU_x86_KVM_HV_FREQUENCIES "hv-frequencies"
-#define VIR_CPU_x86_KVM_HV_REENLIGHTENMENT "hv-reenlightenment"
-#define VIR_CPU_x86_KVM_HV_TLBFLUSH  "hv-tlbflush"
-#define VIR_CPU_x86_KVM_HV_IPI       "hv-ipi"
-#define VIR_CPU_x86_KVM_HV_EVMCS     "hv-evmcs"
+#define VIR_CPU_x86_HV_RUNTIME   "hv-runtime"
+#define VIR_CPU_x86_HV_SYNIC     "hv-synic"
+#define VIR_CPU_x86_HV_STIMER    "hv-stimer"
+#define VIR_CPU_x86_HV_RELAXED   "hv-relaxed"
+#define VIR_CPU_x86_HV_SPINLOCKS "hv-spinlocks"
+#define VIR_CPU_x86_HV_VAPIC     "hv-vapic"
+#define VIR_CPU_x86_HV_VPINDEX   "hv-vpindex"
+#define VIR_CPU_x86_HV_RESET     "hv-reset"
+#define VIR_CPU_x86_HV_FREQUENCIES "hv-frequencies"
+#define VIR_CPU_x86_HV_REENLIGHTENMENT "hv-reenlightenment"
+#define VIR_CPU_x86_HV_TLBFLUSH  "hv-tlbflush"
+#define VIR_CPU_x86_HV_IPI       "hv-ipi"
+#define VIR_CPU_x86_HV_EVMCS     "hv-evmcs"
 
 
 #define VIR_CPU_X86_DATA_INIT { 0 }
index c2f99034c8e348a2f4da69e07699ee3f0a57fb23..7b2cfa06831d57e3e2e4acc7c69eb681388202b8 100644 (file)
@@ -7179,7 +7179,7 @@ qemuBuildCpuCommandLine(virCommandPtr cmd,
             case VIR_DOMAIN_HYPERV_SPINLOCKS:
                 if (def->hyperv_features[i] == VIR_TRISTATE_SWITCH_ON)
                     virBufferAsprintf(&buf, ",%s=0x%x",
-                                      VIR_CPU_x86_KVM_HV_SPINLOCKS,
+                                      VIR_CPU_x86_HV_SPINLOCKS,
                                       def->hyperv_spinlocks);
                 break;