mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-03 03:25:20 +00:00
qemu: domain: Fix backing store terminator for non-backing local files
Raw local files do not pass through the backing store detector and thus
the code did not allocate the required backing store terminator for
them. Previously the terminating element would be formatted into the XML
since the default values used for the metadata allowed that. This is a
regression since a693fdba01
which was not detected in the review.
This patch also reverts all the changes in the test files.
This commit is contained in:
parent
24e47ee2b9
commit
adcc31bb89
@ -6385,6 +6385,11 @@ qemuDomainDetermineDiskChain(virQEMUDriverPtr driver,
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
/* terminate the chain for such images as the code below would do */
|
||||
if (!src->backingStore &&
|
||||
VIR_ALLOC(src->backingStore) < 0)
|
||||
goto cleanup;
|
||||
|
||||
ret = 0;
|
||||
goto cleanup;
|
||||
}
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='vde' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='hda' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
@ -31,6 +32,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='hdb' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='hda' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='hda' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='hda' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -33,6 +33,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='sdg' bus='scsi'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='sdf' bus='scsi'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='sdq' bus='usb'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='vde' bus='virtio'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
@ -22,6 +22,7 @@
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw' cache='none'/>
|
||||
<source file='/dev/null'/>
|
||||
<backingStore/>
|
||||
<target dev='sdf' bus='scsi'/>
|
||||
<readonly/>
|
||||
<shareable/>
|
||||
|
Loading…
Reference in New Issue
Block a user