projects/linux·commit 53ff7095

Merge git://git.infradead.org/battery-2.6

53ff7095 · Linus Torvalds <[email protected]> · 2010-01-12 21:13:06 -08:00

* git://git.infradead.org/battery-2.6:
  pmu_battery: Fix battery full reporting
Commit
53ff7095cce683813be075379160b8e4e6ea8b85
Parents
bb7d3f24 · d54e7929

Merge commit. Changes below are compared with the first parent: bb7d3f24.

Changes

1 files changed · +2 −0

FileStatusAddDelContent
drivers/power/pmu_battery.cmodified+2−0View file

drivers/power/pmu_battery.c

View file
diff --git a/drivers/power/pmu_battery.c b/drivers/power/pmu_battery.c
index 9346a86..9c87ad5 100644
--- a/drivers/power/pmu_battery.c
+++ b/drivers/power/pmu_battery.c
@@ -89,6 +89,8 @@ static int pmu_bat_get_property(struct power_supply *psy,
case POWER_SUPPLY_PROP_STATUS:
if (pbi->flags & PMU_BATT_CHARGING)
val->intval = POWER_SUPPLY_STATUS_CHARGING;
+ else if (pmu_power_flags & PMU_PWR_AC_PRESENT)
+ val->intval = POWER_SUPPLY_STATUS_FULL;
else
val->intval = POWER_SUPPLY_STATUS_DISCHARGING;
break;