Only with BQ24296 OTG+PMU charging, the 1th time to access the USB flash drive tips to solve the problem of charging
Platform: msm8909+android5.1.1
At present, due to the BQ24296 charging mode of power display still have a lot of problems, instead of only using BQ24296 OTG function, or use PMU to charge, but found that the 1th time to access the USB flash drive tips Charging
Why this situation, the root cause is not found out temporarily, but can kernel\drivers\power\qpnp\linear-charger.c under the Get_prop_batt_status () add the following processing can avoid this problem
static int get_prop_batt_status (struct qpnp_lbc_chip *chip) {int rc;u8 reg_val;union power_supply_propval ret = {0,};if (q Pnp_lbc_is_usb_chg_plugged_in (Chip) && chip->chg_done) return POWER_SUPPLY_STATUS_FULL;RC = Qpnp_lbc_read (Chip, Chip->chgr_base + int_rt_sts_reg,®_val, 1); if (RC) {pr_err ("Failed to read interrupt STS rc=%d\n", RC); r Eturn Power_supply_charge_type_none;} Kandi Add Startchip->usb_psy->get_property (Chip->usb_psy,power_supply_prop_online, &ret); Ret.intval)//Solve the 1th time Access USB flash drive Display charging problem {if (Reg_val & FAST_CHG_ON_IRQ) {return power_supply_status_charging;}} Kandi add Endreturn power_supply_status_discharging;}
Only with BQ24296 OTG+PMU charging, the 1th time to access the USB flash drive tips to solve the problem of charging