----- Original Message ----- > From: "Kevin Wolf" <kw...@redhat.com> > To: "Federico Simoncelli" <fsimo...@redhat.com> > Cc: qemu-devel@nongnu.org, "Marcelo Tosatti" <mtosa...@redhat.com>, > lcapitul...@redhat.com, "Paolo Bonzini" > <pbonz...@redhat.com>, "Markus Armbruster" <arm...@redhat.com> > Sent: Friday, February 24, 2012 1:03:08 PM > Subject: Re: [PATCH 2/2] Add the blockdev-reopen and blockdev-migrate commands > > Am 24.02.2012 12:37, schrieb Federico Simoncelli: > > Signed-off-by: Federico Simoncelli <fsimo...@redhat.com> > > --- > > block/blkmirror.c | 2 +- > > blockdev.c | 109 > > +++++++++++++++++++++++++++++++++++++++++++++++------ > > hmp-commands.hx | 36 +++++++++++++++++ > > hmp.c | 30 ++++++++++++++ > > hmp.h | 2 + > > qapi-schema.json | 63 ++++++++++++++++++++++++++++++ > > 6 files changed, 229 insertions(+), 13 deletions(-) > > > > diff --git a/block/blkmirror.c b/block/blkmirror.c > > index 39927c8..49e3381 100644 > > --- a/block/blkmirror.c > > +++ b/block/blkmirror.c > > @@ -81,7 +81,7 @@ static int blkmirror_open(BlockDriverState *bs, > > const char *filename, int flags) > > bdrv_delete(m->bs[0]); > > return -ENOMEM; > > } > > - ret = bdrv_open(m->bs[1], filename, flags, NULL); > > + ret = bdrv_open(m->bs[1], filename, flags | BDRV_O_NO_BACKING, > > NULL); > > if (ret < 0) { > > bdrv_delete(m->bs[0]); > > return ret; > > Was this hunk meant to be in patch 1?
Not necessarily, I thought a lot about it. I didn't want to modify Marcelo's patch too much. This flag is actually mandatory only to make blockdev-migrate work with a destination that doesn't have a backing file yet, so I thought it was more appropriate to squash it here. -- Federico