power: qpnp-charger: fix charger valid check issue

Currently we use USB_CHG_PTH_STS(0x1309) to check whether charger is
valid in usbin_valid interrupt handler. Unfortunately it has
no debounce time and if USB_IN has a spike over UVP threshold
and comes back quickly, reading will be '0x10' by mistake. Fix this
by reading USBIN_VALID_RT_STS(0x1310) instead, which based on properly
debounced time.

Change-Id: Ia67a4bb433b6978a4b05a7419817e722b629ab41
CRs-Fixed: 623946
Signed-off-by: Zhenhua Huang <zhenhuah@codeaurora.org>
1 file changed