summaryrefslogtreecommitdiff
path: root/drivers/regulator
diff options
context:
space:
mode:
authorMichał Mirosław <mirq-linux@rere.qmqm.pl>2013-02-01 19:40:17 (GMT)
committerMark Brown <broonie@opensource.wolfsonmicro.com>2013-02-04 18:38:06 (GMT)
commit896b65f3453d434983969e3ee7c254f4f8ba1424 (patch)
treedcbec2381f7c4394852f1abd831a177be07f4da4 /drivers/regulator
parenta451405fcdf4048aa46c80ede25b36eba27ba3ec (diff)
downloadlinux-896b65f3453d434983969e3ee7c254f4f8ba1424.tar.xz
regulator: show state for GPIO-controlled regulators
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/regulator')
-rw-r--r--drivers/regulator/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 2785843..6b3550a 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -3208,7 +3208,7 @@ static int add_regulator_attributes(struct regulator_dev *rdev)
if (status < 0)
return status;
}
- if (ops->is_enabled) {
+ if (rdev->ena_gpio || ops->is_enabled) {
status = device_create_file(dev, &dev_attr_state);
if (status < 0)
return status;