Multiple video elements lead to erratic mouse behavior through spice
Erik Skultety
eskultet at redhat.com
Wed Jun 10 13:35:20 UTC 2020
On Wed, Jun 10, 2020 at 01:58:13PM +0200, Christian Ehrhardt wrote:
> Hi,
> with a guest set up as in the following example mouse behavior breaks:
>
> <graphics type='spice' port='5901' autoport='no' listen='0.0.0.0'>
> <listen type='address' address='0.0.0.0'/>
> <gl enable='no'/>
> </graphics>
> <video>
> <model type='qxl' ram='65536' vram='16384' vgamem='16384' heads='1'
> primary='yes'/>
> <address type='pci' domain='0x0000' bus='0x00' slot='0x01'
> function='0x0'/>
> </video>
> <video>
> <model type='qxl' ram='65536' vram='16384' vgamem='16384' heads='1'/>
> <address type='pci' domain='0x0000' bus='0x08' slot='0x01'
> function='0x0'/>
> </video>
>
> Please note that this is for illustration purposes as this everyone can
> easily retry.
> I originally had QXL + GPU as mediated device, where the behavior is the
> same.
>
> If I know connect to that via spice, spice is smart and opens both displays:
> $ virt-viewer --connect qemu+ssh://ubuntu@10.246.115.255/system guestname
>
> But while with one display mouse integration (to move in/out smoothly) and
> positioning of the mouse pointer is fine.
> It is broken with this double display setup.
> What I see is:
> - no mouse integration anymore (falls back to capture the mouse)
> - often the mouse can not move upwards anymore
> - sometimes "left" also doesn't work
I'm afraid I can't help on ^this, that is beyond libvirt.
>
> Let me know if someone wants a video in case the description is still too
> odd.
>
> I have tried spice-client-gtk and virt-viewer, but both behave the same way.
>
> If I take away one of the displays it works well again.
> So I'm wondering how virtual-multi-monitor is supposed to work, are there
> known bugs or tweaks that would apply here?
>
> In my original case I wanted to take away the QXL device, to jst keep the
> Mdev as one screen (and the one I really want).
> But due to [1] the video section is re-added automatically.
So, if you want to stop libvirt doing that, use:
<video>
<model type='none'/>
</video>
https://libvirt.org/formatdomain.html#elementsVideo
With ^this in place, you can use mdev with display=on as your primary display
(I assume you're using Intel? Or are you already making use of ramfb to get
boot output from NVIDIA?)
>
> Maybe this comes down to not re-adding that default video entry if a
> hostdev has display=on set?
>
> I'd appreciate any pointers if this rings a bell or a discussion on
> not-auto-adding-video if display=on is present.
>
> Kind Regards,
> Christian
>
> P.S. I tried VNC but that just has "other" issues. It only shows 1 of 2
> displays and on the one I see over amplifies the mouse movement by the
> amount the other display adds to ther overall desktop size.
Okay, this hints Intel, because there's no cursor with NVIDIA :D unless you use
vncviewer and force usage of the remote cursor.
But if you do want to use 2 virtual monitors (QXL+mdev combo), I've never tried
such a thing, sorry.
Erik
>
> P.P.S. Sorry for cross posting, at least I avoided cross posting even
> further (spice-devel / qemu-devel) hoping that libvirt & virt-tools would
> be involved enough that if someone recognizes this he can point me to the
> right place.
>
> [1]: https://bugzilla.redhat.com/show_bug.cgi?id=707439
More information about the virt-tools-list
mailing list