[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 18/43] qapi event: convert STOP
From: |
Luiz Capitulino |
Subject: |
[Qemu-devel] [PULL 18/43] qapi event: convert STOP |
Date: |
Mon, 23 Jun 2014 12:36:18 -0400 |
From: Wenchao Xia <address@hidden>
Signed-off-by: Wenchao Xia <address@hidden>
Signed-off-by: Paolo Bonzini <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Signed-off-by: Luiz Capitulino <address@hidden>
---
cpus.c | 4 +++-
docs/qmp/qmp-events.txt | 12 ------------
qapi-event.json | 9 +++++++++
3 files changed, 12 insertions(+), 13 deletions(-)
diff --git a/cpus.c b/cpus.c
index 06da4e7..5e7f2cf 100644
--- a/cpus.c
+++ b/cpus.c
@@ -26,6 +26,7 @@
#include "config-host.h"
#include "monitor/monitor.h"
+#include "qapi/qmp/qerror.h"
#include "sysemu/sysemu.h"
#include "exec/gdbstub.h"
#include "sysemu/dma.h"
@@ -38,6 +39,7 @@
#include "qemu/main-loop.h"
#include "qemu/bitmap.h"
#include "qemu/seqlock.h"
+#include "qapi-event.h"
#ifndef _WIN32
#include "qemu/compatfd.h"
@@ -530,7 +532,7 @@ static int do_vm_stop(RunState state)
pause_all_vcpus();
runstate_set(state);
vm_state_notify(0, state);
- monitor_protocol_event(QEVENT_STOP, NULL);
+ qapi_event_send_stop(&error_abort);
}
bdrv_drain_all();
diff --git a/docs/qmp/qmp-events.txt b/docs/qmp/qmp-events.txt
index c50b18f..cb32530 100644
--- a/docs/qmp/qmp-events.txt
+++ b/docs/qmp/qmp-events.txt
@@ -364,18 +364,6 @@ Example:
"channel-id": 0, "tls": true}
}}
-STOP
-----
-
-Emitted when the Virtual Machine is stopped.
-
-Data: None.
-
-Example:
-
-{ "event": "STOP",
- "timestamp": { "seconds": 1267041730, "microseconds": 281295 } }
-
SUSPEND
-------
diff --git a/qapi-event.json b/qapi-event.json
index f38669d..bac7fdc 100644
--- a/qapi-event.json
+++ b/qapi-event.json
@@ -29,3 +29,12 @@
# Since: 0.12.0
##
{ 'event': 'RESET' }
+
+##
+# @STOP
+#
+# Emitted when the virtual machine is stopped
+#
+# Since: 0.12.0
+##
+{ 'event': 'STOP' }
--
1.9.3
- [Qemu-devel] [PULL 06/43] json-lexer: fix escaped backslash in single-quoted string, (continued)
- [Qemu-devel] [PULL 06/43] json-lexer: fix escaped backslash in single-quoted string, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 03/43] qapi: fix coding style in parameters list, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 07/43] os-posix: include sys/time.h, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 08/43] qapi: Add includes from qapi/ as dependencies, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 12/43] qapi: adjust existing defines, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 13/43] monitor: add an implemention of qapi event emit method, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 14/43] qapi: add new schema file qapi-event.json, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 20/43] qapi event: convert SUSPEND, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 11/43] test: add test cases for qapi event, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 17/43] qapi event: convert RESET, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 18/43] qapi event: convert STOP,
Luiz Capitulino <=
- [Qemu-devel] [PULL 22/43] qapi event: convert WAKEUP, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 23/43] qapi event: convert RTC_CHANGE, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 15/43] qapi event: convert SHUTDOWN, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 27/43] qapi event: convert BLOCK_IO_ERROR and BLOCK_JOB_ERROR, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 26/43] qapi event: convert DEVICE_TRAY_MOVED, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 32/43] qapi event: convert SPICE events, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 28/43] qapi event: convert BLOCK_IMAGE_CORRUPTED, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 30/43] qapi event: convert NIC_RX_FILTER_CHANGED, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 31/43] qapi event: convert VNC events, Luiz Capitulino, 2014/06/23
- [Qemu-devel] [PULL 33/43] qmp: convert ACPI_DEVICE_OST event, Luiz Capitulino, 2014/06/23