Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8f681319 authored by Jack Pham's avatar Jack Pham
Browse files

usb: dwc3-msm: Revert back to power_supply_by_name() lookup



commit af346132 ("usb: dwc3-msm: Get usb power_supply from
device tree") changed the power_supply_get_by_name() to
get_by_phandle(), however this does not work if the device
pointed to by the phandle registers multiple power_supply
objects (including battery & wireless as is the case for
QTI PMICs) as we are not guaranteed to get back the USB psy.

Hence revert back to using power_supply_get_by_name() for
the named "usb" psy. We can keep using the "qcom,usb-charger"
DT property but just treat it as boolean instead so that we
can support USB controllers that may not be tied to a charger.

Change-Id: Ic7e4c58b096b0d6210cd55f1ff6edf21ffc5b4b1
Signed-off-by: default avatarJack Pham <jackp@codeaurora.org>
parent 97ed7577
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment