Not logged in
Log in now
Create an account
Subscribe to LWN
LWN.net Weekly Edition for May 23, 2013
An "enum" for Python 3
An unexpected perf feature
LWN.net Weekly Edition for May 16, 2013
A look at the PyPy 2.0 release
How are userspace apps notified of the change? There are lots of stuff they may want to do on suspend, such as flagging 'away' in jabber etc.
Major suspend changes
Posted Jul 4, 2006 15:06 UTC (Tue) by gdt (subscriber, #6284)
The kernel doesn't notify user space apps. There's no need. Something asked the kernel to go into suspend-to-RAM. That 'something' is in user space and can notify the applications.
As a concrete example, the 'something' might be a ACPI lid button. The action script for that can clean up user space before calling the kernel. I wouldn't worry about Jabber so much as saving and restoring the system time to/from the hardware clock, asking any DHCP client daemons to retry leases, etc.
Of course, it would be very nice if all the 'something's (ACPI, command line, GNOME/KDE) all used the same mechanism. And that's been a long-time area of failure in Linux.
Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds