summaryrefslogtreecommitdiff
path: root/arch/um
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <k.kozlowski@samsung.com>2015-03-12 08:44:13 +0100
committerSebastian Reichel <sre@kernel.org>2015-03-13 23:15:52 +0100
commit03e81acce5568c7105dc5bef6984c8b0edfe8d45 (patch)
tree5a23f5c2245e9d4f170e644e2050638c225b51a1 /arch/um
parent1a352462b5377ac68f5955d674b3460c7bac52a3 (diff)
power_supply: Increment power supply use counter when obtaining references
Increment the power_supply.use_cnt usage counter on: - power_supply_get_by_phandle() - power_supply_get_by_name() and decrement it on power_supply_put() call. This helps tracking of valid usage of power supply instance by consumers. The usage counter itself also allows safe calling of power_supply_get_property-like functions even when driver unregisters this power supply. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
Diffstat (limited to 'arch/um')
0 files changed, 0 insertions, 0 deletions