LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 01-19-2025, 05:32 PM   #1
AWildMagikarpAppeared
LQ Newbie
 
Registered: Jan 2025
Posts: 1

Rep: Reputation: 0
USB Adapter ceases to work after system sleep


On Ubuntu 24.04 I'm having an issue where an USB adapter for an RF Wireless Keyboard seems to stop working altogether after a system sleep (inactivity), without actually being disconnected. The moment i wake up the system after it has been in sleep mode, all USB connections seem to regain activity but this one. In short, i have to disconnect and reconnect it every time. It's not a huge hassle, but an inconvenience nonetheless so I'd like to figure out how to go about fixing this.

Dmesg does not show the USB adapter being disconnected, such as this:
Code:
usb #-#.#.#: USB disconnect, device number #
The USB hub also doesn't seem to stop delivering power to the USB adapter in question.

I have done some digging on the Linux Kernel (and USB buses), and while learning some new things about how it works, i haven't actually come closer to a solution. Ideally i'd like to see if there is such a thing as a driver-exclusive log (as the USB adapter is handled by usbhid), so i can see exactly what is happening to cause it to stop working.

Could someone point me in the right direction?

Last edited by AWildMagikarpAppeared; 01-19-2025 at 05:34 PM.
 
Old 01-21-2025, 02:31 AM   #2
lvm_
Senior Member
 
Registered: Jul 2020
Posts: 1,396

Rep: Reputation: 467Reputation: 467Reputation: 467Reputation: 467Reputation: 467
Don't know how to prevent this, but resetting it with 'usb_modeswitch -R' from a wake-up script or rather systemd service might help.
 
1 members found this post helpful.
Old 01-21-2025, 09:05 AM   #3
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,299

Rep: Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675Reputation: 3675
I think the issue is that many computers power off the usb port(s) on some sleep states. Not sure if you can change that in bios. I have a few computers that have special (yellow??) usb ports that are claimed to remain powered even when power switch is off.

I think that the above suggestion in some form ought to work. Make some trigger to then issue some command. If you can't get a trigger, then run some loop that detects if or then.

Might be that the connectionless state of the port is also the problem.
 
Old 01-25-2025, 05:21 AM   #4
lvm_
Senior Member
 
Registered: Jul 2020
Posts: 1,396

Rep: Reputation: 467Reputation: 467Reputation: 467Reputation: 467Reputation: 467
Quote:
Originally Posted by jefro View Post
I think the issue is that many computers power off the usb port(s) on some sleep states.
Good idea, but if it is the cause, it's probably the other way around: port remains powered and the dongle, not detecting any signals, shuts down after a while. So the OP should try disabling in BIOS USB power while sleeping or plug the dongle into an unpowered port.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Transmission bit-torrent client ceases downloading after two or three minutes grumpyskeptic Linux - Software 11 08-24-2021 01:44 AM
LXer: IBM Ceases Work on Server-Side Swift Development LXer Syndicated Linux News 0 01-21-2020 12:02 PM
OpenOffice Math Ceases to Cause Symbols to Be Rendered after RHEL Up-Date Oeconomist Linux - Software 0 12-14-2010 09:47 AM
firefox ceases to function infamous41md Linux - Software 11 10-18-2005 03:53 PM
Linux never ceases to amaze me. DigitalTygrrr LinuxQuestions.org Member Success Stories 5 09-26-2003 04:24 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 06:17 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration