Wired USB keyboard radomly disconnects

Edit: Forgot to add: I’m running Fedora 34 with XFCE.

I have a Cloud Nine Ego C989 keyboard (it’s a wired USB keyboard). After an update sometime around the beginning of the year, the keyboard now randomly disconnects are reconnects. The timing between disconnects appears to be random, between seconds and many minutes. This same keyboard has no issues on other systems. A different make and model keyboard has no issue on the same system.

I don’t know enough about USB subsystems to determine if there’s something I can roll back. I have tried the following:

  • Booting with old kernel - when it first started happening, I booted with the oldest kernel available. It did not make a difference.
  • Swapping USB ports - no difference
  • Disabling USB power management for the device - this is complicated by the fact that the keyboard gets assigned a new device id every time id reconnects, but I believe I did manage to accomplish this once, to no effect.

I believe the keyboard uses a Sonix controller. I’m also sure that there is a USB hub in the keyboard that handles an USB connector on the keyboard as well as some extra controls (note that there are six devices listed in the kernel messages). lsusb (output below) appears to list the keyboard as a camera… sort of. Typical kernel messages are also shown below.

I also added journalctl output. It appears the XFCE volume manager is trying to do something with the keyboard when it reconnects.

Questions

  1. Has anyone seen a similar problem before?
  2. Could the strange identification in lsusb be indicative of a problem?
  3. How can I identify if there’s something I can roll back? Like a driver or other configuration?

I sincerely appreciate any assistance in this matter.

lsusb output

Bus 003 Device 031: ID 0c45:8006 Microdia Dual Mode Camera (8006 VGA)
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x0c45 Microdia
  idProduct          0x8006 Dual Mode Camera (8006 VGA)
  bcdDevice            1.38
  iManufacturer           1 SONiX
  iProduct                2 USB-Keyboard
  iSerial                 0 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength       0x003b
    bNumInterfaces          2
    bConfigurationValue     1
    iConfiguration          0 
    bmAttributes         0xa0
      (Bus Powered)
      Remote Wakeup
    MaxPower              100mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         3 Human Interface Device
      bInterfaceSubClass      1 Boot Interface Subclass
      bInterfaceProtocol      1 Keyboard
      iInterface              0 
        HID Device Descriptor:
          bLength                 9
          bDescriptorType        33
          bcdHID               1.11
          bCountryCode            0 Not supported
          bNumDescriptors         1
          bDescriptorType        34 Report
          wDescriptorLength      79
         Report Descriptors: 
           ** UNAVAILABLE **
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0010  1x 16 bytes
        bInterval               1
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         3 Human Interface Device
      bInterfaceSubClass      1 Boot Interface Subclass
      bInterfaceProtocol      2 Mouse
      iInterface              0 
        HID Device Descriptor:
          bLength                 9
          bDescriptorType        33
          bcdHID               1.11
          bCountryCode            0 Not supported
          bNumDescriptors         1
          bDescriptorType        34 Report
          wDescriptorLength     259
         Report Descriptors: 
           ** UNAVAILABLE **
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0010  1x 16 bytes
        bInterval               1

dmesg output

[ 3689.106996] usb 3-7: USB disconnect, device number 28
[ 3689.107005] usb 3-7.4: USB disconnect, device number 29
[ 3689.498106] usb 3-7: new high-speed USB device number 30 using xhci_hcd
[ 3689.624365] usb 3-7: New USB device found, idVendor=1a40, idProduct=0101, bcdDevice= 1.11
[ 3689.624375] usb 3-7: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[ 3689.624378] usb 3-7: Product: USB 2.0 Hub
[ 3689.625548] hub 3-7:1.0: USB hub found
[ 3689.625593] hub 3-7:1.0: 4 ports detected
[ 3690.007114] usb 3-7.4: new full-speed USB device number 31 using xhci_hcd
[ 3690.196970] usb 3-7.4: New USB device found, idVendor=0c45, idProduct=8006, bcdDevice= 1.38
[ 3690.196980] usb 3-7.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 3690.196984] usb 3-7.4: Product: USB-Keyboard
[ 3690.196986] usb 3-7.4: Manufacturer: SONiX
[ 3690.203384] input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.0/0003:0C45:8006.001D/input/input108
[ 3690.255468] hid-generic 0003:0C45:8006.001D: input,hidraw2: USB HID v1.11 Keyboard [SONiX USB-Keyboard] on usb-0000:00:14.0-7.4/input0
[ 3690.257419] input: SONiX USB-Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.001E/input/input109
[ 3690.309293] input: SONiX USB-Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.001E/input/input110
[ 3690.309455] input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.001E/input/input111
[ 3690.309600] input: SONiX USB-Keyboard Mouse as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.001E/input/input112
[ 3690.309799] input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.001E/input/input113
[ 3690.309940] input: SONiX USB-Keyboard System Multi Axis as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.001E/input/input114
[ 3690.310286] hid-generic 0003:0C45:8006.001E: input,hiddev97,hidraw3: USB HID v1.11 Keyboard [SONiX USB-Keyboard] on usb-0000:00:14.0-7.4/input1
[ 3981.632339] usb 3-7: USB disconnect, device number 30
[ 3981.632349] usb 3-7.4: USB disconnect, device number 31
[ 3982.017730] usb 3-7: new high-speed USB device number 32 using xhci_hcd
[ 3982.144967] usb 3-7: New USB device found, idVendor=1a40, idProduct=0101, bcdDevice= 1.11
[ 3982.144976] usb 3-7: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[ 3982.144980] usb 3-7: Product: USB 2.0 Hub
[ 3982.146375] hub 3-7:1.0: USB hub found
[ 3982.146424] hub 3-7:1.0: 4 ports detected
[ 3982.528737] usb 3-7.4: new full-speed USB device number 33 using xhci_hcd
[ 3982.718447] usb 3-7.4: New USB device found, idVendor=0c45, idProduct=8006, bcdDevice= 1.38
[ 3982.718456] usb 3-7.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 3982.718460] usb 3-7.4: Product: USB-Keyboard
[ 3982.718463] usb 3-7.4: Manufacturer: SONiX
[ 3982.724706] input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.0/0003:0C45:8006.001F/input/input115
[ 3982.777219] hid-generic 0003:0C45:8006.001F: input,hidraw2: USB HID v1.11 Keyboard [SONiX USB-Keyboard] on usb-0000:00:14.0-7.4/input0
[ 3982.779425] input: SONiX USB-Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.0020/input/input116
[ 3982.830916] input: SONiX USB-Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.0020/input/input117
[ 3982.831078] input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.0020/input/input118
[ 3982.831228] input: SONiX USB-Keyboard Mouse as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.0020/input/input119
[ 3982.831437] input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.0020/input/input120
[ 3982.831580] input: SONiX USB-Keyboard System Multi Axis as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.0020/input/input121
[ 3982.832602] hid-generic 0003:0C45:8006.0020: input,hiddev97,hidraw3: USB HID v1.11 Keyboard [SONiX USB-Keyboard] on usb-0000:00:14.0-7.4/input1

journalctl output

Feb 01 09:49:33 brandon-fedora kernel: usb 3-7.4: new full-speed USB device number 61 using xhci_hcd
Feb 01 09:49:33 brandon-fedora kernel: usb 3-7.4: New USB device found, idVendor=0c45, idProduct=8006, bcdDevice= 1.38
Feb 01 09:49:33 brandon-fedora kernel: usb 3-7.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
Feb 01 09:49:33 brandon-fedora kernel: usb 3-7.4: Product: USB-Keyboard
Feb 01 09:49:33 brandon-fedora kernel: usb 3-7.4: Manufacturer: SONiX
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.0/0003:0C45:8006.003A/input/input207
Feb 01 09:49:33 brandon-fedora kernel: hid-generic 0003:0C45:8006.003A: input,hidraw2: USB HID v1.11 Keyboard [SONiX USB-Keyboard] on usb-0000:00:14.0-7.4/input0
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.003>
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.003B/>
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.003B/input/input210
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard Mouse as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.003B/input/inp>
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.003B/input/input212
Feb 01 09:49:33 brandon-fedora kernel: input: SONiX USB-Keyboard System Multi Axis as /devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4/3-7.4:1.1/0003:0C45:8006.00>
Feb 01 09:49:33 brandon-fedora kernel: hid-generic 0003:0C45:8006.003B: input,hiddev97,hidraw3: USB HID v1.11 Keyboard [SONiX USB-Keyboard] on usb-0000:00:14.0-7>
Feb 01 09:49:33 brandon-fedora mtp-probe[13157]: checking bus 3, device 61: "/sys/devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4"
Feb 01 09:49:33 brandon-fedora mtp-probe[13157]: bus: 3, device: 61 was not an MTP device
Feb 01 09:49:33 brandon-fedora upowerd[2021]: treating change event as add on /sys/devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4
Feb 01 09:49:33 brandon-fedora Thunar[13158]: thunar-volman: Unsupported USB device type "usb".
Feb 01 09:49:33 brandon-fedora systemd-logind[1128]: Watching system buttons on /dev/input/event5 (SONiX USB-Keyboard Consumer Control)
Feb 01 09:49:33 brandon-fedora systemd-logind[1128]: Watching system buttons on /dev/input/event6 (SONiX USB-Keyboard System Control)
Feb 01 09:49:33 brandon-fedora systemd-logind[1128]: Watching system buttons on /dev/input/event7 (SONiX USB-Keyboard)
Feb 01 09:49:33 brandon-fedora mtp-probe[13183]: checking bus 3, device 61: "/sys/devices/pci0000:00/0000:00:14.0/usb3/3-7/3-7.4"
Feb 01 09:49:33 brandon-fedora mtp-probe[13183]: bus: 3, device: 61 was not an MTP device
Feb 01 09:49:33 brandon-fedora Thunar[13174]: thunar-volman: Unsupported input device type "/dev/input/js0".
Feb 01 09:49:33 brandon-fedora Thunar[13188]: thunar-volman: Unsupported input device type "/dev/input/event10".
Feb 01 09:49:33 brandon-fedora Thunar[13192]: thunar-volman: Unsupported input device type "/dev/input/event9".
Feb 01 09:49:33 brandon-fedora Thunar[13196]: thunar-volman: Unsupported input device type "/dev/input/event7".
Feb 01 09:49:33 brandon-fedora Thunar[13200]: thunar-volman: Unsupported input device type "/dev/input/event8".
Feb 01 09:49:33 brandon-fedora Thunar[13204]: thunar-volman: Unsupported input device type "/dev/input/event6".
Feb 01 09:49:33 brandon-fedora Thunar[13208]: thunar-volman: Unsupported input device type "/dev/input/event5".
Feb 01 09:49:33 brandon-fedora Thunar[13220]: thunar-volman: Unsupported input device type "(null)".
Feb 01 09:49:34 brandon-fedora Thunar[13228]: thunar-volman: Unsupported input device type "(null)".
Feb 01 09:49:34 brandon-fedora Thunar[13232]: thunar-volman: Unsupported input device type "(null)".
Feb 01 09:49:34 brandon-fedora Thunar[13236]: thunar-volman: Unsupported input device type "(null)".
Feb 01 09:49:34 brandon-fedora Thunar[13244]: thunar-volman: Unsupported input device type "(null)".
Feb 01 09:49:34 brandon-fedora Thunar[13248]: thunar-volman: Unsupported USB device type "usbhid".
Feb 01 09:49:34 brandon-fedora Thunar[13252]: thunar-volman: Unsupported USB device type "usbhid".

1 Like

When a USB device is connected/disconnected, there should be a journal entry. See if you can locate the revelant entries.

They might provide more clues.

journalctl output is at the end of the first message. Nothing jumps out at me, not that I know what I’m looking for. There’s a bunch of thunar-volman: Unsupported input device type messages that come after the keyboard reconnecting (thunar-volman is the XKCE volume manager).

1 Like

I appear to have found the solution: it was a power issue.

I tested the setup on the same machine but with an older, different Linux OS and had the same disconnect issues. That lead me to think about USB power supply issues.

After plugging the keyboard into a powered USB hub, I no longer have any disconnects.

While this is the solution, I suspect it may still have something to do with drivers or firmware. It was too much of a coincidence that this started happening after a software update. I’m not sure, but I believe there is some software control over power delivered to a USB device (I remember seeing this somewhere…). I don’t know if this is in the driver, or generally in the firmware for the internal USB hub. Not sure if tha t should be a bug report or not, since it may be very difficult to duplicate.