我偶尔会出现奇怪的错误行为,我正在尝试在笔记本电脑上跟踪并解决该问题。
有时,有线 USB 输入设备(鼠标和键盘)在 Xorg XFCE 会话下停止工作。无论它们是否已通电,都没有一致性(例如,NumLock 和 CapsLock LED 可以点亮或不能点亮),但它们不会移动指针或输入文本,而内置键盘和触摸板则会移动指针或输入文本。不过,它们已列出lsusb
,如果我使用(内置键盘)AltCtrlF1转到 tty1,或者如果我在 tty8 中打开另一个图形用户会话,鼠标和键盘将按预期工作。
我使用的是带有 USB-C 扩展坞的笔记本电脑(我首先认为这会造成干扰,但无论是否通过扩展坞的 USB 集线器连接,情况都是如此,并且在拔掉插头时仍然存在)并且我正在运行 Debian Bullseye lightdm 下的 XFCE。当错误发生时,尝试service restart lightdm
仅恢复其中一台设备。在另一个 tty 中启动gdm3
3.38.2.1-1 时两个输入设备同时出现问题。降级lightdm
到稳定的 debian 版本 1.26.0-4 没有任何改变。重新启动系统(对于本例)确实使用 lightm/bullseye 恢复了两个设备。
编辑:过了好久,我又遇到这个问题了。两个外部设备均插入 USB-C 扩展坞,但似乎未通电,xinput
无法看到它们:
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ DELL0815:00 044E:120A Mouse id=14 [slave pointer (2)]
⎜ ↳ DELL0815:00 044E:120A Touchpad id=15 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Power Button id=6 [slave keyboard (3)]
↳ Video Bus id=7 [slave keyboard (3)]
↳ Power Button id=8 [slave keyboard (3)]
↳ Sleep Button id=9 [slave keyboard (3)]
↳ Integrated_Webcam_HD: Integrate id=13 [slave keyboard (3)]
↳ DELL0815:00 044E:120A UNKNOWN id=16 [slave keyboard (3)]
↳ Intel HID 5 button array id=17 [slave keyboard (3)]
↳ Intel HID events id=18 [slave keyboard (3)]
↳ Dell WMI hotkeys id=19 [slave keyboard (3)]
↳ AT Translated Set 2 keyboard id=20 [slave keyboard (3)]
然后 3 分钟后,我从扩展坞拔下其中一个(鼠标)并将其直接插入笔记本电脑,两者都突然激活,请参阅dmesg
:
[1184725.182186] usb 1-1: device not accepting address 37, error -71
[1184725.182343] usb usb1-port1: attempt power cycle
[1184725.266717] usb 2-1.2: reset SuperSpeed Gen 1 USB device number 9 using xhci_hcd
[1184725.287315] usb 2-1.2: Dell TB16 Dock, disable RX aggregation
[1184725.290078] r8152 2-1.2:1.0: firmware: failed to load rtl_nic/rtl8153a-3.fw (-2)
[1184725.290083] r8152 2-1.2:1.0: Direct firmware load for rtl_nic/rtl8153a-3.fw failed with error -2
[1184725.290087] r8152 2-1.2:1.0: unable to load firmware patch rtl_nic/rtl8153a-3.fw (-2)
[1184725.290227] r8152 2-1.2:1.0 (unnamed net_device) (uninitialized): Using pass-thru MAC addr e4:b9:7a:7f:5a:b6
[1184725.320675] r8152 2-1.2:1.0 eth0: v1.11.11
[1184725.626338] usb 1-1: new full-speed USB device number 38 using xhci_hcd
[1184725.626530] usb 1-1: Device not responding to setup address.
[1184725.834454] usb 1-1: Device not responding to setup address.
[1184726.042190] usb 1-1: device not accepting address 38, error -71
[1184726.170294] usb 1-1: new full-speed USB device number 39 using xhci_hcd
[1184726.170471] usb 1-1: Device not responding to setup address.
[1184726.378522] usb 1-1: Device not responding to setup address.
[1184726.586408] usb 1-1: device not accepting address 39, error -71
[1184726.586484] usb usb1-port1: unable to enumerate USB device
[1184726.620595] r8152 2-1.2:1.0 enxe4b97a7f5ab6: renamed from eth0
[1184728.395840] IPv6: ADDRCONF(NETDEV_CHANGE): enxe4b97a7f5ab6: link becomes ready
[1184728.396250] r8152 2-1.2:1.0 enxe4b97a7f5ab6: carrier on
[1184988.175205] r8152 2-1.2:1.0 enxe4b97a7f5ab6: carrier off
[1184991.337451] usb 1-1: new high-speed USB device number 40 using xhci_hcd
[1184991.486320] usb 1-1: New USB device found, idVendor=0424, idProduct=2807, bcdDevice= 2.04
[1184991.486326] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[1184991.486329] usb 1-1: Product: USB2807 Hub
[1184991.486332] usb 1-1: Manufacturer: Microchip
[1184991.487314] hub 1-1:1.0: USB hub found
[1184991.487380] hub 1-1:1.0: 7 ports detected
[1184991.531285] r8152 2-1.2:1.0 enxe4b97a7f5ab6: carrier on
[1184991.617517] usb 1-9: new low-speed USB device number 41 using xhci_hcd
[1184991.771119] usb 1-9: New USB device found, idVendor=413c, idProduct=2107, bcdDevice= 1.04
[1184991.771126] usb 1-9: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[1184991.771130] usb 1-9: Product: Dell USB Entry Keyboard
[1184991.771133] usb 1-9: Manufacturer: DELL
[1184991.775512] input: DELL Dell USB Entry Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-9/1-9:1.0/0003:413C:2107.0161/input/input325
[1184991.834188] hid-generic 0003:413C:2107.0161: input,hidraw1: USB HID v1.11 Keyboard [DELL Dell USB Entry Keyboard] on usb-0000:00:14.0-9/input0
[1184991.845377] usb 1-1.5: new high-speed USB device number 42 using xhci_hcd
[1184992.370896] r8152 2-1.2:1.0 enxe4b97a7f5ab6: carrier off
[1184992.405048] usb 1-1.5: New USB device found, idVendor=0bda, idProduct=4014, bcdDevice= 0.05
[1184992.405052] usb 1-1.5: New USB device strings: Mfr=3, Product=1, SerialNumber=2
[1184992.405055] usb 1-1.5: Product: USB Audio
[1184992.405058] usb 1-1.5: Manufacturer: Generic
[1184992.405060] usb 1-1.5: SerialNumber: 200901010001
[1184993.353588] usb 1-1.7: new low-speed USB device number 43 using xhci_hcd
[1184993.458257] usb 1-1.7: New USB device found, idVendor=0461, idProduct=4d17, bcdDevice= 2.00
[1184993.458264] usb 1-1.7: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[1184993.458268] usb 1-1.7: Product: USB Optical Mouse
[1184993.464432] input: USB Optical Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-1/1-1.7/1-1.7:1.0/0003:0461:4D17.0162/input/input326
[1184993.465105] hid-generic 0003:0461:4D17.0162: input,hidraw2: USB HID v1.11 Mouse [USB Optical Mouse] on usb-0000:00:14.0-1.7/input0
[1184996.010910] r8152 2-1.2:1.0 enxe4b97a7f5ab6: carrier on
并将xinput
它们添加到设备列表中:
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ DELL0815:00 044E:120A Mouse id=14 [slave pointer (2)]
⎜ ↳ DELL0815:00 044E:120A Touchpad id=15 [slave pointer (2)]
⎜ ↳ USB Optical Mouse id=11 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Power Button id=6 [slave keyboard (3)]
↳ Video Bus id=7 [slave keyboard (3)]
↳ Power Button id=8 [slave keyboard (3)]
↳ Sleep Button id=9 [slave keyboard (3)]
↳ Integrated_Webcam_HD: Integrate id=13 [slave keyboard (3)]
↳ DELL0815:00 044E:120A UNKNOWN id=16 [slave keyboard (3)]
↳ Intel HID 5 button array id=17 [slave keyboard (3)]
↳ Intel HID events id=18 [slave keyboard (3)]
↳ Dell WMI hotkeys id=19 [slave keyboard (3)]
↳ AT Translated Set 2 keyboard id=20 [slave keyboard (3)]
↳ DELL Dell USB Entry Keyboard id=10 [slave keyboard (3)]
在我看来,问题与错误相对应
[1184725.626338] usb 1-1: new full-speed USB device number 38 using xhci_hcd
[1184725.626530] usb 1-1: Device not responding to setup address.
[1184725.834454] usb 1-1: Device not responding to setup address.
[1184726.042190] usb 1-1: device not accepting address 38, error -71
在这种情况下,这似乎与以下事实相矛盾:在以前的设备中,设备是按lsusb
...列出的,我在这种情况下没有尝试过。