OSDN Git Service

usb: dwc3: Support float charger detection
authorSriharsha Allenki <sallenki@codeaurora.org>
Tue, 14 May 2019 12:58:23 +0000 (18:28 +0530)
committerSriharsha Allenki <sallenki@codeaurora.org>
Tue, 4 Jun 2019 09:10:53 +0000 (14:40 +0530)
commit669f50368505b3a67fb81a5ffec4914c5baa8b7f
tree9dfb65cba0a316397803adcc74ee153db04bd52e
parent705aac6195a3dbfcf1ec179ca489cdd5203016aa
usb: dwc3: Support float charger detection

Chargers on some platforms do not support FLOAT charger
detection. On these platforms, the float charger can be
detected depending on the state of the DP and DM lines as
detected by the PHY.
So, on these platforms check for the DP DM line state
and if found floating, do not start the peripheral mode
and notify PMIC -ETIMEDOUT implying the connected
charger is of type float.

Change-Id: I6bf54b0d5c143a849ce9ea7bc515d62204ed2f33
Signed-off-by: Sriharsha Allenki <sallenki@codeaurora.org>
Documentation/devicetree/bindings/usb/msm-ssusb.txt
drivers/usb/dwc3/dwc3-msm.c
drivers/usb/phy/phy-msm-qusb.c
include/linux/usb/phy.h