Revert "bq27x00_battery: Fix reporting status value for bq27500 battery"
authorAnton Vorontsov <cbouatmailru@gmail.com>
Wed, 1 Feb 2012 17:20:15 +0000 (21:20 +0400)
committerAnton Vorontsov <cbouatmailru@gmail.com>
Wed, 1 Feb 2012 17:21:29 +0000 (21:21 +0400)
commitb7aaacf56ac9e0cdb58c3d087fea7084d897c307
tree13f7a896054839a1e2e3fa773e428205e475ec52
parent62aa2b537c6f5957afd98e29f96897419ed5ebab
Revert "bq27x00_battery: Fix reporting status value for bq27500 battery"

This reverts commit 270968c0984aeed096da3cfffb0e131f4c416166.

Grazvydas Ignotas wrote:

After 270968c0984ae "bq27x00_battery: Fix reporting status value for
bq27500 battery" status doesn't seem to be reported correctly when the
battery is close to fully charged state. It reports "Not charging"
while in fact there is >130mA current flowing to the battery according
to current_now.

This status report seems to be based on CHG bit in status register,
but looking at the datasheet the description says "(Fast) charging
allowed", which I guess means that the chip recommends charging and
not that charging is actually going on? If you check the bit while
battery is discharging and it's not full, the bit is also set.

Suggested-by: Grazvydas Ignotas <notasas@gmail.com>
Acked-by: Pali Rohár <pali.rohar@gmail.com>
Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
drivers/power/bq27x00_battery.c