[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/3] block: Add QMP support for streaming to an
From: |
Alberto Garcia |
Subject: |
Re: [Qemu-devel] [PATCH 2/3] block: Add QMP support for streaming to an intermediate layer |
Date: |
Mon, 23 Feb 2015 13:23:08 +0100 |
User-agent: |
Mutt/1.5.20 (2009-06-14) |
On Fri, Feb 20, 2015 at 03:38:04PM -0700, Eric Blake wrote:
> > + if (has_top) {
> > + top_bs = bdrv_find_backing_image(bs, top);
> > + if (top_bs == NULL) {
> > + error_set(errp, QERR_TOP_NOT_FOUND, top);
> > + goto out;
> > + }
>
> If I understand correctly, bdrv_find_backing_image has problems for
> backing nodes that don't have a file name. Given our shift towards
> node names, I think we really want to target node names rather than
> file names when specifying which node we will use as the top bound
> receiving the stream operations.
Sure I can change that, but note that the 'base' parameter also
receives a file name and uses bdrv_find_backing_image, so I guess it
makes sense to change it in both sides.
> > +#define QERR_TOP_NOT_FOUND \
> > + ERROR_CLASS_GENERIC_ERROR, "Top '%s' not found"
> > +
>
> Please don't. Just use error_setg() at the right place with the
> direct message (existing QERR_ macros are a legacy holdover, and we
> shouldn't be creating more of them).
Ok, I'll fix that.
I'll wait for more comments regarding the top / base parameters before
resubmitting the patches.
Thanks,
Berto
Re: [Qemu-devel] [PATCH 0/3] Support streaming to an intermediate layer, Eric Blake, 2015/02/20