Fwd: Using HAL to disable USB hub "wakeup" setting

Andrey Borzenkov arvidjaar at mail.ru
Fri Mar 20 08:39:30 PDT 2009


On 20 марта 2009 18:22:56 Dan Streetman wrote:
> Hello,
>
> I have a system unit (a couple different model types, actually) with
> a quirk that I think should be addressed in HAL and I wanted to see
> what you think.
>
> The system has integrated USB hubs, and when the system goes into
> S3/suspend, those USB hubs' ports are powered down completely.  Since
> Linux defaults to enable the "remote wakeup" for USB hubs, which
> causes a system wakeup from suspend when a USB device is disconnected
> (or connected), when the system is entering suspend and those hubs
> power down their ports, if there are any USB device(s) connected then
> the power loss causes a "disconnect" and thus the hubs immediately
> wake up the system.
>
> Since the hardware is hard-wired to drop power, the only way to fix
> it is to disable the "remote wakeup" for those hubs.  This seems like
> a perfect match into HAL, by just creating a policy to match on the
> system unit model type info and specific USB PCI info, and disable
> the USB wakeup for the appropriate USB hubs.
>
> My questions are, first, is this a good fit for HAL?  Or should it be
> done somewhere else?

I have been doing similar things in udev; something like

ACTION=="add" SUBSYSTEM=="usb" ATTR{product}=="OHCI Host Controller" 
ATTR{power/autosuspend}="0"

> If HAL is the right place to handle this I'll send a patch in.
>

Frankly, HAL seems to be overkill for a simple "echo".

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://lists.freedesktop.org/archives/hal/attachments/20090320/e856de14/attachment.pgp 


More information about the hal mailing list