]> xenbits.xensource.com Git - libvirt.git/commitdiff
qemu: hotplug: Don't generate alias when detaching disk
authorPeter Krempa <pkrempa@redhat.com>
Tue, 24 Jul 2018 12:39:46 +0000 (14:39 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Tue, 21 Aug 2018 13:46:06 +0000 (15:46 +0200)
It should be impossible to lack an alias in the domain definition. Other
disk types don't generate it so remove it here as well.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/qemu/qemu_hotplug.c

index 7e6f4cf7ba53025464647195f0e01bc92bcc71b2..a7809661d1ca6ac08e1c2ab654fbbf9173faae81 100644 (file)
@@ -4915,11 +4915,6 @@ qemuDomainDetachVirtioDiskDevice(virQEMUDriverPtr driver,
         goto cleanup;
     }
 
-    if (!detach->info.alias) {
-        if (qemuAssignDeviceDiskAlias(vm->def, detach) < 0)
-            goto cleanup;
-    }
-
     if (!async)
         qemuDomainMarkDeviceForRemoval(vm, &detach->info);