MMI: Init batt health to GOOD

batt health is only set  in normal mode, so batt health is unknown
in factory mode, so Init it to POWER_SUPPLY_HEALTH_GOOD.

Change-Id: I3c8de02fc8e07c9d1bdc65ea4b530927d1eec343
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/1456963
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Lu Chai <chailu1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
Haijian Ma 2019-11-18 17:33:31 +08:00
commit 65c2b4a165

View file

@ -3904,6 +3904,7 @@ static int smb_mmi_probe(struct platform_device *pdev)
chip->soc_cycles_start = EMPTY_CYCLES;
chip->last_reported_soc = -1;
chip->last_reported_status = -1;
chip->sm_param[BASE_BATT].batt_health = POWER_SUPPLY_HEALTH_GOOD;
chip->qcom_psy = power_supply_get_by_name("qcom_battery");
if (chip->qcom_psy) {
chip->batt_psy = devm_power_supply_register(chip->dev,