[linux-pm] [RFC] Tying sysfs "wakeup" file to platform-level handler

Deepak Saxena dsaxena at plexity.net
Mon Nov 24 13:09:49 PST 2008


On Nov 24 2008, at 15:57, Alan Stern was caught saying:
> Shouldn't these things be decided by the user and not by the kernel's 
> platform code?
> 
> So what you want is a way for userspace to know and react at the start 
> of a suspend, and a way for it to know the cause of the suspend.  Then 
> a daemon could be set to notice whenever a suspend is started, and it 
> could set all the various wakeup flags however the user wants.
> 

Ack. This is what we are already doing.  The decision on whether or 
not a device should wake us up from suspend is handle via OHM on the 
XO and we set the OLPC-specific flags in /sys/power/wakeup_events as 
there is no standard way to specify wakeup events from userland.

My proposal uses the existing sysfs interface to connect into a platform 
level handler that can set the appropriate low-level HW bits. The
decision of whether or not to enable the device's wakeup capability
would still be left to user space. 

~Deepak

-- 
 Deepak Saxena  http://www.greenbasement.info
   _____   __o  Kernel Hacker, One Laptop Per Child  (o>
------    -\<,  Give One Laptop, Get One Laptop      //\
 ----- ( )/ ( ) http://www.amazon.com/xo             V_/_
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


More information about the linux-pm mailing list