power: smb5: update APSD result in USBIN_PLUGIN IRQ

The variable real_charge_type is a cached value to reflect the real
connected charger type based on APSD results. However, it is not
updated when APSD result status gets cleared on charger removal, the
moment when USBIN_PLUGIN_RT_STS goes low on unplug. As a result,
some times, charger type remains even after a charger is removed.

Fix it by updating real_charge_type in USBIN_PLUGIN IRQ.

Change-Id: I008aa466ef83c12a38d3d2a2d81c736d14d019c9
Signed-off-by: Harry Yang <harryy@codeaurora.org>
1 file changed