From: Peter Krempa Date: Fri, 23 Jun 2017 12:11:25 +0000 (+0200) Subject: tests: hotplug: Test disks with duplicate WWNs X-Git-Tag: v3.5.0-rc1~25 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d65781bf061fb6369494b381c908ec2e08b05769;p=thirdparty%2Flibvirt.git tests: hotplug: Test disks with duplicate WWNs --- diff --git a/tests/qemuhotplugtest.c b/tests/qemuhotplugtest.c index fe97fd0dc3..79f0326905 100644 --- a/tests/qemuhotplugtest.c +++ b/tests/qemuhotplugtest.c @@ -76,6 +76,7 @@ qemuHotplugCreateObjects(virDomainXMLOptionPtr xmlopt, virQEMUCapsSet(priv->qemuCaps, QEMU_CAPS_VIRTIO_CCW); virQEMUCapsSet(priv->qemuCaps, QEMU_CAPS_DEVICE_IVSHMEM_PLAIN); virQEMUCapsSet(priv->qemuCaps, QEMU_CAPS_DEVICE_IVSHMEM_DOORBELL); + virQEMUCapsSet(priv->qemuCaps, QEMU_CAPS_SCSI_DISK_WWN); if (event) virQEMUCapsSet(priv->qemuCaps, QEMU_CAPS_DEVICE_DEL_EVENT); @@ -809,6 +810,10 @@ mymain(void) DO_TEST_DETACH("base-live", "ivshmem-plain-detach", false, false, "device_del", QMP_OK, "object-del", QMP_OK); + DO_TEST_ATTACH("base-live+disk-scsi-wwn", + "disk-scsi-duplicate-wwn", false, true, + "human-monitor-command", HMP("OK\\r\\n"), + "device_add", QMP_OK); #define DO_TEST_CPU_GROUP(prefix, vcpus, modernhp, expectfail) \ do { \ diff --git a/tests/qemuhotplugtestdevices/qemuhotplug-disk-scsi-duplicate-wwn.xml b/tests/qemuhotplugtestdevices/qemuhotplug-disk-scsi-duplicate-wwn.xml new file mode 100644 index 0000000000..5d09ad973e --- /dev/null +++ b/tests/qemuhotplugtestdevices/qemuhotplug-disk-scsi-duplicate-wwn.xml @@ -0,0 +1,8 @@ + + + + + + + 0x5000c50015ea71aa + diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-live+disk-scsi-wwn+disk-scsi-duplicate-wwn.xml b/tests/qemuhotplugtestdomains/qemuhotplug-base-live+disk-scsi-wwn+disk-scsi-duplicate-wwn.xml new file mode 100644 index 0000000000..4c3ea3202b --- /dev/null +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-live+disk-scsi-wwn+disk-scsi-duplicate-wwn.xml @@ -0,0 +1,74 @@ + + hotplug + d091ea82-29e6-2e34-3005-f02617b36e87 + 4194304 + 4194304 + 4 + + hvm + + + + + + + + + destroy + restart + restart + + /usr/bin/qemu-system-x86_64 + + + + + + + + 0x5000c50015ea71aa + +
+ + + + + + + + + 0x5000c50015ea71aa + +
+ + + +
+ + + +
+ + + +
+ + + + + + +
+ + + + + + + + + + + + + diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-live+disk-scsi-wwn.xml b/tests/qemuhotplugtestdomains/qemuhotplug-base-live+disk-scsi-wwn.xml new file mode 100644 index 0000000000..0de8656d2b --- /dev/null +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-live+disk-scsi-wwn.xml @@ -0,0 +1,63 @@ + + hotplug + d091ea82-29e6-2e34-3005-f02617b36e87 + 4194304 + 4194304 + 4 + + hvm + + + + + + + + + destroy + restart + restart + + /usr/bin/qemu-system-x86_64 + + + + + + + + 0x5000c50015ea71aa + +
+ + + +
+ + + +
+ + + +
+ + + + + + +
+ + + + + + + + + + + + +