USB, Help, Keyboard being dropped
(no need to CC I'm subscribed to list), Hello, My USB keyboard is being dropped by the kernel at various times and I cannot figure out how to fix this. Maybe I have messed up somewhere but I think I'm reading the documents right. :) I'm using a recent Debian kernel and running Debian Testing/Unstable but the kernel is coming from Experimental. Linux ant 4.17.0-rc3-amd64 #1 SMP Debian 4.17~rc3-1~exp1 (2018-04-29) x86_64 GNU/Linux And I've also tried kernel straight from Linus tree, doesn't seem to be any different. I've also made sure the keyboard is plugged into various USB ports and of versions both 2.0 and 3.1 and also tried changing through the bios any legacy and handoff settings to verify that they didn't solve this problem. I've captured logs from journalctl and udevadm which makes me think that this is coming from the kernel (they are at the end). If it helps I have a combined log from the console captured by script command. I've tried setting kernel parameters for power control in sys/bus/usb and sys/bus/hid to stop any autosuspend and I've used the usbhid.quirks in my kernel boot parameters like: net.ifnames=0 usbhid.quirks=0x17f6:0x0830:0x0400 I've also made sure that udev has rules like: ACTION=="add|change", SUBSYSTEM=="usb", ATTR{idVendor}=="17f6", ATTR{idProduct}=="0830", TEST=="power/control", ATTR{power/control}="on" ACTION=="add|change", SUBSYSTEM=="usb", ATTR{idVendor}=="17f6", ATTR{idProduct}=="0830", TEST=="power/autosuspend_delay_ms", ATTR{power/autosuspend_delay_ms}="-1" and the following script shows they seem to be set: - echo -e "\nDev\tControl\tMs\tProduct\n" for d in /sys/bus/usb/devices/[0-9]* ; do if [[ -e $d/product ]] ; then echo -e "`basename $d`\t`cat $d/power/control`\t`cat $d/power/autosuspend_delay_ms`\t`cat $d/product`" ; fi ; done echo -e "\nDev\tControl\n" for d in /sys/bus/hid/devices/[0-9]* ; do echo -e "`basename $d`\t`cat $d/power/control`" ; done - Dev Control Ms Product 1-12on 20002.4G Mouse 1-4 on 2000DeskJet 930C 1-5 on 2000ASC495 Speakers 1-6 on -1 Ruffian6_x Kbrd v3_16 1-8 on 2000Cruzer Glide Dev Control 0003:17F6:0830.0002 auto 0003:1EA7:0064.0001 auto - lsusb finds device fine: Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 001 Device 005: ID 0781:5575 SanDisk Corp. Bus 001 Device 007: ID 17f6:0830 Unicomp, Inc Bus 001 Device 003: ID 04d2:ff05 Altec Lansing Technologies ADA-305 Speakers Bus 001 Device 002: ID 03f0:1204 Hewlett-Packard DeskJet 930c Bus 001 Device 006: ID 1ea7:0064 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub lsmod says: Module Size Used by cpufreq_powersave 16384 0 cpufreq_userspace 16384 0 cpufreq_conservative16384 0 usblp 24576 0 snd_hda_codec_hdmi 57344 1 nls_ascii 16384 2 nls_cp437 20480 2 snd_hda_codec_realtek 106496 1 vfat 24576 2 intel_rapl 24576 0 snd_hda_codec_generic86016 1 snd_hda_codec_realtek fat77824 1 vfat x86_pkg_temp_thermal16384 0 intel_powerclamp 16384 0 snd_hda_intel 45056 3 kvm_intel 233472 0 snd_hda_codec 151552 4 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek snd_usb_audio 229376 0 snd_usbmidi_lib36864 1 snd_usb_audio kvm 724992 1 kvm_intel snd_hda_core 94208 5 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek mxm_wmi16384 0 snd_rawmidi40960 1 snd_usbmidi_lib irqbypass 16384 1 kvm crct10dif_pclmul 16384 0 crc32_pclmul 16384 0 snd_seq_device 16384 1 snd_rawmidi snd_hwdep 16384 2 snd_usb_audio,snd_hda_codec snd_pcm 118784 5 snd_hda_codec_hdmi,snd_hda_intel,snd_usb_audio,snd_hda_codec,snd_hda_core ghash_clmulni_intel16384 0 i915 1708032 4 efi_pstore 16384 0 intel_cstate 16384 0 intel_uncore 131072 0 evdev 28672 6 snd_timer 36864 1 snd_pcm mei_me 45056 0 snd94208 18 snd_hda_codec_generic,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_usb_audio,snd_usbmidi_lib,snd_hda_codec,snd_hda_codec_realtek,snd_timer,snd_pcm,snd_rawmidi iTCO_wdt 16384 0 drm_kms_helper200704 1 i915 joydev 24576 0 int
Re: USB, Help, Keyboard being dropped
Did I not say it right? Or perhaps a kernel or some other issue? = (no need to CC I'm subscribed to list), Hello, My USB keyboard is being dropped by the kernel at various times and I cannot figure out how to fix this. Maybe I have messed up somewhere but I think I'm reading the documents right. :) I'm using a recent Debian kernel and running Debian Testing/Unstable but the kernel is coming from Experimental. Linux ant 4.17.0-rc3-amd64 #1 SMP Debian 4.17~rc3-1~exp1 (2018-04-29) x86_64 GNU/Linux And I've also tried kernel straight from Linus tree, doesn't seem to be any different. I've also made sure the keyboard is plugged into various USB ports and of versions both 2.0 and 3.1 and also tried changing through the bios any legacy and handoff settings to verify that they didn't solve this problem. I've captured logs from journalctl and udevadm which makes me think that this is coming from the kernel (they are at the end). If it helps I have a combined log from the console captured by script command. I've tried setting kernel parameters for power control in sys/bus/usb and sys/bus/hid to stop any autosuspend and I've used the usbhid.quirks in my kernel boot parameters like: net.ifnames=0 usbhid.quirks=0x17f6:0x0830:0x0400 I've also made sure that udev has rules like: ACTION=="add|change", SUBSYSTEM=="usb", ATTR{idVendor}=="17f6", ATTR{idProduct}=="0830", TEST=="power/control", ATTR{power/control}="on" ACTION=="add|change", SUBSYSTEM=="usb", ATTR{idVendor}=="17f6", ATTR{idProduct}=="0830", TEST=="power/autosuspend_delay_ms", ATTR{power/autosuspend_delay_ms}="-1" and the following script shows they seem to be set: - echo -e "\nDev\tControl\tMs\tProduct\n" for d in /sys/bus/usb/devices/[0-9]* ; do if [[ -e $d/product ]] ; then echo -e "`basename $d`\t`cat $d/power/control`\t`cat $d/power/autosuspend_delay_ms`\t`cat $d/product`" ; fi ; done echo -e "\nDev\tControl\n" for d in /sys/bus/hid/devices/[0-9]* ; do echo -e "`basename $d`\t`cat $d/power/control`" ; done - Dev Control Ms Product 1-12on 20002.4G Mouse 1-4 on 2000DeskJet 930C 1-5 on 2000ASC495 Speakers 1-6 on -1 Ruffian6_x Kbrd v3_16 1-8 on 2000Cruzer Glide Dev Control 0003:17F6:0830.0002 auto 0003:1EA7:0064.0001 auto - lsusb finds device fine: Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 001 Device 005: ID 0781:5575 SanDisk Corp. Bus 001 Device 007: ID 17f6:0830 Unicomp, Inc Bus 001 Device 003: ID 04d2:ff05 Altec Lansing Technologies ADA-305 Speakers Bus 001 Device 002: ID 03f0:1204 Hewlett-Packard DeskJet 930c Bus 001 Device 006: ID 1ea7:0064 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub lsmod says: Module Size Used by cpufreq_powersave 16384 0 cpufreq_userspace 16384 0 cpufreq_conservative16384 0 usblp 24576 0 snd_hda_codec_hdmi 57344 1 nls_ascii 16384 2 nls_cp437 20480 2 snd_hda_codec_realtek 106496 1 vfat 24576 2 intel_rapl 24576 0 snd_hda_codec_generic86016 1 snd_hda_codec_realtek fat77824 1 vfat x86_pkg_temp_thermal16384 0 intel_powerclamp 16384 0 snd_hda_intel 45056 3 kvm_intel 233472 0 snd_hda_codec 151552 4 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek snd_usb_audio 229376 0 snd_usbmidi_lib36864 1 snd_usb_audio kvm 724992 1 kvm_intel snd_hda_core 94208 5 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek mxm_wmi16384 0 snd_rawmidi40960 1 snd_usbmidi_lib irqbypass 16384 1 kvm crct10dif_pclmul 16384 0 crc32_pclmul 16384 0 snd_seq_device 16384 1 snd_rawmidi snd_hwdep 16384 2 snd_usb_audio,snd_hda_codec snd_pcm 118784 5 snd_hda_codec_hdmi,snd_hda_intel,snd_usb_audio,snd_hda_codec,snd_hda_core ghash_clmulni_intel16384 0 i915 1708032 4 efi_pstore 16384 0 intel_cstate 16384 0 intel_uncore 131072 0 evdev 28672 6 snd_timer 36864 1 snd_pcm mei_me 45056 0 snd94208 18 snd_hda_codec_generic,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_usb_audio,snd_usbmidi_lib,snd_hda_codec,snd_hda_codec_realtek,snd_timer,snd_pcm,snd_rawmidi iTCO_wdt 16384 0 dr
Re: USB, Help, Keyboard being dropped
On Fri, May 18, 2018 at 08:41:28AM +0200, Greg KH wrote: > On Thu, May 17, 2018 at 01:43:35PM -0400, ant wrote: > > > > Did I not say it right? > > > > Or perhaps a kernel or some other issue? > > > > > > = > > > > > > (no need to CC I'm subscribed to list), hi, thank you for replying, ... > What do you mean exactly by "dropped"? the keyboard stops working at various times. i may be in the middle of typing and it no longer shows anything happening, sometimes it will eventually reconnect and other times it will not (at which point i have to unplug it and plug it back in). > The kernel log you posted > doesn't show any USB devices going away, so it's a bit hard to know if > the kernel really thought the device is gone, or the device just stopped > working, right? i thought that the following lines showed the change started coming from the kernel: KERNEL[8256.344251] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.000B/input/inpu t27/input27::numlock (leds) which after some moments eventually ends up with: UDEV [8256.414787] unbind /devices/pci:00/:00:14.0/usb1/1-6 (usb) UDEV [8256.416250] remove /devices/pci:00/:00:14.0/usb1/1-6 (usb) [ 8256.041205] ant kernel: usb 1-6: USB disconnect, device number 16 which to me looks like a USB device being disconnected? i'd be happy for any way to tell the kernel to not do this as any kind of temporary|permanent workaround. i don't have any power keys on the keyboard. i tried reading up on X configuration and input and disabling things via X11, but i've not gotten very far down that road. i also tried installing laptop power tools and turning things off via that but because this is a desktop i don't think it made any difference, keyboard still stops working at times. > Does this keyboard work properly on other machines / operating systems? it worked with my previous machine with no issues, but that machine is gone as of February. i was also running Debian testing and Debian stable (on a 2nd partition) on that system. i have used Linus's stock kernel to boot from a USB stick and the issue is there too (v4.17-rc3), my connection isn't that fast so grabbing other images isn't quick but if i can get them and boot from a USB stick i'll do it if it helps. i haven't compiled the lastest rc5 or tried that yet. i didn't think you'd care too much about a report from Debian stable, but i finally got that installed and booting. i can leave that running today while i'm working on other things and see what the logs say. ant -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: USB, Help, Keyboard being dropped
On Fri, May 18, 2018 at 01:57:20PM +0200, Greg KH wrote: > On Fri, May 18, 2018 at 07:17:42AM -0400, ant wrote: > > On Fri, May 18, 2018 at 08:41:28AM +0200, Greg KH wrote: > > > On Thu, May 17, 2018 at 01:43:35PM -0400, ant wrote: > > > > > > > > Did I not say it right? > > > > > > > > Or perhaps a kernel or some other issue? > > > > > > > > > > > > = > > > > > > > > > > > > (no need to CC I'm subscribed to list), > > > > hi, thank you for replying, > > > > > > ... > > > What do you mean exactly by "dropped"? > > > > the keyboard stops working at various times. > > i may be in the middle of typing and it no > > longer shows anything happening, sometimes it > > will eventually reconnect and other times it > > will not (at which point i have to unplug it > > and plug it back in). > > > > > > > The kernel log you posted > > > doesn't show any USB devices going away, so it's a bit hard to know if > > > the kernel really thought the device is gone, or the device just stopped > > > working, right? > > > > i thought that the following lines showed the change > > started coming from the kernel: > > > > KERNEL[8256.344251] change > > /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.000B/input/inpu > > t27/input27::numlock (leds) > > > > which after some moments eventually ends up with: > > UDEV [8256.414787] unbind /devices/pci:00/:00:14.0/usb1/1-6 (usb) > > UDEV [8256.416250] remove /devices/pci:00/:00:14.0/usb1/1-6 (usb) > > [ 8256.041205] ant kernel: usb 1-6: USB disconnect, device number 16 > > > > which to me looks like a USB device being disconnected? > > > > i'd be happy for any way to tell the kernel to not do > > this as any kind of temporary|permanent workaround. i don't > > have any power keys on the keyboard. > > It's not up to the kernel to "not disconnect" a device, that's an > electrical thing, it is only responding to the state of the hardware as > told to it. So this might be an electrical issue with your keyboard, > the USB connector it is plugged into, any USB hubs or cables along the > way, or anything like that. the same cabling as before, plugged into USB2.0 or USB3.1 ports doesn't make any change, booting USB legacy modes, no change, booting system in bios mode, no change, PS2 emulation no change. the cable is not being moved at all at times and the problem still happens. hubs and devices found seem common and i'm not having any issues with any other USB devices. i did look around on the web to see if others were having troubles with this keyboard and motherboard and didn't find any. it's not a very old keyboard, but old enough that i'm pretty sure it's past any burn-in period where i'd suspect the electronics. me@ant(1)~$ lsusb Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 002: ID 174c:3074 ASMedia Technology Inc. ASM1074 SuperSpeed hub Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 001 Device 006: ID 0781:5575 SanDisk Corp. Bus 001 Device 005: ID 17f6:0830 Unicomp, Inc Bus 001 Device 004: ID 04d2:ff05 Altec Lansing Technologies ADA-305 Speakers Bus 001 Device 003: ID 03f0:1204 Hewlett-Packard DeskJet 930c Bus 001 Device 002: ID 174c:2074 ASMedia Technology Inc. ASM1074 High-Speed hub Bus 001 Device 007: ID 1ea7:0064 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub me@ant(2)~$ lspci 00:00.0 Host bridge: Intel Corporation Intel Kaby Lake Host Bridge (rev 05) 00:02.0 VGA compatible controller: Intel Corporation HD Graphics 630 (rev 04) 00:14.0 USB controller: Intel Corporation 200 Series PCH USB 3.0 xHCI Controller 00:14.2 Signal processing controller: Intel Corporation 200 Series PCH Thermal Subsystem 00:16.0 Communication controller: Intel Corporation 200 Series PCH CSME HECI 00:17.0 SATA controller: Intel Corporation 200 Series PCH SATA controller [AHCI mode] 00:1b.0 PCI bridge: Intel Corporation 200 Series PCH PCI Express Root Port (rev f0) 00:1c.0 PCI bridge: Intel Corporation 200 Series PCH PCI Express Root Port (rev f0) 00:1c.1 PCI bridge: Intel Corporation 200 Series PCH PCI Express Root Port (rev f0) 00:1c.4 PCI bridge: Intel Corporation 200 Series PCH PCI Express Root Port (rev f0) 00:1d.0 PCI bridge: Intel Corporation 200 Series PCH PCI Express Root Port (rev f0) 00:1f.0 ISA bridge: Intel Corporation 200 Series PCH LPC Controller (Z270) 00:1f.2 Memory controller: Int
Re: USB, Help, Keyboard being dropped
On Fri, May 18, 2018 at 01:57:20PM +0200, Greg KH wrote: > ant wrote: ... > > i didn't think you'd care too much about a report > > from Debian stable, but i finally got that installed > > and booting. i can leave that running today while > > i'm working on other things and see what the logs > > say. > > If it works on the same hardware with a different kernel, yes, that is > interesting to know. hi, no luck, keyboard/system wasn't touched during entire time once the logs were set up to track until i came in a while ago: Script started on Fri 18 May 2018 09:40:24 AM EDT root@anto(1)~# journalctl -f -o short-monotonic | tee jrnl-log & [1] 980 root@anto(2)~# -- Logs begin at Fri 2018-05-18 09:33:45 EDT. -- ... root@anto(2)~# udevadm monitor -k -u | tee udev-log & [2] 982 root@anto(3)~# monitor will print the received events for: UDEV - the event which udev sends out after rule processing KERNEL - the kernel uevent ... root@anto(5)~# [ 910.372140] anto systemd[1]: Starting Cleanup of Temporary Directories... [ 910.383094] anto systemd[1]: Started Cleanup of Temporary Directories. [ 1696.872987] anto systemd[1]: Started Run anacron jobs. [ 1696.878216] anto anacron[1001]: Anacron 2.3 started on 2018-05-18 [ 1696.879521] anto anacron[1001]: Normal exit (0 jobs run) [ 1696.879959] anto systemd[1]: anacron.timer: Adding 4min 10.454254s random time. KERNEL[2078.484239] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::numlock (leds) KERNEL[2078.484313] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::numlock (leds) KERNEL[2078.484361] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::capslock (leds) KERNEL[2078.484395] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::capslock (leds) KERNEL[2078.484436] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::scrolllock (leds) KERNEL[2078.484466] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::scrolllock (leds) KERNEL[2078.484487] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::compose (leds) KERNEL[2078.484514] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::kana (leds) KERNEL[2078.484536] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::kana (leds) UDEV [2078.487645] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::numlock (leds) UDEV [2078.489387] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::capslock (leds) UDEV [2078.489824] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::numlock (leds) UDEV [2078.489839] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::compose (leds) UDEV [2078.489850] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::scrolllock (leds) UDEV [2078.490032] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::capslock (leds) UDEV [2078.490170] change /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::kana (leds) UDEV [2078.490256] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::scrolllock (leds) UDEV [2078.490561] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/input19::kana (leds) KERNEL[2078.512355] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/event16 (input) UDEV [2078.515258] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19/event16 (input) KERNEL[2078.544334] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19 (input) KERNEL[2078.544402] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/hidraw/hidraw1 (hidraw) KERNEL[2078.544465] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002 (hid) KERNEL[2078.544537] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0 (usb) KERNEL[2078.545109] remove /devices/pci:00/:00:14.0/usb1/1-6 (usb) UDEV [2078.546837] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/input/input19 (input) UDEV [2078.547436] remove /devices/pci:00/:00:14.0/usb1/1-6/1-6:1.0/0003:17F6:0830.0002/hidraw/hidraw1 (hidraw) UDEV [20
[FIXED]: Re: USB, Help, Keyboard being dropped
On Fri, May 18, 2018 at 08:41:28AM +0200, Greg KH wrote: ... > Does this keyboard work properly on other machines / operating systems? it is a hardware problem. figures that keyboard is now one month past warranty. i had a previous keyboard of same type and it was having troubles on the old machine so i replaced it. it happens to be running the same version of the software as the newer one and is the same keyboard otherwise. so i dug it out of the closet and used it yesterday and today and no problems with it so far. thanks for your help, sorry for the noise. ant -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html