|
|
404507 |
From 9daae960fbe9902f9db5ebc76ded1f197bb3e6ae Mon Sep 17 00:00:00 2001
|
|
|
404507 |
Message-Id: <9daae960fbe9902f9db5ebc76ded1f197bb3e6ae@dist-git>
|
|
|
404507 |
From: Peter Krempa <pkrempa@redhat.com>
|
|
|
404507 |
Date: Wed, 7 Feb 2018 14:16:00 +0100
|
|
|
404507 |
Subject: [PATCH] qemu: Remove unused 'cpuhalted' argument from
|
|
|
404507 |
qemuDomainHelperGetVcpus
|
|
|
404507 |
|
|
|
404507 |
The halted state is no longer extracted using this helper so the
|
|
|
404507 |
argument can be removed.
|
|
|
404507 |
|
|
|
404507 |
(cherry picked from commit 2222548b1e55257dc8806abdbefa71a87b22dea1)
|
|
|
404507 |
|
|
|
404507 |
https://bugzilla.redhat.com/show_bug.cgi?id=1534585
|
|
|
404507 |
---
|
|
|
404507 |
src/qemu/qemu_driver.c | 14 +++-----------
|
|
|
404507 |
1 file changed, 3 insertions(+), 11 deletions(-)
|
|
|
404507 |
|
|
|
404507 |
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
|
|
|
404507 |
index bfb3c3c4c5..b5bef7442e 100644
|
|
|
404507 |
--- a/src/qemu/qemu_driver.c
|
|
|
404507 |
+++ b/src/qemu/qemu_driver.c
|
|
|
404507 |
@@ -1490,8 +1490,7 @@ qemuDomainHelperGetVcpus(virDomainObjPtr vm,
|
|
|
404507 |
unsigned long long *cpuwait,
|
|
|
404507 |
int maxinfo,
|
|
|
404507 |
unsigned char *cpumaps,
|
|
|
404507 |
- int maplen,
|
|
|
404507 |
- bool *cpuhalted)
|
|
|
404507 |
+ int maplen)
|
|
|
404507 |
{
|
|
|
404507 |
size_t ncpuinfo = 0;
|
|
|
404507 |
size_t i;
|
|
|
404507 |
@@ -1511,9 +1510,6 @@ qemuDomainHelperGetVcpus(virDomainObjPtr vm,
|
|
|
404507 |
if (cpumaps)
|
|
|
404507 |
memset(cpumaps, 0, sizeof(*cpumaps) * maxinfo);
|
|
|
404507 |
|
|
|
404507 |
- if (cpuhalted)
|
|
|
404507 |
- memset(cpuhalted, 0, sizeof(*cpuhalted) * maxinfo);
|
|
|
404507 |
-
|
|
|
404507 |
for (i = 0; i < virDomainDefGetVcpusMax(vm->def) && ncpuinfo < maxinfo; i++) {
|
|
|
404507 |
virDomainVcpuDefPtr vcpu = virDomainDefGetVcpu(vm->def, i);
|
|
|
404507 |
pid_t vcpupid = qemuDomainGetVcpuPid(vm, i);
|
|
|
404507 |
@@ -1551,9 +1547,6 @@ qemuDomainHelperGetVcpus(virDomainObjPtr vm,
|
|
|
404507 |
return -1;
|
|
|
404507 |
}
|
|
|
404507 |
|
|
|
404507 |
- if (cpuhalted)
|
|
|
404507 |
- cpuhalted[ncpuinfo] = qemuDomainGetVcpuHalted(vm, ncpuinfo);
|
|
|
404507 |
-
|
|
|
404507 |
ncpuinfo++;
|
|
|
404507 |
}
|
|
|
404507 |
|
|
|
404507 |
@@ -5411,8 +5404,7 @@ qemuDomainGetVcpus(virDomainPtr dom,
|
|
|
404507 |
goto cleanup;
|
|
|
404507 |
}
|
|
|
404507 |
|
|
|
404507 |
- ret = qemuDomainHelperGetVcpus(vm, info, NULL, maxinfo, cpumaps, maplen,
|
|
|
404507 |
- NULL);
|
|
|
404507 |
+ ret = qemuDomainHelperGetVcpus(vm, info, NULL, maxinfo, cpumaps, maplen);
|
|
|
404507 |
|
|
|
404507 |
cleanup:
|
|
|
404507 |
virDomainObjEndAPI(&vm;;
|
|
|
404507 |
@@ -19567,7 +19559,7 @@ qemuDomainGetStatsVcpu(virQEMUDriverPtr driver,
|
|
|
404507 |
|
|
|
404507 |
if (qemuDomainHelperGetVcpus(dom, cpuinfo, cpuwait,
|
|
|
404507 |
virDomainDefGetVcpus(dom->def),
|
|
|
404507 |
- NULL, 0, NULL) < 0) {
|
|
|
404507 |
+ NULL, 0) < 0) {
|
|
|
404507 |
virResetLastError();
|
|
|
404507 |
ret = 0; /* it's ok to be silent and go ahead */
|
|
|
404507 |
goto cleanup;
|
|
|
404507 |
--
|
|
|
404507 |
2.16.1
|
|
|
404507 |
|