June 2017
Intermediate to advanced
478 pages
13h 14m
English
Before you suspend a device, you must have a method of waking it again. The kernel tries to help you here: if there is not at least one wakeup source, the system will refuse to suspend with the message:
No sources enabled to wake-up! Sleep abort.
Of course, this means that some parts of the system have to remain powered on even during the deepest sleep. This usually involves the Power Management IC (PMIC), the real-time clock (RTC), and may additionally include interfaces such as GPIO, UART, and Ethernet.
Wakeup events are controlled through sysfs. Each device in /sys/device has a subdirectory power containing a wakeup file that will contain one of these strings:
Read now
Unlock full access