From 0fc9f8ea2800b76eaea20a8a3a91fbeeb4bfa81b Mon Sep 17 00:00:00 2001 From: Fam Zheng Date: Mon, 8 Jun 2015 13:56:08 +0800 Subject: qmp: Add optional bool "unmap" to drive-mirror If specified as "true", it allows discarding on target sectors where source is not allocated. Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- qmp-commands.hx | 3 +++ 1 file changed, 3 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 87fa1722fb..e1bcc60380 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1503,6 +1503,7 @@ EQMP .args_type = "sync:s,device:B,target:s,speed:i?,mode:s?,format:s?," "node-name:s?,replaces:s?," "on-source-error:s?,on-target-error:s?," + "unmap:b?," "granularity:i?,buf-size:i?", .mhandler.cmd_new = qmp_marshal_input_drive_mirror, }, @@ -1542,6 +1543,8 @@ Arguments: (BlockdevOnError, default 'report') - "on-target-error": the action to take on an error on the target (BlockdevOnError, default 'report') +- "unmap": whether the target sectors should be discarded where source has only + zeroes. (json-bool, optional, default true) The default value of the granularity is the image cluster size clamped between 4096 and 65536, if the image format defines one. If the format -- cgit v1.2.3