Patch submission for incorrect battery %

mark ellis m at rkellis.com
Sun Feb 10 01:58:01 PST 2013


Hello,

First off I'm sorry if this is not clear, but it's a little hard to explain!

I have a very dodgy batter in my laptop that sometimes likes to lie about
how much energy it's currently containing, or what it's charge_full and
charge_full_design are. It only does this briefly, for a split second or
so, but it's enough to mess up upower, which will start reporting 3% charge
remaining, 5 hours left on a full battery (energy-full ends up really high
for no reason, e.g. instead of 48Wh, it'll be 780Wh). The way to correct
this is for me to kill upowerd and restart it, which is a pain.

So I've patched the upowerd source to reread charge_full and
charge_full_design each time the battery status is refreshed. I'm not sure
what the implications of this are, but I imagine it's not that big of a
deal, and it fixes my issue!

Anyway I thought I'd do the honourable thing and send the patch on to
yourselves, just because. I hope it's useful, if not it fixes my little
problem!

Thanks,
Mark
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/devkit-devel/attachments/20130210/eb4c5ad7/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: upower.patch
Type: application/octet-stream
Size: 851 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/devkit-devel/attachments/20130210/eb4c5ad7/attachment.obj>


More information about the devkit-devel mailing list