qcom: smb1351: update CHARGING_ENABLE reporting logic

In case of parallel charging mode "parallel_charger_suspended"
variable tracks the charging enable state, update CHARGING_ENABLE
reporting to use the same.

CRs-Fixed: 2014572
Change-Id: Ib7246f407ad103343b7587b9de3ac938fb63767d
Signed-off-by: Ashay Jaiswal <ashayj@codeaurora.org>
This commit is contained in:
Ashay Jaiswal 2017-04-04 16:57:57 +05:30
parent eb367740c8
commit 0b6793543b

View file

@ -1655,7 +1655,7 @@ static int smb1351_parallel_get_property(struct power_supply *psy,
switch (prop) {
case POWER_SUPPLY_PROP_CHARGING_ENABLED:
val->intval = !chip->usb_suspended_status;
val->intval = !chip->parallel_charger_suspended;
break;
case POWER_SUPPLY_PROP_CURRENT_MAX:
if (!chip->parallel_charger_suspended)