regulator: add get_status()
authorDavid Brownell <dbrownell@users.sourceforge.net>
Thu, 15 Jan 2009 07:03:17 +0000 (23:03 -0800)
committerLiam Girdwood <lrg@slimlogic.co.uk>
Tue, 31 Mar 2009 08:56:20 +0000 (09:56 +0100)
commit853116a10544206b6b2cf42ebc9d78fba2668888
treebc233aa343638575b36e300e863ce3d477374f57
parent93e14baa4494607efe81608725f591e3ba31e3c1
regulator: add get_status()

Based on previous LKML discussions:

 * Update docs for regulator sysfs class attributes to highlight
   the fact that all current attributes are intended to be control
   inputs, including notably "state" and "opmode" which previously
   implied otherwise.

 * Define a new regulator driver get_status() method, which is the
   first method reporting regulator outputs instead of inputs.
   It can report on/off and error status; or instead of simply
   "on", report the actual operating mode.

For the moment, this is a sysfs-only interface, not accessible to
regulator clients.  Such clients can use the current notification
interfaces to detect errors, if the regulator reports them.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Documentation/ABI/testing/sysfs-class-regulator
drivers/regulator/core.c
include/linux/regulator/driver.h