mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
conf: add support for Hyper-V PV IPIs
Support Hyper-V PV IPI enlightenment in domain config. QEMU support will be implemented in the next patch, adding interim VIR_DOMAIN_HYPERV_IPI cases to src/qemu/* for now. Reviewed-by: Andrea Bolognani <abologna@redhat.com> Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
This commit is contained in:
parent
96f657e378
commit
988113f4fa
@ -2007,6 +2007,7 @@
|
||||
<frequencies state='on'/>
|
||||
<reenlightenment state='on'/>
|
||||
<tlbflush state='on'/>
|
||||
<ipi state='on'/>
|
||||
</hyperv>
|
||||
<kvm>
|
||||
<hidden state='on'/>
|
||||
@ -2147,6 +2148,12 @@
|
||||
<td>on, off</td>
|
||||
<td><span class="since">4.7.0 (QEMU 3.0)</span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>ipi</td>
|
||||
<td>Enable PV IPI support</td>
|
||||
<td>on, off</td>
|
||||
<td><span class="since">4.10.0 (QEMU 3.1)</span></td>
|
||||
</tr>
|
||||
</table>
|
||||
</dd>
|
||||
<dt><code>pvspinlock</code></dt>
|
||||
|
@ -5779,6 +5779,11 @@
|
||||
<ref name="featurestate"/>
|
||||
</element>
|
||||
</optional>
|
||||
<optional>
|
||||
<element name="ipi">
|
||||
<ref name="featurestate"/>
|
||||
</element>
|
||||
</optional>
|
||||
</interleave>
|
||||
</element>
|
||||
</define>
|
||||
|
@ -172,7 +172,9 @@ VIR_ENUM_IMPL(virDomainHyperv, VIR_DOMAIN_HYPERV_LAST,
|
||||
"vendor_id",
|
||||
"frequencies",
|
||||
"reenlightenment",
|
||||
"tlbflush")
|
||||
"tlbflush",
|
||||
"ipi",
|
||||
);
|
||||
|
||||
VIR_ENUM_IMPL(virDomainKVM, VIR_DOMAIN_KVM_LAST,
|
||||
"hidden")
|
||||
@ -20197,6 +20199,7 @@ virDomainDefParseXML(xmlDocPtr xml,
|
||||
case VIR_DOMAIN_HYPERV_FREQUENCIES:
|
||||
case VIR_DOMAIN_HYPERV_REENLIGHTENMENT:
|
||||
case VIR_DOMAIN_HYPERV_TLBFLUSH:
|
||||
case VIR_DOMAIN_HYPERV_IPI:
|
||||
break;
|
||||
|
||||
case VIR_DOMAIN_HYPERV_SPINLOCKS:
|
||||
@ -22391,6 +22394,7 @@ virDomainDefFeaturesCheckABIStability(virDomainDefPtr src,
|
||||
case VIR_DOMAIN_HYPERV_FREQUENCIES:
|
||||
case VIR_DOMAIN_HYPERV_REENLIGHTENMENT:
|
||||
case VIR_DOMAIN_HYPERV_TLBFLUSH:
|
||||
case VIR_DOMAIN_HYPERV_IPI:
|
||||
if (src->hyperv_features[i] != dst->hyperv_features[i]) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
|
||||
_("State of HyperV enlightenment "
|
||||
@ -28191,6 +28195,7 @@ virDomainDefFormatInternal(virDomainDefPtr def,
|
||||
case VIR_DOMAIN_HYPERV_FREQUENCIES:
|
||||
case VIR_DOMAIN_HYPERV_REENLIGHTENMENT:
|
||||
case VIR_DOMAIN_HYPERV_TLBFLUSH:
|
||||
case VIR_DOMAIN_HYPERV_IPI:
|
||||
break;
|
||||
|
||||
case VIR_DOMAIN_HYPERV_SPINLOCKS:
|
||||
|
@ -1795,6 +1795,7 @@ typedef enum {
|
||||
VIR_DOMAIN_HYPERV_FREQUENCIES,
|
||||
VIR_DOMAIN_HYPERV_REENLIGHTENMENT,
|
||||
VIR_DOMAIN_HYPERV_TLBFLUSH,
|
||||
VIR_DOMAIN_HYPERV_IPI,
|
||||
|
||||
VIR_DOMAIN_HYPERV_LAST
|
||||
} virDomainHyperv;
|
||||
|
@ -114,6 +114,8 @@ KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_REENLIGHTENMENT,
|
||||
0x40000003, 0x00002000);
|
||||
KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_TLBFLUSH,
|
||||
0x40000004, 0x00000004);
|
||||
KVM_FEATURE_DEF(VIR_CPU_x86_KVM_HV_IPI,
|
||||
0x40000004, 0x00000400);
|
||||
|
||||
static virCPUx86Feature x86_kvm_features[] =
|
||||
{
|
||||
@ -137,6 +139,7 @@ static virCPUx86Feature x86_kvm_features[] =
|
||||
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),
|
||||
};
|
||||
|
||||
typedef struct _virCPUx86Model virCPUx86Model;
|
||||
|
@ -65,6 +65,7 @@ struct _virCPUx86CPUID {
|
||||
# define VIR_CPU_x86_KVM_HV_FREQUENCIES "__kvm_hv_frequencies"
|
||||
# define VIR_CPU_x86_KVM_HV_REENLIGHTENMENT "__kvm_hv_reenlightenment"
|
||||
# define VIR_CPU_x86_KVM_HV_TLBFLUSH "__kvm_hv_tlbflush"
|
||||
# define VIR_CPU_x86_KVM_HV_IPI "__kvm_hv_ipi"
|
||||
|
||||
|
||||
# define VIR_CPU_X86_DATA_INIT { 0 }
|
||||
|
@ -6899,6 +6899,7 @@ qemuBuildCpuCommandLine(virCommandPtr cmd,
|
||||
def->hyperv_vendor_id);
|
||||
break;
|
||||
|
||||
case VIR_DOMAIN_HYPERV_IPI:
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
break;
|
||||
|
@ -1579,6 +1579,7 @@ qemuParseCommandLineCPU(virDomainDefPtr dom,
|
||||
|
||||
break;
|
||||
|
||||
case VIR_DOMAIN_HYPERV_IPI:
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
break;
|
||||
}
|
||||
|
@ -3969,6 +3969,7 @@ qemuProcessVerifyHypervFeatures(virDomainDefPtr def,
|
||||
virDomainHypervTypeToString(i));
|
||||
return -1;
|
||||
|
||||
case VIR_DOMAIN_HYPERV_IPI:
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_VENDOR_ID:
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
|
Loading…
x
Reference in New Issue
Block a user