Bug 49846 - upower reports "percentage: 0%" while laptop is AC-adapter-powered and battery is 100% charged
Summary: upower reports "percentage: 0%" while laptop is AC-adapter-powered and batter...
Status: RESOLVED NOTOURBUG
Alias: None
Product: upower
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Richard Hughes
QA Contact:
URL: https://bugs.launchpad.net/bugs/981212
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-12 10:06 UTC by Bob Bib
Modified: 2013-10-28 18:54 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
upower --monitor-detail (1.70 KB, text/plain)
2012-05-12 10:06 UTC, Bob Bib
Details
/sys/class/power_supply/BAT0/uevent (433 bytes, application/octet-stream)
2012-05-12 10:10 UTC, Bob Bib
Details
/sys/class/power_supply/BAT0/uevent (433 bytes, text/plain)
2012-05-12 10:12 UTC, Bob Bib
Details
/proc/acpi/battery/BAT0/info (437 bytes, text/plain)
2012-05-12 10:13 UTC, Bob Bib
Details
/proc/acpi/battery/BAT0/state (194 bytes, text/plain)
2012-05-12 10:15 UTC, Bob Bib
Details

Description Bob Bib 2012-05-12 10:06:39 UTC
Created attachment 61510 [details]
upower --monitor-detail

upower strangely reports "percentage: 0%" while laptop is AC-adapter-powered and battery is 100% charged

Ubuntu 12.04 LTS / amd64
Linux kernel version: Ubuntu 3.2.0-24.37-generic 3.2.14
upower 0.9.15-3git1
Comment 1 Bob Bib 2012-05-12 10:10:02 UTC
Created attachment 61511 [details]
/sys/class/power_supply/BAT0/uevent
Comment 2 Bob Bib 2012-05-12 10:12:10 UTC
Created attachment 61512 [details]
/sys/class/power_supply/BAT0/uevent
Comment 3 Bob Bib 2012-05-12 10:13:16 UTC
Created attachment 61513 [details]
/proc/acpi/battery/BAT0/info
Comment 4 Bob Bib 2012-05-12 10:15:21 UTC
Created attachment 61514 [details]
/proc/acpi/battery/BAT0/state
Comment 5 Bob Bib 2012-05-12 10:19:22 UTC
All attached files were taken with 100% charged battery and AC power supply connected.
Comment 6 Bastien Nocera 2013-10-12 22:46:02 UTC
>    energy:              0 Wh

What's the output of:
cat /sys/class/power_supply/BAT0/energy_now
?
Comment 7 Bob Bib 2013-10-13 01:37:56 UTC
Bastien Nocera:
> What's the output of:
> cat /sys/class/power_supply/BAT0/energy_now
> ?

Unfortunately, nothing meaningful:
$ cat /sys/class/power_supply/BAT0/energy_now
cat: /sys/class/power_supply/BAT0/energy_now: No such file or directory

It's the same laptop, but now slightly different distro:
Debian testing "jessie" / amd64
Linux 3.10.7 (3.10.7-1)
upower 0.9.21 (0.9.21-2)
Comment 8 Bastien Nocera 2013-10-13 07:04:45 UTC
The ACPI for that laptop seems pretty broken:
POWER_SUPPLY_CHARGE_NOW=-1000

You should report this as a bug against the kernel at bugzilla.kernel.org. The laptop lacks energy_* information.

Reopen this bug if the kernel developers think that this is actually a bug in UPower.
Comment 9 Mike C 2013-10-28 18:54:05 UTC
It turns out that this was indeed a bug in upower and is resolved in arch linux package upower version 0.9.23-2

The upstream report for this is at https://bugs.freedesktop.org/show_bug.cgi?id=70952

So this I believe is now fully resolved with the latest upower version.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.