Message ID | 1401970944-18735-14-git-send-email-wenchaoqemu@gmail.com |
---|---|
State | New |
Headers | show |
On 06/05/2014 06:22 AM, Wenchao Xia wrote: > Signed-off-by: Wenchao Xia <wenchaoqemu@gmail.com> > --- > docs/qmp/qmp-events.txt | 12 ------------ > qapi-event.json | 10 ++++++++++ > vl.c | 2 +- > 3 files changed, 11 insertions(+), 13 deletions(-) > > +## > +# @SUSPEND > +# > +# Emitted when guest enters a hardware suspension state, for example, S3 state, > +# which is sometimes called standby state > +# > +# Since: 2.1 1.1
diff --git a/docs/qmp/qmp-events.txt b/docs/qmp/qmp-events.txt index cda67d4..d86a077 100644 --- a/docs/qmp/qmp-events.txt +++ b/docs/qmp/qmp-events.txt @@ -342,18 +342,6 @@ Example: "channel-id": 0, "tls": true} }} -SUSPEND -------- - -Emitted when guest enters S3 state. - -Data: None. - -Example: - -{ "event": "SUSPEND", - "timestamp": { "seconds": 1344456160, "microseconds": 309119 } } - SUSPEND_DISK ------------ diff --git a/qapi-event.json b/qapi-event.json index 3485985..83c4ea2 100644 --- a/qapi-event.json +++ b/qapi-event.json @@ -47,3 +47,13 @@ # Since: 2.1 ## { 'event': 'RESUME' } + +## +# @SUSPEND +# +# Emitted when guest enters a hardware suspension state, for example, S3 state, +# which is sometimes called standby state +# +# Since: 2.1 +## +{ 'event': 'SUSPEND' } diff --git a/vl.c b/vl.c index d195e50..c6cb2c1 100644 --- a/vl.c +++ b/vl.c @@ -1928,7 +1928,7 @@ static void qemu_system_suspend(void) pause_all_vcpus(); notifier_list_notify(&suspend_notifiers, NULL); runstate_set(RUN_STATE_SUSPENDED); - monitor_protocol_event(QEVENT_SUSPEND, NULL); + qapi_event_send_suspend(NULL); } void qemu_system_suspend_request(void)
Signed-off-by: Wenchao Xia <wenchaoqemu@gmail.com> --- docs/qmp/qmp-events.txt | 12 ------------ qapi-event.json | 10 ++++++++++ vl.c | 2 +- 3 files changed, 11 insertions(+), 13 deletions(-)