Bug 508347

Summary: USB keyboard is detected as mouse
Product: [Applications] systemsettings Reporter: Patrick Silva <bugseforuns>
Component: kcm_mouseAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED DUPLICATE    
Severity: normal CC: duha.bugs, natalie_clarius, nate
Priority: NOR    
Version First Reported In: 6.4.4   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: screenshot
libinput list-devices

Description Patrick Silva 2025-08-16 15:19:07 UTC
Created attachment 184147 [details]
screenshot

SUMMARY
Can reproduce on Wayland, cannot on X11, on both Arch and neon unstable.
A few weeks ago I replaced an old Logitech usb keyboard, it was not detected as mouse, but the new keyboard is. Please see the attached screenshot.

EXPECTED RESULT
usb keyboard is always detected correctly, even on Wayland

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.4.4
KDE Frameworks Version: 6.17.0
Qt Version: 6.9.1
Graphics Platform: Wayland

$ lsusb (with keyboard connected)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 004: ID 1a81:2232 Holtek Semiconductor, Inc. Lenovo Gaming Mouse
Bus 001 Device 008: ID 1a2c:0e24 China Resource Semico Co., Ltd USB Keyboard
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 002: ID 8087:8000 Intel Corp. Integrated Rate Matching Hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 002: ID 8087:8008 Intel Corp. Integrated Rate Matching Hub

$ sudo journalctl -f (output after connecting the keyboard)
ago 16 12:04:15 Arch-PC kernel: usb 1-5: New USB device found, idVendor=1a2c, idProduct=0e24, bcdDevice= 1.10
ago 16 12:04:15 Arch-PC kernel: usb 1-5: New USB device strings: Mfr=1, Product=2, SerialNumber=0
ago 16 12:04:15 Arch-PC kernel: usb 1-5: Product: USB Keyboard
ago 16 12:04:15 Arch-PC kernel: usb 1-5: Manufacturer: SEM
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBGL: kevent: adding USB device 1-5.
ago 16 12:04:15 Arch-PC kernel: input: SEM USB Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.0/0003:1A2C:0E24.000C/input/input26
ago 16 12:04:15 Arch-PC kernel: hid-generic 0003:1A2C:0E24.000C: input,hidraw0: USB HID v1.10 Keyboard [SEM USB Keyboard] on usb-0000:00:14.0-5/input0
ago 16 12:04:15 Arch-PC kernel: probe of 0003:1A2C:0E24.000C returned 0 after 68540 usecs
ago 16 12:04:15 Arch-PC kernel: probe of 1-5:1.0 returned 0 after 71028 usecs
ago 16 12:04:15 Arch-PC kernel: input: SEM USB Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.1/0003:1A2C:0E24.000D/input/input27
ago 16 12:04:15 Arch-PC kernel: input: SEM USB Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.1/0003:1A2C:0E24.000D/input/input28
ago 16 12:04:15 Arch-PC kernel: hid-generic 0003:1A2C:0E24.000D: input,hidraw1: USB HID v1.10 Device [SEM USB Keyboard] on usb-0000:00:14.0-5/input1
ago 16 12:04:15 Arch-PC kernel: probe of 0003:1A2C:0E24.000D returned 0 after 50812 usecs
ago 16 12:04:15 Arch-PC kernel: probe of 1-5:1.1 returned 0 after 52989 usecs
ago 16 12:04:15 Arch-PC kernel: probe of 1-5 returned 0 after 125148 usecs
ago 16 12:04:15 Arch-PC mtp-probe[30703]: checking bus 1, device 9: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-5"
ago 16 12:04:15 Arch-PC mtp-probe[30703]: bus: 1, device: 9 was not an MTP device
ago 16 12:04:15 Arch-PC systemd-logind[631]: Watching system buttons on /dev/input/event3 (SEM USB Keyboard)
ago 16 12:04:15 Arch-PC systemd-logind[631]: Watching system buttons on /dev/input/event5 (SEM USB Keyboard System Control)
ago 16 12:04:15 Arch-PC systemd-logind[631]: Watching system buttons on /dev/input/event4 (SEM USB Keyboard Consumer Control)
ago 16 12:04:15 Arch-PC mtp-probe[30726]: checking bus 1, device 9: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-5"
ago 16 12:04:15 Arch-PC mtp-probe[30726]: bus: 1, device: 9 was not an MTP device
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBGL: Failed to open '/sys/bus/usb/devices/1-5/serial', error(0x2).
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBGL: DevID(1a2c0e24): Failed to read serial number for '1-5'.
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBGL: Failed to open '/sys/bus/usb/devices/1-5/serial', error(0x2).
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBArb: DevID(81a2c0e24): Bootable hid device is not allowed.
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBArb: DevID(81a2c0e24): Device defaults to target 'host:' with rule(id:8).
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBArb: DevID(81a2c0e24): Device added.
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBArb: DevID(21a812232): Device 0: name:Holtek\ Lenovo\ Gaming\ Mouse vid:1a81 pid:2232 path:1/6 speed:full family:hid,hid-bootable arbRuntimeKey:2 version:5 owner:(null).
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBArb: DevID(81a2c0e24): Device 1: name:China\ Resource\ Semico\ USB\ Keyboard vid:1a2c pid:0e24 path:1/5 speed:low family:hid,hid-bootable arbRuntimeKey:8 version:5 owner:(null).
ago 16 12:04:15 Arch-PC vmware-usbarbitrator[638]: USBArb: 2 devices enumerated.
ago 16 12:04:16 Arch-PC vmware-usbarbitrator[638]: USBArb: DevID(81a2c0e24): Unclaiming device for client '(null)'.
ago 16 12:04:16 Arch-PC vmware-usbarbitrator[638]: USBArb: Updating autoconnect to 0.

$ sudo dmesg -Tw (output after connecting the keyboard)
[sáb ago 16 12:04:15 2025] usb 1-5: new low-speed USB device number 9 using xhci_hcd
[sáb ago 16 12:04:15 2025] usb 1-5: New USB device found, idVendor=1a2c, idProduct=0e24, bcdDevice= 1.10
[sáb ago 16 12:04:15 2025] usb 1-5: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[sáb ago 16 12:04:15 2025] usb 1-5: Product: USB Keyboard
[sáb ago 16 12:04:15 2025] usb 1-5: Manufacturer: SEM
[sáb ago 16 12:04:15 2025] input: SEM USB Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.0/0003:1A2C:0E24.000C/input/input26
[sáb ago 16 12:04:15 2025] hid-generic 0003:1A2C:0E24.000C: input,hidraw0: USB HID v1.10 Keyboard [SEM USB Keyboard] on usb-0000:00:14.0-5/input0
[sáb ago 16 12:04:15 2025] probe of 0003:1A2C:0E24.000C returned 0 after 68540 usecs
[sáb ago 16 12:04:15 2025] probe of 1-5:1.0 returned 0 after 71028 usecs
[sáb ago 16 12:04:15 2025] input: SEM USB Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.1/0003:1A2C:0E24.000D/input/input27
[sáb ago 16 12:04:15 2025] input: SEM USB Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.1/0003:1A2C:0E24.000D/input/input28
[sáb ago 16 12:04:15 2025] hid-generic 0003:1A2C:0E24.000D: input,hidraw1: USB HID v1.10 Device [SEM USB Keyboard] on usb-0000:00:14.0-5/input1
[sáb ago 16 12:04:15 2025] probe of 0003:1A2C:0E24.000D returned 0 after 50812 usecs
[sáb ago 16 12:04:15 2025] probe of 1-5:1.1 returned 0 after 52989 usecs
[sáb ago 16 12:04:15 2025] probe of 1-5 returned 0 after 125148 usecs
Comment 1 Nate Graham 2025-08-18 20:32:43 UTC
Is it a wired keyboard, or a wireless one with a USB RF receiver?
Comment 2 Patrick Silva 2025-08-18 20:38:45 UTC
It's a wired keyboard.
Comment 3 Nate Graham 2025-08-19 19:35:42 UTC
Thanks, bit weird. Can you paste or attach the output of `sudo libinput list-devices`?
Comment 4 Patrick Silva 2025-08-19 19:54:54 UTC
Created attachment 184269 [details]
libinput list-devices
Comment 5 Nate Graham 2025-08-19 20:00:36 UTC
Well, that's the problem:

> Device:                  SEM USB Keyboard Consumer Control
> [...]
> Capabilities:            keyboard pointer 

The keyboard is telling us it's also a mouse! The presence of the words "Consumer Control" in the name originally made me suspect it was an RF receiver for a mouse/keyboard pair, because you often see those words used for that kind of hardware, and those also show up as both a keyboard and a mouse.

I suspect what's going on is that the vendor cheaped out and used the same hardware only with a wired form factor, so it still tells the system it's a receiver for a mouse/keyboard pair even though it isn't.

Ultimately this is yet another case of the generic issue Bug 465957, which tracks us figuring out a way to filter out these kinds of lying devices.

*** This bug has been marked as a duplicate of bug 465957 ***