Hello,
I am trying out KDE Plasma on FreeBSD. I use a USB switch to be able to switch between my desktop computer and my work laptop with the same mouse and keyboard.
The USB swith is connected to a mouse, a keyboard, a USB headset and a webcam.
When I switch from KDE FreeBSD on the desktop computer to the work computer, and then switch back, I don’t get mouse and keyboard input back.
Interestingly this problem doesn’t happen when using Windowmaker or in the loging manager SDDM.
This is the Xorg log when the problem doesn’t happen in Windomaker, we can see that Xorg detect the device disconnection and reconnection:
While in Plasma, no reconnection event is detected:
There is some interesting messages in dmesg:
It looks like that the disconnect event is being held for the USB headset, as the audio device is kept busy. This also holds the reconnect event from happening apparently.
When I kill Plasma by restarting SDDM, the audio device is disconnected, and then the USB devices reconnect is detected, even if I reconnected the swith 3 minutes before.
So in a nutshell, it looks like Plasma is keeping the USB device open, which blocks any new USB event from happening, thus blocking the reconnection event for the USB mouse and keyboard.
Any idea on how to solve that?
Thanks!
I am trying out KDE Plasma on FreeBSD. I use a USB switch to be able to switch between my desktop computer and my work laptop with the same mouse and keyboard.
The USB swith is connected to a mouse, a keyboard, a USB headset and a webcam.
When I switch from KDE FreeBSD on the desktop computer to the work computer, and then switch back, I don’t get mouse and keyboard input back.
Interestingly this problem doesn’t happen when using Windowmaker or in the loging manager SDDM.
This is the Xorg log when the problem doesn’t happen in Windomaker, we can see that Xorg detect the device disconnection and reconnection:
Code:
[ 1089.351] (II) config/udev: removing device Logitech USB Laser Mouse
[ 1089.351] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 13: device removed
[ 1089.352] (II) UnloadModule: "libinput"
[ 1089.352] (II) config/udev: removing device A4Tech LDLC AZERTY+
[ 1089.352] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 14: device removed
[ 1089.352] (II) UnloadModule: "libinput"
[ 1095.802] (II) config/udev: Adding input device Logitech USB Laser Mouse (/dev/input/event3)
[ 1095.802] (**) Logitech USB Laser Mouse: Applying InputClass "evdev pointer catchall"
[ 1095.802] (**) Logitech USB Laser Mouse: Applying InputClass "libinput pointer catchall"
[ 1095.802] (II) Using input driver 'libinput' for 'Logitech USB Laser Mouse'
[ 1095.802] (**) Logitech USB Laser Mouse: always reports core events
[ 1095.802] (**) Option "Device" "/dev/input/event3"
[ 1095.802] (**) Option "_source" "server/udev"
[ 1095.804] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 18: is tagged by udev as: Mouse
[ 1095.805] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 18: device is a pointer
[ 1095.805] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 18: device removed
[ 1095.806] (**) Option "config_info" "udev:/dev/input/event3"
[ 1095.806] (II) XINPUT: Adding extended input device "Logitech USB Laser Mouse" (type: MOUSE, id 9)
[ 1095.806] (**) Option "AccelerationScheme" "none"
[ 1095.806] (**) Logitech USB Laser Mouse: (accel) selected scheme none/0
[ 1095.806] (**) Logitech USB Laser Mouse: (accel) acceleration factor: 2.000
[ 1095.806] (**) Logitech USB Laser Mouse: (accel) acceleration threshold: 4
[ 1095.808] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 18: is tagged by udev as: Mouse
[ 1095.809] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 18: device is a pointer
[ 1096.400] (II) config/udev: Adding input device A4Tech LDLC AZERTY+ (/dev/input/event4)
[ 1096.400] (**) A4Tech LDLC AZERTY+: Applying InputClass "evdev keyboard catchall"
[ 1096.400] (**) A4Tech LDLC AZERTY+: Applying InputClass "Evdev keyboard"
[ 1096.400] (**) A4Tech LDLC AZERTY+: Applying InputClass "libinput keyboard catchall"
[ 1096.400] (**) A4Tech LDLC AZERTY+: Applying InputClass "system-keyboard"
[ 1096.400] (II) Using input driver 'libinput' for 'A4Tech LDLC AZERTY+'
[ 1096.400] (**) A4Tech LDLC AZERTY+: always reports core events
[ 1096.400] (**) Option "Device" "/dev/input/event4"
[ 1096.400] (**) Option "_source" "server/udev"
[ 1096.402] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 19: is tagged by udev as: Keyboard
[ 1096.403] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 19: device is a keyboard
[ 1096.403] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 19: device removed
[ 1096.404] (**) Option "config_info" "udev:/dev/input/event4"
[ 1096.404] (II) XINPUT: Adding extended input device "A4Tech LDLC AZERTY+" (type: KEYBOARD, id 10)
[ 1096.404] (**) Option "xkb_rules" "evdev"
[ 1096.404] (**) Option "xkb_layout" "fr"
[ 1096.404] (**) Option "xkb_variant" "afnor"
[ 1096.406] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 19: is tagged by udev as: Keyboard
[ 1096.407] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 19: device is a keyboard
While in Plasma, no reconnection event is detected:
Code:
[ 1241.569] (II) config/udev: removing device Logitech USB Laser Mouse
[ 1241.569] (II) event3 - Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 18: device removed
[ 1241.582] (II) UnloadModule: "libinput"
[ 1241.582] (II) config/udev: removing device A4Tech LDLC AZERTY+
[ 1241.582] (II) event4 - A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 19: device removed
[ 1241.584] (II) UnloadModule: "libinput"
There is some interesting messages in dmesg:
Code:
Apr 20 19:11:35 gen3 kernel: ugen0.2: <vendor 0x1a40 USB 2.0 Hub> at usbus0 (disconnected)
Apr 20 19:11:35 gen3 kernel: uhub1: at uhub0, port 9, addr 22 (disconnected)
Apr 20 19:11:35 gen3 kernel: ugen0.3: <Logitech USB Laser Mouse> at usbus0 (disconnected)
Apr 20 19:11:35 gen3 kernel: ums0: at uhub1, port 1, addr 23 (disconnected)
Apr 20 19:11:35 gen3 kernel: ums0: detached
Apr 20 19:11:35 gen3 kernel: ugen0.4: <A4Tech LDLC AZERTY+> at usbus0 (disconnected)
Apr 20 19:11:35 gen3 kernel: ukbd0: at uhub1, port 2, addr 24 (disconnected)
Apr 20 19:11:35 gen3 kernel: ukbd0: detached
Apr 20 19:11:35 gen3 kernel: uhid0: at uhub1, port 2, addr 24 (disconnected)
Apr 20 19:11:35 gen3 kernel: uhid0: detached
Apr 20 19:11:35 gen3 kernel: ugen0.5: <vendor 0x046d product 0x081b> at usbus0 (disconnected)
Apr 20 19:11:35 gen3 kernel: uaudio0: at uhub1, port 3, addr 25 (disconnected)
Apr 20 19:11:35 gen3 kernel: pcm7: unregister: mixer busy
Apr 20 19:11:35 gen3 kernel: pcm7: Waiting for sound application to exit!
Apr 20 19:11:37 gen3 kernel: pcm7: unregister: mixer busy
Apr 20 19:11:37 gen3 kernel: pcm7: Waiting for sound application to exit!
Apr 20 19:11:39 gen3 kernel: pcm7: unregister: mixer busy
Apr 20 19:16:44 gen3 kernel: pcm7: unregister: mixer busy
Apr 20 19:16:44 gen3 kernel: pcm7: Waiting for sound application to exit!
Apr 20 19:16:46 gen3 kernel: pcm7: unregister: mixer busy
Apr 20 19:16:46 gen3 kernel: pcm7: Waiting for sound application to exit!
Apr 20 19:16:48 gen3 kernel: pcm7: unregister: mixer busy
Apr 20 19:16:48 gen3 kernel: pcm7: Waiting for sound application to exit!
Apr 20 19:16:48 gen3 devd[73807]: notify_clients: send() failed; dropping unresponsive client
Apr 20 19:16:48 gen3 kernel: pid 37576 (kglobalaccel5), jid 0, uid 1001: exited on signal 6 (core dumped)
Apr 20 19:16:50 gen3 kernel: pid 38073 (drkonqi), jid 0, uid 1001: exited on signal 6 (core dumped)
Apr 20 19:16:50 gen3 kernel: pcm7: detached
Apr 20 19:16:50 gen3 kernel: uaudio0: detached
Apr 20 19:16:50 gen3 kernel: ugen0.6: <Creative Technology Creative USB Headset> at usbus0 (disconnected)
Apr 20 19:16:50 gen3 kernel: uaudio1: at uhub1, port 4, addr 26 (disconnected)
Apr 20 19:16:50 gen3 kernel: pcm8: detached
Apr 20 19:16:50 gen3 kernel: uaudio1: detached
Apr 20 19:16:50 gen3 kernel: uhid1: at uhub1, port 4, addr 26 (disconnected)
Apr 20 19:16:50 gen3 kernel: uhid1: detached
Apr 20 19:16:50 gen3 kernel: uhub1: detached
Apr 20 19:16:51 gen3 kernel: ugen0.2: <vendor 0x1a40 USB 2.0 Hub> at usbus0
Apr 20 19:16:51 gen3 kernel: uhub1 on uhub0
Apr 20 19:16:51 gen3 kernel: uhub1: <vendor 0x1a40 USB 2.0 Hub, class 9/0, rev 2.00/1.11, addr 27> on usbus0
Apr 20 19:16:52 gen3 kernel: uhub1: 4 ports with 4 removable, self powered
Apr 20 19:16:53 gen3 kernel: ugen0.3: <Logitech USB Laser Mouse> at usbus0
Apr 20 19:16:53 gen3 kernel: ums0 on uhub1
Apr 20 19:16:53 gen3 kernel: ums0: <Logitech USB Laser Mouse, class 0/0, rev 2.00/56.01, addr 28> on usbus0
Apr 20 19:16:53 gen3 kernel: ums0: 8 buttons and [XYZT] coordinates ID=0
Apr 20 19:16:53 gen3 kernel: ugen0.4: <A4Tech LDLC AZERTY+> at usbus0
Apr 20 19:16:53 gen3 kernel: ukbd0 on uhub1
Apr 20 19:16:53 gen3 kernel: ukbd0: <A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 29> on usbus0
Apr 20 19:16:53 gen3 kernel: kbd2 at ukbd0
Apr 20 19:16:53 gen3 kernel: uhid0 on uhub1
Apr 20 19:16:53 gen3 kernel: uhid0: <A4Tech LDLC AZERTY+, class 0/0, rev 2.00/1.05, addr 29> on usbus0
Apr 20 19:16:54 gen3 kernel: ugen0.5: <vendor 0x046d product 0x081b> at usbus0
Apr 20 19:16:54 gen3 kernel: uaudio0 on uhub1
Apr 20 19:16:54 gen3 kernel: uaudio0: <vendor 0x046d product 0x081b, class 239/2, rev 2.00/0.12, addr 30> on usbus0
Apr 20 19:16:54 gen3 kernel: uaudio0: No playback.
Apr 20 19:16:54 gen3 kernel: uaudio0: Record: 48000 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:54 gen3 kernel: uaudio0: Record: 32000 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:54 gen3 kernel: uaudio0: Record: 24000 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:54 gen3 kernel: uaudio0: Record: 16000 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:54 gen3 kernel: uaudio0: No MIDI sequencer.
Apr 20 19:16:54 gen3 kernel: pcm7: <USB audio> on uaudio0
Apr 20 19:16:54 gen3 kernel: uaudio0: No HID volume keys found.
Apr 20 19:16:55 gen3 kernel: ugen0.6: <Creative Technology Creative USB Headset> at usbus0
Apr 20 19:16:55 gen3 kernel: uaudio1 on uhub1
Apr 20 19:16:55 gen3 kernel: uaudio1: <Creative Technology Creative USB Headset, class 0/0, rev 2.00/1.10, addr 31> on usbus0
Apr 20 19:16:55 gen3 kernel: uaudio1: Play: 48000 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:55 gen3 kernel: uaudio1: Play: 44100 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:55 gen3 kernel: uaudio1: Record: 48000 Hz, 2 ch, 16-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:55 gen3 kernel: uaudio1: Record: 44100 Hz, 2 ch, 16-bit S-LE PCM format, 2x8ms buffer.
Apr 20 19:16:55 gen3 kernel: uaudio1: No MIDI sequencer.
Apr 20 19:16:55 gen3 kernel: pcm8: <USB audio> on uaudio1
Apr 20 19:16:55 gen3 kernel: uaudio1: HID volume keys found
It looks like that the disconnect event is being held for the USB headset, as the audio device is kept busy. This also holds the reconnect event from happening apparently.
When I kill Plasma by restarting SDDM, the audio device is disconnected, and then the USB devices reconnect is detected, even if I reconnected the swith 3 minutes before.
So in a nutshell, it looks like Plasma is keeping the USB device open, which blocks any new USB event from happening, thus blocking the reconnection event for the USB mouse and keyboard.
Any idea on how to solve that?
Thanks!