I have an issue thats been bothering me since I switched from MS Windows
over two years ago. Windows used to completely power down my computer.
Shutting down from Linux leaves the USB ports powered, so a USB mouse/gamepad
just sits there and "glows" all night for no good reason. Very annoying.
I've been poking around google off-and-on for a solution ever since.
It seems that this occurs due to a "buggy" BIOS implementation that mostly
affects nForce chipset motherboards. (Mine is a Gigabyte GA-7N400-L nForce2)
Finally stumbled on a thread that spans almost two years (!!!)
but contains a workaround:
http://bugzilla.kernel.org/show_bug.cgi?id=5410
Applied the patch, recompiled. And IT WORKS!
USB ports power down just like they should. Awesome.
Here is the diff from my 2.6.21.5 tree:
Code:
--- ./drivers/usb/host/ohci-hcd.c.orig 2007-06-11 14:37:06.000000000 -0400
+++ ./drivers/usb/host/ohci-hcd.c 2008-04-03 22:56:53.000000000 -0400
@@ -361,7 +361,8 @@
static void ohci_usb_reset (struct ohci_hcd *ohci)
{
ohci->hc_control = ohci_readl (ohci, &ohci->regs->control);
- ohci->hc_control &= OHCI_CTRL_RWC;
+ /* ohci->hc_control &= OHCI_CTRL_RWC; */
+ ohci->hc_control &= (OHCI_CTRL_RWC | OHCI_CTRL_HCFS);
ohci_writel (ohci, ohci->hc_control, &ohci->regs->control);
}
I guess my question is, could you see any problem surfacing from using this patch?
From my limited understanding of what this patch does, it sounds safe.
I've only been running this kernel for a few days, zero problems so far.
Any thoughts/opinions would be appreciated.
I have to mention that Zenwalk 5.0 properly powers off the USB ports at shutdown.
Only distro that ever has. Thought that maybe the kernel version Zenwalk used
(2.6.24.2) had finally fixed this, so I compiled a vanilla 2.6.24.4 kernel
for Slackware. No luck, same issue. Not sure what Zenwalk did to fix the problem,
but they seem to have it solved.
Thanks!