bq27x00_battery: Check current after reading flags
authorGrazvydas Ignotas <notasas@gmail.com>
Mon, 26 Mar 2012 22:23:00 +0000 (01:23 +0300)
committerGrazvydas Ignotas <notasas@gmail.com>
Tue, 3 Apr 2012 21:00:38 +0000 (00:00 +0300)
It appears bq27500 has a threshold for DSG flag (60mA by default according
to the manual) after which it no longer sets DSG bit. This means we have
to check current to avoid misreporting that we are charging when we are
really discharging, which currently happens in lower power states.
As flags register is read in bq27x00_update, do current direction check
there.


No differences found