power: rk817-battery: optimize charging curve

Change-Id: I3a11593324be523649f6c5b12872336fb24a5283
Signed-off-by: shengfei Xu <xsf@rock-chips.com>
This commit is contained in:
shengfei Xu 2018-07-20 09:13:26 +08:00 committed by Chen Liang
parent 80cc682ae7
commit c0ce1fa016

View File

@ -1299,6 +1299,13 @@ static int rk817_bat_get_charge_status(struct rk817_battery_device *battery)
status = rk817_bat_field_read(battery, CHG_STS);
if (status == CC_OR_CV_CHRG) {
if (battery->rsoc == 100 * 1000) {
DBG("charge to finish\n");
status = CHARGE_FINISH;
}
}
switch (status) {
case CHRG_OFF:
DBG("charge off...\n");