Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4e957702 authored by Xiaozhe Shi's avatar Xiaozhe Shi
Browse files

power: qpnp-smbcharger: allow OTG OC retries after a delay



When a high capacitance OTG device is connected, the PMI8994 charger
will detect an overcurrent (OC) condition because of the inrush current.

The workaround for this is to retry the OTG enable once after getting an
OC condition. However, this does not account for the case where an OTG
dongle is kept connected to the device so that the PMI8994 charger will
continuously supply 5V. In this case, if the high capacitance device is
repeatedly connected and disconnected, the OC condition will arise every
time it is connected to the OTG device. Since the driver only retries
the OTG enable once, every subsequent OTG device insertion will fail.

Fix this by allowing the OTG to reset if an OC condition is not detected
within a certain time period.

CRs-Fixed: 757987
Change-Id: If4fd7edab97c0992c762717888377daa8d920605
Signed-off-by: default avatarXiaozhe Shi <xiaozhes@codeaurora.org>
parent dca34e2b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment