summaryrefslogtreecommitdiff
path: root/arch/arm/kvm/psci.c
diff options
context:
space:
mode:
authorAbhijeet Dharmapurikar <adharmap@codeaurora.org>2017-05-18 15:37:56 -0700
committerAbhijeet Dharmapurikar <adharmap@codeaurora.org>2017-05-19 14:11:08 -0700
commitb186b398d9565aca9e568c6394b2041c7c0af4e4 (patch)
treebb25099b13aee1bf32a00857648b6eb6e1034d02 /arch/arm/kvm/psci.c
parent5404e35069576a8cd8203065f60975e34a5f727b (diff)
smb-lib: do not disable parallel based only on main's settled current
Currently main charger ends up voting to disable parallel(USBIN_I_VOTER) if the settled current is less than 1.4Amps. It could be that the parallel path is drawing some current and the draw is higher than 1.4Amps. Move this disabling to battery, where the parallel charger's input current is taken in to consideration. Also while voting to disable, make sure that the main's input is limited. If there is more room for ICL to increase that means more power could be drawn from the charger and so we must keep the parallel charging enabled. If the ICL ceiling itself if 1.4Amps then disable parallel charging, because even if ICL has room to increase it wont cross 1.4Amps. The main's input limited state is set while AICL steps up - this ensures that we keep parallel disabled while AICL is running and settled is less than 1.4Amps. When the charger is removed, the main's input limited status is unset, however we want to keep the parallel charger disabled. In such situations the main's settled current is 0mA - use this to vote for disabling parallel charging. For any ICL change vote request: Disable parallel using USBIN_I_VOTER if requested current is less than 1.4Amps and to un-vote (i.e. when ICL vote is higher than 1.4Amps) rely on event from AICL done or status_change delayed work. Note that USBIN_I_VOTER is effective only for non-QC chargers. For QC chargers USBIN_V_VOTER continues to keep charging enabled since parallel need not be disabled is a lower current is requested with a QC charger. Change-Id: I61d7cd161a87de2904470b2d870058a0fe199116 Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Diffstat (limited to 'arch/arm/kvm/psci.c')
0 files changed, 0 insertions, 0 deletions