]> xenbits.xensource.com Git - libvirt.git/commitdiff
qemu: remove deadcode in qemuDomain{HelperGetVcpus|GetIOThreadsLive}
authorLuyao Huang <lhuang@redhat.com>
Fri, 3 Jul 2015 01:57:53 +0000 (09:57 +0800)
committerMichal Privoznik <mprivozn@redhat.com>
Wed, 8 Jul 2015 08:23:37 +0000 (10:23 +0200)
We set @hostcpus variable but not use it.

Signed-off-by: Luyao Huang <lhuang@redhat.com>
src/qemu/qemu_driver.c

index 4cfae0392c04d8c0a97f0efac909e8797d7a2e1a..900740eb5b26228bbee36293123a46cfa7e8b9d9 100644 (file)
@@ -1418,13 +1418,9 @@ static int
 qemuDomainHelperGetVcpus(virDomainObjPtr vm, virVcpuInfoPtr info, int maxinfo,
                          unsigned char *cpumaps, int maplen)
 {
-    int hostcpus;
     size_t i, v;
     qemuDomainObjPrivatePtr priv = vm->privateData;
 
-    if ((hostcpus = nodeGetCPUCount()) < 0)
-        return -1;
-
     if (priv->vcpupids == NULL) {
         virReportError(VIR_ERR_OPERATION_INVALID,
                        "%s", _("cpu affinity is not supported"));
@@ -5579,7 +5575,6 @@ qemuDomainGetIOThreadsLive(virQEMUDriverPtr driver,
     qemuMonitorIOThreadInfoPtr *iothreads = NULL;
     virDomainIOThreadInfoPtr *info_ret = NULL;
     int niothreads = 0;
-    int hostcpus;
     size_t i;
     int ret = -1;
 
@@ -5612,9 +5607,6 @@ qemuDomainGetIOThreadsLive(virQEMUDriverPtr driver,
         goto endjob;
     }
 
-    if ((hostcpus = nodeGetCPUCount()) < 0)
-        goto endjob;
-
     if (VIR_ALLOC_N(info_ret, niothreads) < 0)
         goto endjob;