Skip to content

RFC Add mt7988 XS-PHY

Frank Wunderlich linux-arm-kernel linux-devicetree linux-mediatek linux-phy lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest5 patches 10 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5dt-bindings: phy: mtk-xs-phy: Add mt7988 compatibleDocumentation/devicetree/bindings/phy/mediatek,xsphy.yaml+1 -00 replies
2/5dt-bindings: phy: mtk-xs-phy: support type switch by pericfgDocumentation/devicetree/bindings/phy/mediatek,xsphy.yaml+16 -00 replies
3/5dt-bindings: power: Add binding for MediaTek MT7988 topmisc power controllerDocumentation/devicetree/bindings/power/mediatek,power-controller.yaml+24 -117 replies
4/5phy: mediatek: xsphy: support type switch by pericfgdrivers/phy/mediatek/phy-mtk-xsphy.c+84 -11 reply
5/5arm64: dts: mediatek: mt7988: Add xsphy for ssusb0/pcie2arch/arm64/boot/dts/mediatek/mt7988a.dtsi+39 -02 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC 0/5] Add mt7988 XS-PHY

From: Frank Wunderlich <[email protected]>

Mediatek XS-Phy is a high speed phy used for pcie and usb on mt7988 platform.

It requires a topmisc power controller to switch between USB and PCI mode. This topmisc system controller is also used by ethernet-node which is not upstreamed yet.
---
regading syscon-fallback...i know that it should be avoided ;)

based on these commits:

ba5095ebbc7a ("mfd: syscon: Allow syscon nodes without a "syscon" compatible") 5728c92ae112 ("mfd: syscon: Restore device_node_to_regmap() for non-syscon nodes")

I tried to get it working without syscon by changing

instance->type_sw = syscon_node_to_regmap(args.np); to
device_node_to_regmap()

then xsphy was probed sucessfully, but all pcie (not only the one with xsphy) stopped working.

for ethernet its driver uses syscon_regmap_lookup_by_phandle which needs to be patched in syscon driver to also use device_node_to_regmap instead of syscon_node_to_regmap (with create=true). But have not tried this.

regarding the pcie issue when dropping the syscon compatible i would leave this compatible, but send this patchset as RFC. Maybe anyone can solve this.

Daniel Golle (1):
phy: mediatek: xsphy: support type switch by pericfg

Frank Wunderlich (4):
dt-bindings: phy: mtk-xs-phy: Add mt7988 compatible
dt-bindings: phy: mtk-xs-phy: support type switch by pericfg
dt-bindings: power: Add binding for MediaTek MT7988 topmisc power
controller
arm64: dts: mediatek: mt7988: Add xsphy for ssusb0/pcie2

 .../bindings/phy/mediatek,xsphy.yaml          | 17 ++++
 .../power/mediatek,power-controller.yaml      | 35 +++++---
 arch/arm64/boot/dts/mediatek/mt7988a.dtsi     | 39 +++++++++
 drivers/phy/mediatek/phy-mtk-xsphy.c          | 85 ++++++++++++++++++-
 4 files changed, 164 insertions(+), 12 deletions(-)
Signature · 1 line
2.43.0