[PATCH 10/11] qemuBuildCommandLine: Don't avoid '-S' flag for 'domxml-to-native' conversion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The commandline generated from our XML->native convertor is the majority
of cases not usable without libvirt anyways and the situation will not
improve any more.

As of such there's no much utility of avoiding the use of stopped CPUs
flag in such case.

Remove the QEMU_BUILD_COMMAND_LINE_CPUS_RUNNING flag and the associated
logic.

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 src/qemu/qemu_command.c | 3 +--
 src/qemu/qemu_command.h | 4 ----
 src/qemu/qemu_driver.c  | 3 +--
 3 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 8705f0018c..25b8dcb10a 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -10436,8 +10436,7 @@ qemuBuildCommandLine(virDomainObj *vm,

     qemuBuildCompatDeprecatedCommandLine(cmd, cfg, def, qemuCaps);

-    if (!(flags & QEMU_BUILD_COMMAND_LINE_CPUS_RUNNING))
-        virCommandAddArg(cmd, "-S"); /* freeze CPU */
+    virCommandAddArg(cmd, "-S"); /* freeze CPUs during startup */

     if (qemuBuildMasterKeyCommandLine(cmd, priv) < 0)
         return NULL;
diff --git a/src/qemu/qemu_command.h b/src/qemu/qemu_command.h
index 72b0401c7b..087ab52ee5 100644
--- a/src/qemu/qemu_command.h
+++ b/src/qemu/qemu_command.h
@@ -43,10 +43,6 @@
 VIR_ENUM_DECL(qemuVideo);
 VIR_ENUM_DECL(qemuSoundCodec);

-typedef enum {
-    QEMU_BUILD_COMMAND_LINE_CPUS_RUNNING = 1 << 0,
-} qemuBuildCommandLineFlags;
-
 virCommand *qemuBuildCommandLine(virDomainObj *vm,
                                  const char *migrateURI,
                                  virDomainMomentObj *snapshot,
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index 2ca264d9f9..5f4990b09c 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -6339,7 +6339,6 @@ static char *qemuConnectDomainXMLToNative(virConnectPtr conn,
     virQEMUDriver *driver = conn->privateData;
     g_autoptr(virDomainObj) vm = NULL;
     g_autoptr(virCommand) cmd = NULL;
-    unsigned int commandlineflags = QEMU_BUILD_COMMAND_LINE_CPUS_RUNNING;
     size_t i;

     virCheckFlags(0, NULL);
@@ -6391,7 +6390,7 @@ static char *qemuConnectDomainXMLToNative(virConnectPtr conn,
     if (qemuConnectDomainXMLToNativePrepareHost(vm) < 0)
         return NULL;

-    if (!(cmd = qemuProcessCreatePretendCmdBuild(vm, NULL, commandlineflags)))
+    if (!(cmd = qemuProcessCreatePretendCmdBuild(vm, NULL, 0)))
         return NULL;

     return virCommandToString(cmd, false);
-- 
2.35.3




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux