Changes in v2: * rebased This patch requires another one, otherwise a small conflict appears: https://www.redhat.com/archives/libvir-list/2016-July/msg00402.html
In qemu_driver.c, two functions were split to have less responsibility. They were also modified so that they could be used in qemuhotplugtest. Now instead of running different functions to attach different device types, a generic function is run. Hopefully this will result in more device types tested in the future. Suggestions on how to name these two new functions are very welcome. In the future, if one uses the following command: virsh attach-device --live --config the new device will have the same address assigned in both live and config domain. To make sure that everything will work properly after making these changes, I reworked qemuhotplug.c to work with attaching devices to persistent domains. So far, there is only one test for persistent attachment. I will add more testcases as soon as I hear some feedback on these changes. qemuhotplugtest.c should first be modified anyway, so that the three xmls's filenames (basis domain xml, device xml, expected xml) are stated explicitly instead of being calculated. This will allow for more flexibility in testing and less xml files duplicates. Tomasz Tomasz Flendrich (10): Change parameters to qemuDomainAttachDeviceLive Remove an unnecessary variable Split qemuDomainAttachDeviceFlags in two Narrow down a parameter Split qemuDomainDetachDeviceFlags in two Make qemu attach/detach functions public Narrow down a parameter to function Use more generic functions in qemuhotplugtest Make qemuhotplugtest work with persistent domains Add a persistent attachment testcase src/qemu/qemu_driver.c | 221 +++++++++++---------- src/qemu/qemu_driver.h | 14 ++ tests/qemuhotplugtest.c | 213 ++++++++++++-------- .../qemuhotplug-base-config+qemu-agent+config.xml | 45 +++++ .../qemuhotplug-base-config.xml | 40 ++++ 5 files changed, 349 insertions(+), 184 deletions(-) create mode 100644 tests/qemuhotplugtestdomains/qemuhotplug-base-config+qemu-agent+config.xml create mode 100644 tests/qemuhotplugtestdomains/qemuhotplug-base-config.xml -- 2.7.4 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list