]> git.karo-electronics.de Git - karo-tx-linux.git/commit
PM / Domains: Move syscore flag from subsys data to struct device
authorRafael J. Wysocki <rjw@sisk.pl>
Sun, 5 Aug 2012 23:46:39 +0000 (01:46 +0200)
committerRafael J. Wysocki <rjw@sisk.pl>
Fri, 17 Aug 2012 17:38:47 +0000 (19:38 +0200)
commitee2dae755ab793b50f6b43026930566b0f55b52a
treea1c0fe941aedb17c46a0b603af02765222f1dce9
parent0213c5ef0f8fef83edc4d8f96a572369d598b3bb
PM / Domains: Move syscore flag from subsys data to struct device

The syscore device PM flag is used to mark the devices (belonging to
a PM domain) that should never be turned off, except for the system
core (syscore) suspend/hibernation and resume stages.  That flag is
stored in the device's struct pm_subsys_data object whose address is
available from struct device.  However, in some situations it may be
convenient to set that flag before the device is added to a PM
domain, so it is better to move it directly to the "power" member of
struct device.  Then, it can be checked by the routines in
drivers/base/power/runtime.c and drivers/base/power/main.c, which is
more straightforward.

This also reduces the number of dev_gpd_data() invocations in the
generic PM domains framework, so the overhead related to the syscore
flag is slightly smaller.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Magnus Damm <damm@opensource.se>
drivers/base/power/common.c
drivers/base/power/domain.c
drivers/base/power/main.c
drivers/base/power/runtime.c
drivers/clocksource/sh_cmt.c
drivers/clocksource/sh_mtu2.c
drivers/clocksource/sh_tmu.c
include/linux/pm.h
include/linux/pm_domain.h