diff options
| author | Linux Build Service Account <lnxbuild@quicinc.com> | 2017-12-14 00:14:40 -0800 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2017-12-14 00:14:39 -0800 |
| commit | 19c73e7a34d3fbaa18534073e36643747481f3cc (patch) | |
| tree | a95f42635b83ae0dc4f2cb0cb4364c134a901864 /drivers/usb | |
| parent | 517f7db9b07c793eff9b906d0afc3e08e88a8343 (diff) | |
| parent | ff9900827c20ef657ecc8a959486f72bbb7863a9 (diff) | |
Merge "dwc3-msm: Notify proper current values in case of floating charger"
Diffstat (limited to 'drivers/usb')
| -rw-r--r-- | drivers/usb/dwc3/dwc3-msm.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/usb/dwc3/dwc3-msm.c b/drivers/usb/dwc3/dwc3-msm.c index 26422a659bfc..0c992cfb3afa 100644 --- a/drivers/usb/dwc3/dwc3-msm.c +++ b/drivers/usb/dwc3/dwc3-msm.c @@ -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; } |
