charging: fixed sometimes don't request dpdm issue

sometimes vbus type don't equal to NONE, so don't request
dpdm, so qc3.0 can't be correctly identified.
we must request dpdm when charger inserted.

Change-Id: I68f48ac713e468250709a6788dddf57e460887d0
Signed-off-by: mahj8 <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2114459
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
mahj8 2021-11-12 14:14:46 +08:00 • committed by Haijian Ma
commit 424fc3bd64

View file

@ -2029,7 +2029,7 @@ static void bq2589x_charger_irq_workfunc(struct work_struct *work)
bq->vbus_type = (status & BQ2589X_VBUS_STAT_MASK) >> BQ2589X_VBUS_STAT_SHIFT;
if (state.vbus_gd && (bq->vbus_type == BQ2589X_VBUS_NONE)){
if (state.vbus_gd && (!bq->dpdm_enabled)) {
dev_info(bq->dev, "BC1.2 detect is not done.\n");
bq2589x_reuqest_dpdm(bq, true);
}