Check whether virtiofs is exposed in domcapabilities, We can use it as a proxy for 'libvirt is new enough to allow bare memory access mode=shared' as well. Signed-off-by: Lin Ma <lma@xxxxxxxx> --- virtinst/domcapabilities.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/virtinst/domcapabilities.py b/virtinst/domcapabilities.py index 65b984ce..978deb85 100644 --- a/virtinst/domcapabilities.py +++ b/virtinst/domcapabilities.py @@ -363,6 +363,13 @@ class DomainCapabilities(XMLBuilder): types = self.devices.graphics.get_enum("type").get_values() return bool("spice" in types) + def supports_filesystem_virtiofs(self): + """ + Return True if libvirt advertises support for virtiofs + """ + types = self.devices.filesystem.get_enum("driverType").get_values() + return bool("virtiofs" in types) + XML_NAME = "domainCapabilities" os = XMLChildProperty(_OS, is_single=True) -- 2.26.2