power: bq24617: Fix scenario where charge indication is missed
authorGreg Meiste <w30289@motorola.com>
Wed, 26 Jan 2011 19:38:37 +0000 (13:38 -0600)
committerColin Cross <ccross@android.com>
Thu, 27 Jan 2011 01:34:50 +0000 (17:34 -0800)
commit6010dba762ad06de75cfb8070c473f6810a5357f
treeb1020be6ef80304204cdcac884758f29f6414272
parent7aea99d563f8ebc4867276834b970935b99a53f9
power: bq24617: Fix scenario where charge indication is missed

On Stingray, the charge STAT pins are not connected to a wakeup
source.  Therefore, if the device enters LP0 after the charger is
detected, but before charging begins, charging will never be
reported to the UI since the edge on STAT1 is missed.  The device
is actually charging, but to see the indication, the charger would
have to be removed and re-inserted.  In addition, if charge
complete is reached while in LP0, the edge on STAT2 is missed, and
the UI never shows charge complete.  These issues were resolved by
adding a resume function to the driver.

In addition, the work function and wake_lock was removed from the
driver because the same functionality exists in the power supply
core driver.

Change-Id: Ieaeaf2b47adec21f51bd77910427d74780cb865d
Signed-off-by: Greg Meiste <w30289@motorola.com>
drivers/power/bq24617_charger.c