]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: dts: qcom: qcs404: Fix incorrect USB2 PHYs assignment
authorSumit Garg <sumit.garg@linaro.org>
Mon, 11 Jul 2022 08:30:38 +0000 (14:00 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:23:14 +0000 (14:23 +0200)
commite5d4c91641d3994c3ff98bae1b586e064672f1a5
tree309f54040a6c9714422af1a0f1e8ff6c0833c798
parent43cb85d64be39b509d8717417eec3242cf36d1cf
arm64: dts: qcom: qcs404: Fix incorrect USB2 PHYs assignment

[ Upstream commit ff21fdfc26fd33f2ea7125feac86994009cf65be ]

Currently the DT for QCS404 SoC has setup for 2 USB2 PHYs with one each
assigned to USB3 controller and USB2 controller. This assignment is
incorrect which only works by luck: as when each USB HCI comes up it
configures the *other* controllers PHY which is enough to make them
happy. If, for any reason, we were to disable one of the controllers then
both would stop working.

This was a difficult inconsistency to be caught which was found while
trying to enable USB support in u-boot. So with all the required drivers
ported to u-boot, I couldn't get the same USB storage device enumerated
in u-boot which was being enumerated fine by the kernel.

The root cause of the problem came out to be that I wasn't enabling USB2
PHY: "usb2_phy_prim" in u-boot. Then I realised that via simply disabling
the same USB2 PHY currently assigned to USB2 host controller in the
kernel disabled enumeration for USB3 host controller as well.

So fix this inconsistency by correctly assigning USB2 PHYs.

Fixes: af153ec753ba ("arm64: dts: qcom: qcs404: Add USB devices and PHYs")
Signed-off-by: Sumit Garg <sumit.garg@linaro.org>
Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Link: https://lore.kernel.org/r/20220711083038.1518529-1-sumit.garg@linaro.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/arm64/boot/dts/qcom/qcs404.dtsi