diff mbox series

[25/29] vl: start VM via qmp_cont

Message ID 20201027182144.3315885-26-pbonzini@redhat.com
State Accepted
Commit ee55686efbd7de8dce8c1437c6e38fb4f5398c24
Headers show
Series cleanup qemu_init and make sense of command line processing | expand

Commit Message

Paolo Bonzini Oct. 27, 2020, 6:21 p.m. UTC
Complement the previous patch by starting the VM with a QMP command.
Later, the user will be able to do the same, invoking two
commands "finish-machine-init" and "cont" instead of
"x-exit-preconfig".

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 softmmu/vl.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Igor Mammedov Nov. 20, 2020, 4:08 p.m. UTC | #1
On Tue, 27 Oct 2020 14:21:40 -0400
Paolo Bonzini <pbonzini@redhat.com> wrote:

> Complement the previous patch by starting the VM with a QMP command.

> Later, the user will be able to do the same, invoking two

> commands "finish-machine-init" and "cont" instead of

> "x-exit-preconfig".

> 

> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


Reviewed-by: Igor Mammedov <imammedo@redhat.com>


> ---

>  softmmu/vl.c | 3 ++-

>  1 file changed, 2 insertions(+), 1 deletion(-)

> 

> diff --git a/softmmu/vl.c b/softmmu/vl.c

> index 583366510b..edabd17dac 100644

> --- a/softmmu/vl.c

> +++ b/softmmu/vl.c

> @@ -110,6 +110,7 @@

>  #include "qapi/qapi-visit-ui.h"

>  #include "qapi/qapi-commands-block-core.h"

>  #include "qapi/qapi-commands-migration.h"

> +#include "qapi/qapi-commands-misc.h"

>  #include "qapi/qapi-commands-run-state.h"

>  #include "qapi/qapi-commands-ui.h"

>  #include "qapi/qmp/qerror.h"

> @@ -4566,7 +4567,7 @@ void qemu_init(int argc, char **argv, char **envp)

>              }

>          }

>      } else if (autostart) {

> -        vm_start();

> +        qmp_cont(NULL);

>      }

>  

>      accel_setup_post(current_machine);
diff mbox series

Patch

diff --git a/softmmu/vl.c b/softmmu/vl.c
index 583366510b..edabd17dac 100644
--- a/softmmu/vl.c
+++ b/softmmu/vl.c
@@ -110,6 +110,7 @@ 
 #include "qapi/qapi-visit-ui.h"
 #include "qapi/qapi-commands-block-core.h"
 #include "qapi/qapi-commands-migration.h"
+#include "qapi/qapi-commands-misc.h"
 #include "qapi/qapi-commands-run-state.h"
 #include "qapi/qapi-commands-ui.h"
 #include "qapi/qmp/qerror.h"
@@ -4566,7 +4567,7 @@  void qemu_init(int argc, char **argv, char **envp)
             }
         }
     } else if (autostart) {
-        vm_start();
+        qmp_cont(NULL);
     }
 
     accel_setup_post(current_machine);