qmp: add block_job_cancel command

Add block_job_cancel, which stops an active block streaming operation.
When the operation has been cancelled the new BLOCK_JOB_CANCELLED event
is emitted.

Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Acked-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
Stefan Hajnoczi 2012-01-18 14:40:48 +00:00 committed by Kevin Wolf
parent 2d47c6e9aa
commit 370521a1d6
10 changed files with 107 additions and 1 deletions

View file

@ -660,6 +660,12 @@ EQMP
.mhandler.cmd_new = qmp_marshal_input_block_job_set_speed,
},
{
.name = "block_job_cancel",
.args_type = "device:B",
.mhandler.cmd_new = qmp_marshal_input_block_job_cancel,
},
{
.name = "blockdev-snapshot-sync",
.args_type = "device:B,snapshot-file:s,format:s?",