Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Kevin Wolf
Am 13.03.2012 21:48, schrieb Eric Blake: On 03/06/2012 10:56 AM, Paolo Bonzini wrote: From: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com ## +# @drive-reopen +# +# Assigns a new image file

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Paolo Bonzini
Il 14/03/2012 10:17, Kevin Wolf ha scritto: If we want to do this, it needs to be the same patch, as we couple the transaction actions with top-level commands as long as there is no other way to discover the possible actions. And it probably makes more sense anyway, because the top-level

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Kevin Wolf
13, 2012 9:48:10 PM Subject: Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command On 03/06/2012 10:56 AM, Paolo Bonzini wrote: From: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Kevin Wolf
Am 14.03.2012 10:19, schrieb Paolo Bonzini: Il 14/03/2012 10:17, Kevin Wolf ha scritto: If we want to do this, it needs to be the same patch, as we couple the transaction actions with top-level commands as long as there is no other way to discover the possible actions. And it probably makes

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Eric Blake
On 03/14/2012 03:34 AM, Kevin Wolf wrote: That said, reopen is really hard to be implemented as a transaction without breaking that rule. For example in the blkmirror case you'd need to open the destination image in r/w while the mirroring is in action (already having the same image in r/w

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Federico Simoncelli
Sent: Wednesday, March 14, 2012 10:34:08 AM Subject: Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command * We could leave it as it is, a distinct command that is not part of the transaction and that it's closing the old image before opening the new one. Yes, this would

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-14 Thread Kevin Wolf
Am 14.03.2012 14:11, schrieb Eric Blake: * We could use the transaction APIs without actually making it transaction (if we fail in the middle we can't rollback). The only advantage of this is that we'd provide a consistent API to libvirt and we would postpone the problem to the future.

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-13 Thread Eric Blake
On 03/06/2012 10:56 AM, Paolo Bonzini wrote: From: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com ## +# @drive-reopen +# +# Assigns a new image file to a device. +# +# @device: the name of

Re: [Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-13 Thread Federico Simoncelli
] [PATCH v4 10/10] Add the drive-reopen command On 03/06/2012 10:56 AM, Paolo Bonzini wrote: From: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com ## +# @drive-reopen +# +# Assigns a new

[Qemu-devel] [PATCH v4 10/10] Add the drive-reopen command

2012-03-06 Thread Paolo Bonzini
From: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Federico Simoncelli fsimo...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- blockdev.c | 63 ++ hmp-commands.hx | 16 + hmp.c| 11