Martin Kletzander <mkletzan@xxxxxxxxxx> writes: > If the user updates from QEMU without DRIVE_READONLY to newer one, > that supports that flag, than XML with readonly IDE HDD will stop > working even though it worked before the update *as requested*. That > readonly flag does not reflect how the disk is exposed in the guest; > as you said IDE does not have any readonly concept, that is only how > the device reacts to writes. > > Changing the behaviour to: > > if (disk->readonly && > virQEMUCapsGet(qemuCaps, QEMU_CAPS_DRIVE_READONLY) && > !(disk->bus == VIR_DOMAIN_DISK_BUS_IDE && > disk->device == VIR_DOMAIN_DISK_DEVICE_DISK)) > virBufferAddLit(&opt, ",readonly=on"); > > > would keep the backward compatibility. This behaviour makes more > sense to me. this behaves in a quite different way that my proposed patch but if <readonly/> affects also the SELinux label and we allow the process to run anyway by skipping readonly=on for IDE disks, wouldn't qemu fail in weird ways when trying to write to the file? Regards, Giuseppe -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list