From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40762) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WwXvB-0001lx-Cc for qemu-devel@nongnu.org; Mon, 16 Jun 2014 10:30:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WwXv6-0000wt-44 for qemu-devel@nongnu.org; Mon, 16 Jun 2014 10:30:05 -0400 Received: from lputeaux-656-01-25-125.w80-12.abo.wanadoo.fr ([80.12.84.125]:51408 helo=paradis.irqsave.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WwXv5-0000wh-Pp for qemu-devel@nongnu.org; Mon, 16 Jun 2014 10:30:00 -0400 Date: Mon, 16 Jun 2014 16:29:58 +0200 From: =?iso-8859-1?Q?Beno=EEt?= Canet Message-ID: <20140616142958.GC12177@irqsave.net> References: <42edc288545832d77960d93fc4db86fefe6dfefe.1402683788.git.jcody@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <42edc288545832d77960d93fc4db86fefe6dfefe.1402683788.git.jcody@redhat.com> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v5 09/10] block: Add QMP documentation for block-stream List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jeff Cody Cc: kwolf@redhat.com, benoit.canet@irqsave.net, pkrempa@redhat.com, famz@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com The Friday 13 Jun 2014 =E0 14:52:37 (-0400), Jeff Cody wrote : > The QMP command 'block-stream' was missing QMP documentation. Add > that documentation. >=20 > Reviewed-by: Eric Blake > Signed-off-by: Jeff Cody > --- > qmp-commands.hx | 58 +++++++++++++++++++++++++++++++++++++++++++++++++= ++++++++ > 1 file changed, 58 insertions(+) >=20 > diff --git a/qmp-commands.hx b/qmp-commands.hx > index b41af0f..69d29ae 100644 > --- a/qmp-commands.hx > +++ b/qmp-commands.hx > @@ -983,6 +983,64 @@ EQMP > .mhandler.cmd_new =3D qmp_marshal_input_block_stream, > }, > =20 > +SQMP > +block-stream > +------------ > + > +Copy data from a backing file into a block device. > + > +The block streaming operation is performed in the background until the= entire > +backing file has been copied. This command returns immediately once s= treaming > +has started. The status of ongoing block streaming operations can be = checked > +with query-block-jobs. The operation can be stopped before it has com= pleted > +using the block-job-cancel command. > + > +If a base file is specified then sectors are not copied from that base= file and > +its backing chain. When streaming completes the image file will have = the base > +file as its backing file. This can be used to stream a subset of the = backing > +file chain instead of flattening the entire image. > + > +On successful completion the image file is updated to drop the backing= file > +and the BLOCK_JOB_COMPLETED event is emitted. > + > +- "device": The device name. > + (json-string) > + > +For base, either 'base' or 'base-node-name' may be set but not both. I= f > +neither is specified, the entire chain will be streamed into the activ= e image, > +and the chain will consist of a single image (the current active layer= ) with > +no backing file. > + > +- "base": The common backing file name. > + (json-string, optional) > + > +- "base-node-name": The block driver state node name of the common bac= king file. > + (json-string, optional) (Since 2.1) > + > +- "backing-file": The backing file string to write into the active l= ayer. > + This filename is not validated. > + > + If a pathname string is such that it cannot be res= olved by > + QEMU, that means that subsequent QMP or HMP comman= ds must > + use node-names for the image in question, as filen= ame > + lookup methods will fail. > + > + If not specified, QEMU will automatically determin= e the > + backing file string to use, or error out if there = is no > + obvious choice. Care should be taken when specify= ing the > + string, to specify a valid filename or protocol. > + (json-string, optional) > + (Since 2.1) > + > +- "speed": The maximum speed, in bytes per second. > + (json-int, optional) > + > +- "on-error": The action to take on an error (default report). > + 'stop' and 'enospc' can only be used if the block = device > + supports io-status (see BlockInfo). > + (json-enum, optional) (Since 1.3) > +EQMP > + > { > .name =3D "block-commit", > .args_type =3D "device:B,base:s?,base-node-name:s?,top:s?,top= -node-name:s?,backing-file:s?,speed:o?", > --=20 > 1.8.3.1 >=20 >=20 Reviewed-by: Benoit Canet