Bug 1782370 - vioinput: high resolution host mouse does not work with "virtio-mouse-pci" and "input-linux"
Summary: vioinput: high resolution host mouse does not work with "virtio-mouse-pci" an...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: virtio-win
Version: 8.0
Hardware: Unspecified
OS: Windows
unspecified
unspecified
Target Milestone: rc
: 8.0
Assignee: ybendito
QA Contact: Peixiu Hou
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-12-11 14:35 UTC by ybendito
Modified: 2020-08-06 06:33 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-04-28 16:05:15 UTC
Type: Bug
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2020:1757 None None None 2020-04-28 16:06:07 UTC

Description ybendito 2019-12-11 14:35:07 UTC
Description of problem:


Version-Release number of selected component (if applicable):


How reproducible: 100%

Steps to Reproduce:
https://github.com/virtio-win/kvm-guest-drivers-windows/issues/385

Actual results:
The mouse does not move correctly in VM

Comment 2 ybendito 2019-12-13 04:47:28 UTC
Fixed in virtio-win-pre-whql 174
https://brewweb.engineering.redhat.com/brew/buildinfo?buildID=1035685

Comment 3 Peixiu Hou 2019-12-13 10:05:26 UTC
Hi Yuri,

I cannot reproduce it with our lab used mouse device, just connect it to vm, maybe my steps has some problem, so could you help provide some simple reproduce steps to reproduce it?

I used command as:
    -enable-kvm \
    -device virtio-mouse-pci,id=input_input1,bus=pcie.0,addr=0x5 \
    -monitor stdio -qmp tcp:0:5888,server,nowait \
    -vga qxl \
    -spice port=3001,disable-ticketing -soundhw hda \
    -device virtio-serial,bus=pcie.0 -chardev spicevmc,id=vdagent,debug=0,name=vdagent \


Thanks a lot~
Peixiu

Comment 4 ybendito 2019-12-13 13:45:05 UTC
(In reply to Peixiu Hou from comment #3)
> Hi Yuri,
> 
> I cannot reproduce it with our lab used mouse device, just connect it to vm,
> maybe my steps has some problem, so could you help provide some simple
> reproduce steps to reproduce it?
> 
> I used command as:
>     -enable-kvm \
>     -device virtio-mouse-pci,id=input_input1,bus=pcie.0,addr=0x5 \
>     -monitor stdio -qmp tcp:0:5888,server,nowait \
>     -vga qxl \
>     -spice port=3001,disable-ticketing -soundhw hda \
>     -device virtio-serial,bus=pcie.0 -chardev
> spicevmc,id=vdagent,debug=0,name=vdagent \
> 

The problem happens with vioinput

Comment 5 ybendito 2019-12-13 13:49:08 UTC
(In reply to Peixiu Hou from comment #3)
> Hi Yuri,
> 
> I cannot reproduce it with our lab used mouse device, just connect it to vm,
> maybe my steps has some problem, so could you help provide some simple
> reproduce steps to reproduce it?
> 
> I used command as:
>     -enable-kvm \
>     -device virtio-mouse-pci,id=input_input1,bus=pcie.0,addr=0x5 \
>     -monitor stdio -qmp tcp:0:5888,server,nowait \
>     -vga qxl \
>     -spice port=3001,disable-ticketing -soundhw hda \
>     -device virtio-serial,bus=pcie.0 -chardev
> spicevmc,id=vdagent,debug=0,name=vdagent \
> 
The repro procedure is described in the referenced issue, involved virio-input and input-linux. But this requires also high resolution mouse (not an usual one).

Comment 6 Peixiu Hou 2019-12-16 08:08:32 UTC
Hi Yuri,

I reproduced this issue with build virtio-win-prewhql-173, tested with a mouse support 1000/1200/1600 DPI on win2019 guest, when set mouse DPI to 1600 and change the display resolution to 2560*1600(keep the display refresh rate 64Hz, due to we cannot adjust it in guest vm), can reproduce this issue easily, the mouse move similar with the video for https://github.com/virtio-win/kvm-guest-drivers-windows/issues/385.

Steps as:
1. Boot a guest vm up with virtio-mouse-pci device, I did not use command "-object input-linux,id=mouse1,evdev=/dev/input/by-id/***":
/usr/libexec/qemu-kvm \
    -name 'avocado-vt-vm1' \
    -machine pc  \
    -nodefaults \
    -device VGA,bus=pci.0,addr=0x2 \
    -m 8192  \
    -smp 24,maxcpus=24,cores=12,threads=1,dies=1,sockets=2  \
    -cpu 'Skylake-Server',hv_stimer,hv_synic,hv_vpindex,hv_reset,hv_relaxed,hv_spinlocks=0x1fff,hv_vapic,hv_time,hv-tlbflush,+kvm_pv_unhalt  \
    -device pvpanic,ioport=0x505,id=idAHFs9n \
    -device qemu-xhci,id=usb1,bus=pci.0,addr=0x3 \
    -device virtio-scsi-pci,id=virtio_scsi_pci0,bus=pci.0,addr=0x4 \
    -drive id=drive_image1,if=none,snapshot=off,aio=threads,cache=none,format=qcow2,file=/home/kvm_autotest_root/images/win2019-64-virtio-scsi.qcow2 \
    -device scsi-hd,id=image1,drive=drive_image1 \
    -device virtio-net-pci,mac=9a:79:5b:20:70:4a,id=idP1WKM0,netdev=idfheR18,bus=pci.0,addr=0x5  \
    -netdev tap,id=idfheR18,vhost=on \
    -drive id=drive_cd1,if=none,snapshot=off,aio=threads,cache=none,media=cdrom,file=/home/kvm_autotest_root/iso/windows/winutils.iso \
    -device scsi-cd,id=cd1,drive=drive_cd1  \
    -vnc :0  \
    -rtc base=localtime,clock=host,driftfix=slew  \
    -boot order=cdn,once=c,menu=off,strict=off \
    -enable-kvm -qmp tcp:0:4448,server,nowait \
    -device virtio-mouse-pci,id=input2,bus=pci.0,addr=0xb \
    -monitor stdio

2. Change the display resolution to 2560*1600(guest supported maximum is this).

3. Change the mouse DPI to 1600. 

4. Fast move mouse to left/right. ---will saw the mouse messy drift.

Tried tested with build virtio-win-prewhql-174, cannot reproduce this issue, the mouse can move normally.

As above results, this bug seems can be verified, just I'm not sure if my steps are correct, because I didn't use "-object input-linux" command.
Could you help to confirm if correct? If yes, I'll change this issue to verified. 

BTW, we don't test with "-object input-linux" before, does it supported by downstream and what is this role? and it seems also used qemu simulation, not same with virtio input device pass-trough, if any update we need added to our test plan for this?

Thanks and Best Regards~
Peixiu

Comment 7 ybendito 2019-12-16 08:42:02 UTC
Yes, thank you, this test procedure is also correct.
In both cases (one I described and one you use) the same events come to the driver.

Comment 8 Peixiu Hou 2019-12-16 08:59:31 UTC
(In reply to ybendito from comment #7)
> Yes, thank you, this test procedure is also correct.
> In both cases (one I described and one you use) the same events come to the
> driver.

Ok, thanks for your confirm~
I changed the bug to verified~

Thanks~
Peixiu

Comment 17 errata-xmlrpc 2020-04-28 16:05:15 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2020:1757


Note You need to log in before you can comment on or make changes to this bug.