[PATCH] Patch to solve issues with some hardware that causes battery to never update

Mikael Hjelm j_m_hjelm at hotmail.com
Sun Jul 10 13:24:52 PDT 2011


I have tested this on a Aspire one which is heavily affected by hardware issues.For further info on the issues it solves please see https://bugs.launchpad.net/ubuntu/+source/upower/+bug/467825
Best Regards/Mikael Hjelm
/upower$ git diff diff --git a/src/linux/up-device-supply.c b/src/linux/up-device-supply.cindex 600fc27..b6aaf9a 100644--- a/src/linux/up-device-supply.c+++ b/src/linux/up-device-supply.c@@ -544,8 +544,12 @@ up_device_supply_refresh_battery (UpDeviceSupply *supply)        }         /* only disable the polling if the kernel tells us we're fully charged,-          not if we've guessed the state to be fully charged */-       supply->priv->enable_poll = (state != UP_DEVICE_STATE_FULLY_CHARGED);+          not if we've guessed the state to be fully charged. This function +          has been disabled since some battery hardware/drivers are very +          late to report discharging and does not interrupt on state change+       */+       /*supply->priv->enable_poll = (state != UP_DEVICE_STATE_FULLY_CHARGED);+         /* reset unknown counter */        if (state != UP_DEVICE_STATE_UNKNOWN) {
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/devkit-devel/attachments/20110710/87727e6e/attachment.htm>


More information about the devkit-devel mailing list