Merge "dwc3-msm: Notify proper current values in case of floating charger"

This commit is contained in:
Linux Build Service Account 2017-12-14 00:14:40 -08:00 committed by Gerrit - the friendly Code Review server
commit 19c73e7a34

View file

@ -3720,7 +3720,10 @@ static int dwc3_msm_gadget_vbus_draw(struct dwc3_msm *mdwc, unsigned mA)
psy_type = get_psy_type(mdwc);
if (psy_type == POWER_SUPPLY_TYPE_USB_FLOAT) {
pval.intval = -ETIMEDOUT;
if (!mA)
pval.intval = -ETIMEDOUT;
else
pval.intval = 1000 * mA;
goto set_prop;
}