From 9254893882139b9a7738214d669958df4dfeee2f Mon Sep 17 00:00:00 2001 From: Dominik Csapak Date: Wed, 5 Dec 2018 12:01:31 +0100 Subject: qmp: Split ShutdownCause host-qmp into quit and system-reset It is interesting to know whether the shutdown cause was 'quit' or 'reset', especially when using "--no-reboot". In that case, a management layer can now determine if the guest wanted a reboot or shutdown, and can act accordingly. Changes the output of the reason in the iotests from 'host-qmp' to 'host-qmp-quit'. This does not break compatibility because the field was introduced in the same version. Signed-off-by: Dominik Csapak Message-Id: <20181205110131.23049-4-d.csapak@proxmox.com> Reviewed-by: Markus Armbruster [Commit message tweaked] Signed-off-by: Markus Armbruster --- qapi/run-state.json | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'qapi/run-state.json') diff --git a/qapi/run-state.json b/qapi/run-state.json index 436ba4e14e..d7477cd715 100644 --- a/qapi/run-state.json +++ b/qapi/run-state.json @@ -68,7 +68,9 @@ # # @host-error: An error prevents further use of guest # -# @host-qmp: Reaction to a QMP command, like 'quit' +# @host-qmp-quit: Reaction to the QMP command 'quit' +# +# @host-qmp-system-reset: Reaction to the QMP command 'system_reset' # # @host-signal: Reaction to a signal, such as SIGINT # @@ -89,9 +91,9 @@ ## { 'enum': 'ShutdownCause', # Beware, shutdown_caused_by_guest() depends on enumeration order - 'data': [ 'none', 'host-error', 'host-qmp', 'host-signal', 'host-ui', - 'guest-shutdown', 'guest-reset', 'guest-panic', - 'subsystem-reset'] } + 'data': [ 'none', 'host-error', 'host-qmp-quit', 'host-qmp-system-reset', + 'host-signal', 'host-ui', 'guest-shutdown', 'guest-reset', + 'guest-panic', 'subsystem-reset'] } ## # @StatusInfo: -- cgit v1.2.3