ACPI / PM: Add functions for manipulating lists of power resources
authorRafael J. Wysocki <rjw@sisk.pl>
Wed, 24 Nov 2010 23:06:09 +0000 (00:06 +0100)
committerLen Brown <len.brown@intel.com>
Wed, 12 Jan 2011 09:48:43 +0000 (04:48 -0500)
commitd2ef555b57292cd818934636ac8e3414cc2a6762
tree6fbe86ad458f20f146dbfb22d624052c644f9ac0
parent32a00d274e877eab3ea7ab196b75c9be5170d25e
ACPI / PM: Add functions for manipulating lists of power resources

ACPI device power resources should be reference counted during
device initialization, so that their reference counters are always
up to date.  It is convenient to do that with the help of a function
that will reference count and possibly turn on power resources in
a given list, so introduce that function, acpi_power_on_list().
For symmetry, introduce acpi_power_off_list() for performing the
reverse operation and use the both of them to simplify
acpi_power_transition().

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/acpi/power.c