]> git.baikalelectronics.ru Git - kernel.git/commit
PM / Sleep: Mark devices involved in wakeup signaling during suspend
authorRafael J. Wysocki <rjw@sisk.pl>
Sun, 16 Oct 2011 21:34:36 +0000 (23:34 +0200)
committerRafael J. Wysocki <rjw@sisk.pl>
Fri, 21 Oct 2011 22:19:29 +0000 (00:19 +0200)
commitfc805e56ea7aa79d89bca9c7244703ce92dc7e45
treeb929bbc30d5e08b1ba4be980c473f9d594a42b58
parentb0393b6e235a4c2daebadebfd23cc55e2c2961d5
PM / Sleep: Mark devices involved in wakeup signaling during suspend

The generic PM domains code in drivers/base/power/domain.c has
to avoid powering off domains that provide power to wakeup devices
during system suspend.  Currently, however, this only works for
wakeup devices directly belonging to the given domain and not for
their children (or the children of their children and so on).
Thus, if there's a wakeup device whose parent belongs to a power
domain handled by the generic PM domains code, the domain will be
powered off during system suspend preventing the device from
signaling wakeup.

To address this problem introduce a device flag, power.wakeup_path,
that will be set during system suspend for all wakeup devices,
their parents, the parents of their parents and so on.  This way,
all wakeup paths in the device hierarchy will be marked and the
generic PM domains code will only need to avoid powering off
domains containing devices whose power.wakeup_path is set.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
drivers/base/power/domain.c
drivers/base/power/main.c
include/linux/pm.h