[Bug 1511511] Re: USB keyboard stops working after pressing extended key
@Alexander, @Taimur: thanks to your comments and efforts, I've managed to make a very basic HID driver for this keyboard. I have tested it against kernel 4.15.0-23-generic with success. Please remove "hid_generic" before loading this module and plugging the keyboard in, so that hid_generic doesn't take on the device. I took some parts from the aziokbd.c driver (by Colin Svingen; https://bitbucket.org/Swoogan/aziokbd/src/f3611717bce078056634bc2312dba2787a433401/aziokbd.c?fileviewer =file-view-default) and made a minimal mapping table between the special keys G1-G6 to F1-F5 and SPACE. this way, the rightmost part of the spacebar (which is labelled as G6) also works as the SPACE key. This is my very first implementation of anything related to kernel code, so expect it to be ugly, buggy and incorrect. Actually, I've found that the kernel oops with a stack trace when the device is disconnected. This is not a problem if you're using the keyboard as usual, but if you're unplugging it (as when debugging with a VM, for example), your machine/VM will become unstable. I hope somebody with better understanding of USB and kernel driver programming will take it and make something good out of this code. If you are interested in evolving this driver and you need me to send you keycodes/debugging output, don't hesitate to contact me. ** Attachment added: "Workaround driver for Cougar 500k keyboard bug" https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+attachment/5153716/+files/cougar-500k-0.4.tgz -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
I've uploaded the code to Github, so it can be better read there. https://github.com/dmlambea/linux-cougar-500k-drv -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
** Description changed: - USB keyboard Cougar K500 gaming keyboard has some additional extended + USB keyboard Cougar 500k Gaming Keyboard has some additional extended keys, all of them making the keyboard stop responding if pressed under linux. The device is recovered only by unplugging the USB and plugging it again. The keyboard has been tested under Ubuntu 14.04.3 LTS, Ubuntu 15.04 and Ubuntu 15.10 (the latter running as virtualbox guest). All tests failed with exactly the same behaviour. USB ID is: "060b:500a Solid Year". ProblemType: Bug DistroRelease: Ubuntu 15.10 Package: linux-image-4.2.0-16-generic 4.2.0-16.19 [modified: boot/vmlinuz-4.2.0-16-generic] ProcVersionSignature: Ubuntu 4.2.0-16.19-generic 4.2.3 Uname: Linux 4.2.0-16-generic x86_64 ApportVersion: 2.19.1-0ubuntu3 Architecture: amd64 AudioDevicesInUse: - USERPID ACCESS COMMAND - /dev/snd/controlC0: pinfli 1055 F pulseaudio + USERPID ACCESS COMMAND + /dev/snd/controlC0: pinfli 1055 F pulseaudio Date: Thu Oct 29 19:33:23 2015 HibernationDevice: RESUME=UUID=f68f4b91-ea68-4e4b-9a10-8ed5bca2efbe InstallationDate: Installed on 2015-10-24 (5 days ago) InstallationMedia: Ubuntu-GNOME 15.10 "Wily Werewolf" - Release amd64 (20151021) IwConfig: - enp0s3no wireless extensions. - - lono wireless extensions. + enp0s3no wireless extensions. + + lono wireless extensions. Lsusb: - Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub - Bus 002 Device 002: ID 060b:500a Solid Year - Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub + Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub + Bus 002 Device 002: ID 060b:500a Solid Year + Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub MachineType: innotek GmbH VirtualBox ProcFB: - + ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.2.0-16-generic root=UUID=523dfd8b-b825-47e3-a116-cb85f901386c ro quiet splash PulseList: Error: command ['pacmd', 'list'] failed with exit code 1: No PulseAudio daemon running, or not running as session daemon. RelatedPackageVersions: - linux-restricted-modules-4.2.0-16-generic N/A - linux-backports-modules-4.2.0-16-generic N/A - linux-firmware1.149 + linux-restricted-modules-4.2.0-16-generic N/A + linux-backports-modules-4.2.0-16-generic N/A + linux-firmware1.149 RfKill: - + SourcePackage: linux UdevLog: Error: [Errno 2] No such file or directory: '/var/log/udev' UpgradeStatus: No upgrade log present (probably fresh install) dmi.bios.date: 12/01/2006 dmi.bios.vendor: innotek GmbH dmi.bios.version: VirtualBox dmi.board.name: VirtualBox dmi.board.vendor: Oracle Corporation dmi.board.version: 1.2 dmi.chassis.type: 1 dmi.chassis.vendor: Oracle Corporation dmi.modalias: dmi:bvninnotekGmbH:bvrVirtualBox:bd12/01/2006:svninnotekGmbH:pnVirtualBox:pvr1.2:rvnOracleCorporation:rnVirtualBox:rvr1.2:cvnOracleCorporation:ct1:cvr: dmi.product.name: VirtualBox dmi.product.version: 1.2 dmi.sys.vendor: innotek GmbH -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
Release 0.5 makes this device fully functional. You can download it from: https://github.com/dmlambea/linux-cougar-500k-drv/releases ** Attachment added: "DKMS module package for v0.5" https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+attachment/5156241/+files/cougar-500k-dkms_0.5_amd64.deb -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
@kaihengfeng, I believe upstreaming the driver is the right thing to do, but I need to learn more about how in-tree drivers are written and submitted. Yes, I will try my best to upstreaming it. I will contact you when/if the driver is accepted. Thank you very much for your help. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
@kaihengfeng, I've sent the code to kernel.org and it's under review. In the meantime, I am keeping the code in my Github updated, so the users can download a pre-packaged DKMS deb file from it (or compile their own). -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
The keyboard has been tested in Ubuntu 16.04LTS kernel 4.4.0-34 x86_64 with the same behavior. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
I've managed to collect two PCAPNG files, one captured using virtualized Windows 7 and the second directly under Ubuntu 16.04LTS fully upgraded up to date. In both sessions, after initialization I pressed "a" key, then special key "G6". The "a" key makes four packets to be recorded. The "G6" special key generates six packets under Windows and only four packets under Linux (the first two packets that can be seen in the Windows dump never occur in Linux). After hitting "G6", the Windows session is fully responsive. But in the Linux session, the device stops responding until: a) is unplugged, then replugged. b) the USB is connected to the Windows Virtual Machine (VirtualBox), which resets the device and makes it responsive again. In the Windows dump, the last 10 packets correspond to the "a" keypress (4 packets) then "G6" keypress (6 packets). In the Linux dump, the last 8 packets correspond to the "a" keypress (4 packets), then "G6" keypress (only 4 packets). ** Attachment added: "PCAPNG dumps of keypress "a" then "G6" (Windows and Linux)" https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+attachment/4721381/+files/pcapng_dumps.zip -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
The keyboard was bought a few months ago and the bug have always been there. I've tried the keyboard both in upgraded systems and in fresh installations to no avail. Following your instructions, I have just tested it right now using the mainline kernel (at the URL you provided) and the bug is still showing, so I proceed with adding the tag 'kernel-bug-exists-upstream'. ** Tags added: kernel-bug-exists-upstream ** Changed in: linux (Ubuntu) Status: Incomplete => Confirmed -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] [NEW] USB keyboard stops working after pressing extended key
Public bug reported: USB keyboard Cougar K500 gaming keyboard has some additional extended keys, all of them making the keyboard stop responding if pressed under linux. The device is recovered only by unplugging the USB and plugging it again. The keyboard has been tested under Ubuntu 14.04.3 LTS, Ubuntu 15.04 and Ubuntu 15.10 (the latter running as virtualbox guest). All tests failed with exactly the same behaviour. USB ID is: "060b:500a Solid Year". ProblemType: Bug DistroRelease: Ubuntu 15.10 Package: linux-image-4.2.0-16-generic 4.2.0-16.19 [modified: boot/vmlinuz-4.2.0-16-generic] ProcVersionSignature: Ubuntu 4.2.0-16.19-generic 4.2.3 Uname: Linux 4.2.0-16-generic x86_64 ApportVersion: 2.19.1-0ubuntu3 Architecture: amd64 AudioDevicesInUse: USERPID ACCESS COMMAND /dev/snd/controlC0: pinfli 1055 F pulseaudio Date: Thu Oct 29 19:33:23 2015 HibernationDevice: RESUME=UUID=f68f4b91-ea68-4e4b-9a10-8ed5bca2efbe InstallationDate: Installed on 2015-10-24 (5 days ago) InstallationMedia: Ubuntu-GNOME 15.10 "Wily Werewolf" - Release amd64 (20151021) IwConfig: enp0s3no wireless extensions. lono wireless extensions. Lsusb: Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 002: ID 060b:500a Solid Year Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub MachineType: innotek GmbH VirtualBox ProcFB: ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.2.0-16-generic root=UUID=523dfd8b-b825-47e3-a116-cb85f901386c ro quiet splash PulseList: Error: command ['pacmd', 'list'] failed with exit code 1: No PulseAudio daemon running, or not running as session daemon. RelatedPackageVersions: linux-restricted-modules-4.2.0-16-generic N/A linux-backports-modules-4.2.0-16-generic N/A linux-firmware1.149 RfKill: SourcePackage: linux UdevLog: Error: [Errno 2] No such file or directory: '/var/log/udev' UpgradeStatus: No upgrade log present (probably fresh install) dmi.bios.date: 12/01/2006 dmi.bios.vendor: innotek GmbH dmi.bios.version: VirtualBox dmi.board.name: VirtualBox dmi.board.vendor: Oracle Corporation dmi.board.version: 1.2 dmi.chassis.type: 1 dmi.chassis.vendor: Oracle Corporation dmi.modalias: dmi:bvninnotekGmbH:bvrVirtualBox:bd12/01/2006:svninnotekGmbH:pnVirtualBox:pvr1.2:rvnOracleCorporation:rnVirtualBox:rvr1.2:cvnOracleCorporation:ct1:cvr: dmi.product.name: VirtualBox dmi.product.version: 1.2 dmi.sys.vendor: innotek GmbH ** Affects: linux (Ubuntu) Importance: Undecided Status: Confirmed ** Tags: amd64 apport-bug wily ** Attachment added: "USB sniffer session: keys pressed "asdfasdf", then one extended key to make the device stop responding" https://bugs.launchpad.net/bugs/1511511/+attachment/4508698/+files/cougar_k500_asdfasdf.pcapng -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1511511] Re: USB keyboard stops working after pressing extended key
Dmesg log info shows the folling: "hid-generic 0003:060B:500A.000A: usage index exceeded". I attach the device rdesc file, obtained from: cat /sys/kernel/debug/hid/0003:060B:500A.000A/rdesc ** Attachment added: "rdesc info obtained from cat /sys/kernel/debug/hid/:060B:500A./rdesc" https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+attachment/4508738/+files/cougar_k500_rdesc.txt -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1511511 Title: USB keyboard stops working after pressing extended key To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1511511/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs