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 <d.csapak@proxmox.com>
Message-Id: <20181205110131.23049-4-d.csapak@proxmox.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
[Commit message tweaked]
Signed-off-by: Markus Armbruster <armbru@redhat.com>
This commit is contained in:
Dominik Csapak 2018-12-05 12:01:31 +01:00 committed by Markus Armbruster
parent ecd7a0d5bb
commit 9254893882
23 changed files with 83 additions and 81 deletions

View file

@ -54,7 +54,7 @@ Testing: -drive driver=null-co,if=virtio
"event": "SHUTDOWN",
"data": {
"guest": false,
"reason": "host-qmp"
"reason": "host-qmp-quit"
}
}
@ -112,7 +112,7 @@ Testing: -drive driver=null-co,if=none
"event": "SHUTDOWN",
"data": {
"guest": false,
"reason": "host-qmp"
"reason": "host-qmp-quit"
}
}
@ -143,7 +143,7 @@ Testing: -blockdev driver=null-co,node-name=null
"event": "SHUTDOWN",
"data": {
"guest": false,
"reason": "host-qmp"
"reason": "host-qmp-quit"
}
}
@ -202,7 +202,7 @@ Testing: -blockdev driver=null-co,node-name=null -device virtio-blk,drive=null,i
"event": "SHUTDOWN",
"data": {
"guest": false,
"reason": "host-qmp"
"reason": "host-qmp-quit"
}
}