[libvirt] [PATCH 9/9] Terminate backing chains explicitly
Eric Blake
eblake at redhat.com
Thu Oct 12 20:34:28 UTC 2017
On 10/12/2017 02:07 PM, Peter Krempa wrote:
> Express a properly terminated backing chain by putting a
> virStorageSource of type VIR_STORAGE_TYPE_NONE in the chain. The newly
> used helpers simplify this greatly.
>
> The change fixes a bug as formatting an incomplete backing chain and
> parsing it back would end up in expressing a terminated chain since
> src->backingStoreRaw was not populated. By relying on the terminator
> object this can be now processed appropriately.
> +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live+ccw-virtio.xml
> @@ -22,7 +22,6 @@
> <disk type='file' device='disk'>
> <driver name='qemu' type='raw' cache='none'/>
> <source file='/dev/null'/>
> - <backingStore/>
This gets rid of a lot of terminator markers in the test XML; the code
looks like we will still generate a terminator marker when we know the
full chain, and that lack of a terminator marker is not fatal, but
merely means that we haven't specified a full chain. It feels like a
lot of fallout, but the code with the special terminator does look
nicer, so I can live with the testsuite churn that results.
Reviewed-by: Eric Blake <eblake at redhat.com>
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20171012/e7b33095/attachment-0001.sig>
More information about the libvir-list
mailing list