PM: Reference counting of power.subsys_data
authorRafael J. Wysocki <rjw@sisk.pl>
Thu, 25 Aug 2011 13:34:01 +0000 (15:34 +0200)
committerRafael J. Wysocki <rjw@sisk.pl>
Thu, 25 Aug 2011 13:34:01 +0000 (15:34 +0200)
commitef27bed1870dbd5fd363ff5ec51eebd5a695e277
treeef563bb07f259386fbe2477ec9a01e7ead011bcc
parent5c095a0e0d600d5a5a4207eaadabd18db46395ce
PM: Reference counting of power.subsys_data

Since the power.subsys_data device field will be used by multiple
filesystems, introduce a reference counting mechanism for it to avoid
freeing it prematurely or changing its value at a wrong time.

Make the PM clocks management code that currently is the only user of
power.subsys_data use the new reference counting.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
drivers/base/power/Makefile
drivers/base/power/clock_ops.c
drivers/base/power/common.c [new file with mode: 0644]
include/linux/pm.h