From 6e37fb811ac86739e5ed30dba3a8e4848bd21b56 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 28 Sep 2012 17:22:51 +0200 Subject: qmp: add block-job-pause and block-job-resume Add QMP commands matching the functionality. Paused jobs cannot be canceled without first resuming them. This ensures that I/O errors are never missed by management. However, an optional force argument can be specified to allow that. Signed-off-by: Paolo Bonzini Reviewed-by: Eric Blake Signed-off-by: Kevin Wolf --- qmp-commands.hx | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index a55a3f54b..71d7c25f5 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -805,9 +805,19 @@ EQMP { .name = "block-job-cancel", - .args_type = "device:B", + .args_type = "device:B,force:b?", .mhandler.cmd_new = qmp_marshal_input_block_job_cancel, }, + { + .name = "block-job-pause", + .args_type = "device:B", + .mhandler.cmd_new = qmp_marshal_input_block_job_pause, + }, + { + .name = "block-job-resume", + .args_type = "device:B", + .mhandler.cmd_new = qmp_marshal_input_block_job_resume, + }, { .name = "transaction", .args_type = "actions:q", -- cgit v1.2.3