devices: graphics: Don't use spice default on xen

This matches what we have historically done, prior to the domcaps
change in 30382d57f. Xen will report spice in domcaps but we should
not let that change our historical default

https://listman.redhat.com/archives/virt-tools-list/2022-February/msg00006.html

Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
Cole Robinson 2022-02-10 10:13:44 -05:00
parent 9c6efdc1d5
commit b4e35c0687

View File

@ -155,6 +155,13 @@ class DeviceGraphics(Device):
def _default_type(self, guest):
gtype = guest.default_graphics_type
log.debug("Using default_graphics=%s", gtype)
if self.conn.is_xen():
# Xen domcaps can advertise spice support, but we have historically
# not defaulted to it for xen, so force vnc.
log.debug("Not defaulting to spice for xen driver. Using vnc.")
gtype = "vnc"
if (gtype == "spice" and
not guest.lookup_domcaps().supports_graphics_spice()):
log.debug("spice requested but HV doesn't support it. "