mbox series

[0/2] pm8150b qmp phy type-c orientation fixes

Message ID 20210706230702.299047-1-bryan.odonoghue@linaro.org
Headers show
Series pm8150b qmp phy type-c orientation fixes | expand

Message

Bryan O'Donoghue July 6, 2021, 11:07 p.m. UTC
This series is a component of a series which enables full Type-C port
manager support on pm8150b hardware as found on sm8150 and sm8250.

https://git.linaro.org/people/bryan.odonoghue/kernel.git/log/?h=usb-next-5.13.rcx-rb5-tcpm-v2

When we change the orientation of the Type-C cable, we must also change the
lane allocation in the qmp phy to match the reported orientation.

The first patch is a simple typo fix in the original upstream commit.

The second patch implements a reasonably complex dance to reset the qmp phy
for the orientation switch. This necessitates registering for the Type-C
switch, resetting the PHY and then bringing the PHY back up with the correct
orientation.

The second patch is based on Wesley's original submission, reworked by
Dmitry and with a few fixes applied by me.

Dmitry Baryshkov (2):
  arm64: dts: qcom: sm8250: fix usb2 qmp phy node
  phy: qcom-qmp: Register as a typec switch for orientation detection

 arch/arm64/boot/dts/qcom/sm8250.dtsi |   2 +-
 drivers/phy/qualcomm/Kconfig         |   8 ++
 drivers/phy/qualcomm/phy-qcom-qmp.c  | 107 ++++++++++++++++++++++-----
 3 files changed, 96 insertions(+), 21 deletions(-)