On Tue, May 10, 2016 at 09:43:04AM +0100, Richard W.M. Jones wrote: > On Tue, May 10, 2016 at 09:14:26AM +0100, Richard W.M. Jones wrote: > > However I didn't test the write-shareable case (the libvirt > > <shareable/> flag which should map to a shared lock -- is that right Dan?). > > To Dan (mainly): I think setting the <shareable/> flag in libvirt only > sets cache=unsafe on the qemu drive (it may have other effects for > virtlockd). Should there be an extra qemu drive flag to communicate > that the drive is write-shareable?
Sure, if QEMU had a way to indicate that the disk was used in a write-sharable mode, libvirt would use it. I agree with your general point that we should do no locking for read-only access, F_RDLCK for shared-write and F_WRLCK for exclusive-write access. I think I made that point similarly against an earlier version of this patchset Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|