]> git.karo-electronics.de Git - karo-tx-linux.git/commit
PM / Domains: Make it possible to use per-device domain callbacks
authorRafael J. Wysocki <rjw@sisk.pl>
Sun, 27 Nov 2011 12:11:36 +0000 (13:11 +0100)
committerRafael J. Wysocki <rjw@sisk.pl>
Sun, 27 Nov 2011 12:11:36 +0000 (13:11 +0100)
commit36751b10302863031264afcadac465a6da53f001
treee72b55a182a9bef3edc50e19de9750f85fdf0e62
parent7ffe56c4e30279d3d7d3cd48a956f882860864b6
PM / Domains: Make it possible to use per-device domain callbacks

The current generic PM domains code requires that the same .stop(),
.start() and .active_wakeup() device callback routines be used for
all devices in the given domain, which is inflexible and may not
cover some specific use cases.  For this reason, make it possible to
use device specific .start()/.stop() and .active_wakeup() callback
routines by adding corresponding callback pointers to struct
generic_pm_domain_data.  Add a new helper routine,
pm_genpd_register_callbacks(), that can be used to populate
the new per-device callback pointers.

Modify the shmobile's power domains code to allow drivers to add
their own code to be run during the device stop and start operations
with the help of the new callback pointers.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Magnus Damm <damm@opensource.se>
arch/arm/mach-shmobile/pm-sh7372.c
drivers/base/power/domain.c
include/linux/pm_domain.h