]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemu: Remove qemuMonitorTextSetCPU
authorPeter Krempa <pkrempa@redhat.com>
Thu, 20 Jun 2019 11:15:04 +0000 (13:15 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Thu, 20 Jun 2019 13:59:19 +0000 (15:59 +0200)
It's not used any more.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/qemu/qemu_monitor_text.c
src/qemu/qemu_monitor_text.h

index 280cc5884022df470b6f54c20346a799a5d360fc..a15c3df76eed8895aae3859a1a498e9ec886423d 100644 (file)
 
 VIR_LOG_INIT("qemu.qemu_monitor_text");
 
-int qemuMonitorTextSetCPU(qemuMonitorPtr mon, int cpu, bool online)
-{
-    char *cmd;
-    char *reply = NULL;
-    int ret = -1;
-
-    if (virAsprintf(&cmd, "cpu_set %d %s", cpu, online ? "online" : "offline") < 0)
-        return -1;
-
-    if (qemuMonitorHMPCommand(mon, cmd, &reply) < 0)
-        goto cleanup;
-
-    /* If the command failed qemu prints: 'unknown command'
-     * No message is printed on success it seems */
-    if (strstr(reply, "unknown command:")) {
-        virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
-                       _("cannot change vcpu count of this domain"));
-        goto cleanup;
-    }
-
-    ret = 0;
-
- cleanup:
-    VIR_FREE(reply);
-    VIR_FREE(cmd);
-
-    return ret;
-}
-
-
 int qemuMonitorTextAddDrive(qemuMonitorPtr mon,
                             const char *drivestr)
 {
index 524bd1d5cb41b74f85f806101e0c52d3ef407b95..ce6dd979a53a9ef8c507f1ab70f8b716d05de334 100644 (file)
@@ -25,8 +25,6 @@
 
 #include "qemu_monitor.h"
 
-int qemuMonitorTextSetCPU(qemuMonitorPtr mon, int cpu, bool online);
-
 int qemuMonitorTextAddDrive(qemuMonitorPtr mon,
                              const char *drivestr);