Date: Wed, 8 Oct 2025 07:09:26 +0000 From: Vasily Postnicov <shamaz.mazum@gmail.com> To: freebsd-virtualization@freebsd.org Subject: virtio-input mouse Message-ID: <CADnZ6Bmy0OB7x0a0xU1Szz6XD-Pw1iXyPwnaEZ3OC1SXMcWbGQ@mail.gmail.com>
index | next in thread | raw e-mail
[-- Attachment #1 --]
Is it possible to have mouse emulation using virtio-input in bhyve?
My FreeBSD version is 14.3-RELEASE-p3, UEFI bootrom from
edk2-bhyve-g202308_5 and the guest is Ubuntu Linux.
My mouse device seems to be /dev/input/event6 (I guess. I checked this
using cat /dev/input/event6 and moving my mouse).
I start bhyve as follows:
bhyve -c 2 -m 8G -w -H \
-s 0,hostbridge -s 3,virtio-blk,/dev/zvol/mypool/virtual/ubuntu2
\
-s 5,virtio-net,tap0 -s 6,virtio-input,/dev/input/event6 \
-s 29,fbuf,tcp=127.0.0.1:5900,w=1920,h=1080 \
-s 31,lpc -l com1,stdio -l bootrom,BHYVE_UEFI.fd ubuntu
and use wlvncc to connect to the VNC server. This way the mouse pointer
stops moving in the host system and there is no mouse in the guest.
When I use -s 30,xhci,tablet my mouse works, but I wonder if I can use
virtio-input instead.
[-- Attachment #2 --]
<div dir="ltr">Is it possible to have mouse emulation using virtio-input in bhyve?<div><br></div><div>My FreeBSD version is 14.3-RELEASE-p3, UEFI bootrom from edk2-bhyve-g202308_5 and the guest is Ubuntu Linux.</div><div><br></div><div>My mouse device seems to be /dev/input/event6 (I guess. I checked this using cat /dev/input/event6 and moving my mouse).<br><div><br></div><div>I start bhyve as follows:</div><div>bhyve -c 2 -m 8G -w -H \</div><div> -s 0,hostbridge -s 3,virtio-blk,/dev/zvol/mypool/virtual/ubuntu2 \</div><div> -s 5,virtio-net,tap0 -s 6,virtio-input,/dev/input/event6 \</div><div> -s 29,fbuf,tcp=<a href="http://127.0.0.1:5900">127.0.0.1:5900</a>,w=1920,h=1080 \</div><div> -s 31,lpc -l com1,stdio -l bootrom,BHYVE_UEFI.fd ubuntu<br></div></div><div><br></div><div>and use wlvncc to connect to the VNC server. This way the mouse pointer stops moving in the host system and there is no mouse in the guest.</div><div><br></div><div>When I use -s 30,xhci,tablet my mouse works, but I wonder if I can use virtio-input instead.</div></div>
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CADnZ6Bmy0OB7x0a0xU1Szz6XD-Pw1iXyPwnaEZ3OC1SXMcWbGQ>
