提交 fc660ae3 编写于 作者: A Andrea Bolognani

qemu: Add validation for SMMUv3 IOMMU

Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
Reviewed-by: NJán Tomko <jtomko@redhat.com>
上级 60f4c413
...@@ -6136,6 +6136,20 @@ qemuDomainDeviceDefValidateIOMMU(const virDomainIOMMUDef *iommu, ...@@ -6136,6 +6136,20 @@ qemuDomainDeviceDefValidateIOMMU(const virDomainIOMMUDef *iommu,
break; break;
case VIR_DOMAIN_IOMMU_MODEL_SMMUV3: case VIR_DOMAIN_IOMMU_MODEL_SMMUV3:
if (!qemuDomainIsARMVirt(def)) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("IOMMU device: '%s' is only supported with "
"ARM Virt machines"),
virDomainIOMMUModelTypeToString(iommu->model));
return -1;
}
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_MACHINE_VIRT_IOMMU)) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("IOMMU device: '%s' is not supported with "
"this QEMU binary"),
virDomainIOMMUModelTypeToString(iommu->model));
return -1;
}
break; break;
case VIR_DOMAIN_IOMMU_MODEL_LAST: case VIR_DOMAIN_IOMMU_MODEL_LAST:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册