1 Star 0 Fork 71

jokenzhang/src-libvirt

forked from src-openEuler/libvirt 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
qemu_command-Don-t-validate-accelerator-when-buildin.patch 1.68 KB
一键复制 编辑 原始数据 按行查看 历史
yezengruan 提交于 2022-12-06 15:38 . libvirt update to version 6.2.0-47
From d048a83b990b08cc3709d6c4a505877533a4d189 Mon Sep 17 00:00:00 2001
From: Michal Privoznik <mprivozn@redhat.com>
Date: Fri, 5 Nov 2021 09:33:45 +0100
Subject: [PATCH 1/2] qemu_command: Don't validate accelerator when building
cmd line
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The domain accelerator was validated in qemuValidateDomainDef()
which calls virQEMUCapsIsVirtTypeSupported() which reports proper
error if QEMU is not capable of KVM/TCG. There is no point in
doing the validation again when building command line.
cherry-pick from 69f2f632994c8f8b51f0d0e4be0f674054619654
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Hyman Huang(黄勇) <huangy81@chinatelecom.cn>
Tested-by: Kashyap Chamarthy <kchamart@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
---
src/qemu/qemu_command.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 42f6e10b33..b009890e35 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -7084,15 +7084,8 @@ qemuBuildMachineCommandLine(virCommandPtr cmd,
case VIR_DOMAIN_VIRT_BHYVE:
case VIR_DOMAIN_VIRT_VZ:
case VIR_DOMAIN_VIRT_NONE:
- virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("the QEMU binary does not support %s"),
- virDomainVirtTypeToString(def->virtType));
- return -1;
-
case VIR_DOMAIN_VIRT_LAST:
- default:
- virReportEnumRangeError(virDomainVirtType, def->virtType);
- return -1;
+ break;
}
/* To avoid the collision of creating USB controllers when calling
--
2.27.0
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/omnihorizon/src-libvirt.git
git@gitee.com:omnihorizon/src-libvirt.git
omnihorizon
src-libvirt
src-libvirt
master

搜索帮助