Bug 216106

Summary: Huion Kamvas Pro 16 (GT1602) issues from kernel 5.18.0
Product: Drivers Reporter: F. G. Szilagyi (fgszilagyi)
Component: Input DevicesAssignee: drivers_input-devices
Status: RESOLVED CODE_FIX    
Severity: high CC: jose.exposito89, quantmint, tasksynctest
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 5.18 Subsystem:
Regression: No Bisected commit-id:
Attachments: HID recording

Description F. G. Szilagyi 2022-06-09 20:21:28 UTC
The graphics tablet mentioned in the title has been working rather fine out of the box 5.15 LTS and 5.17 kernel releases, however I started having problems since 5.18.

Under 5.18.x kernel versions, if I plug the tablet in while my system is already running, the pen input is only recognized until the first time I either lift the pen away from the screen, or press one of the tablet's side buttons.

If I boot the machine with the tablet already plugged in, the issue doesn't appear consistently. Worst case a couple reboots allow me to get it working.

I have checked that the issue is happening from 5.18-rc1, and is still present in 5.19-rc1.

I couldn't bisect it to the exact commit yet, as the kernel builds take a very long time on my machine.

Dmesg output doesn't show anything useful (it's the same regardless whether the tablet keeps working or loses the pen after the first time lifting it). The only good lead I have is that the issue seems to be introduced in this patch set: https://lore.kernel.org/lkml/nycvar.YFH.7.76.2203231015060.24795@cbobk.fhfr.pm/
Comment 1 QuantMint 2022-07-14 12:38:30 UTC
I am getting exactly the same issue on Linux 5.18 with a Huion Inspiroy H1161. It works with Linux 5.15.
Comment 2 José Expósito 2022-08-13 11:00:45 UTC
Created attachment 301558 [details]
HID recording

Output of "sudo hid-recorder --output HUION.txt".

Recording:

 1. Pen in proximity
 2. Draw a small circle without touching the pad
 3. Pen out of proximity
 4. Repeat steps 1 to 3

In user-space only the first circle moves the pointer.
Comment 3 José Expósito 2022-08-13 11:02:23 UTC
Hi!

The issue was reported to the input mailing list. We bisected the bug and we're looking into a fix:
https://lore.kernel.org/linux-input/CAO-hwJ+hBipNJpeYaHRr2-rKXA5d79XT7zE2fo2oEKUKJtKJ0g@mail.gmail.com/T/#t
Comment 4 José Expósito 2022-08-28 10:10:36 UTC
Hi again,

The problem is now solved. Here is the patch that fixes this issue:

https://lore.kernel.org/linux-input/20220822062247.1146141-1-benjamin.tissoires@redhat.com/T/#u
Comment 5 F. G. Szilagyi 2022-09-03 11:20:07 UTC
Tested the patch. Thank you very much for fixing this!