summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas Saenz Julienne <nicolassaenzj@gmail.com>2015-03-08 20:21:20 +0100
committerSebastian Reichel <sre@kernel.org>2015-03-09 02:51:36 +0100
commit0595439a0a8740f776a0ae367a4c7f243add24ec (patch)
treee848e6443e8bddf36db178a7908b47b6e20ce9c8
parentab8500_fg.c: only request threaded IRQs when necessary (diff)
downloadlinux-0595439a0a8740f776a0ae367a4c7f243add24ec.tar.xz
linux-0595439a0a8740f776a0ae367a4c7f243add24ec.zip
power: generic-adc-battery: Fix power_supply_property returned value
The POWER_SUPPLY_PROP_STATUS case in gab_get_property() wasn't providing any value. Signed-off-by: Nicolas Saenz Julienne <nicolassaenzj@gmail.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
-rw-r--r--drivers/power/generic-adc-battery.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/power/generic-adc-battery.c b/drivers/power/generic-adc-battery.c
index d72733e4f93a..0a566ac3eefd 100644
--- a/drivers/power/generic-adc-battery.c
+++ b/drivers/power/generic-adc-battery.c
@@ -159,7 +159,7 @@ static int gab_get_property(struct power_supply *psy,
switch (psp) {
case POWER_SUPPLY_PROP_STATUS:
- gab_get_status(adc_bat);
+ val->intval = gab_get_status(adc_bat);
break;
case POWER_SUPPLY_PROP_CHARGE_EMPTY_DESIGN:
val->intval = 0;