Commit 711a56b
committed
rockchip64: Helios64: fix Type-C PHY and TCPM registration
Problem:
On Helios64 boot, the Type-C PHY (ff7c0000.phy) gets stuck in
"deferred probe" state with unknown reason. This causes:
- USB 3.0 SuperSpeed via Type-C port not working
- DisplayPort via Type-C (Alt Mode) not working
The following messages appear in dmesg:
platform ff7c0000.phy: deferred probe pending: (reason unknown)
platform fe800000.usb: deferred probe pending: wait for supplier /phy@ff7c0000/usb3-port
platform fec00000.dp: deferred probe pending: wait for supplier /phy@ff7c0000/dp-port
Along with dependency cycle warnings:
/phy@ff7c0000/dp-port: Fixed dependency cycle(s) with /i2c@ff3d0000/typec-portc@22/connector
Root cause:
The Helios64 DTS uses a legacy Type-C connection method:
&tcphy0 {
extcon = <&fusb0>; // Expects extcon from fusb302
};
However:
1. The FUSB302 driver with TCPM support (since kernel ~4.14) does NOT
create extcon devices
2. Instead, it uses the Type-C connector class (/sys/class/typec/)
3. The phy-rockchip-typec driver calls extcon_get_edev_by_phandle(),
fails to find an extcon device at the specified phandle, and
returns -EPROBE_DEFER
4. The PHY remains in deferred probe indefinitely
The extcon-cables property is present in the DTS, but without a
typec_extcon_bridge node it serves no purpose.
This bug has existed since Type-C support was added to Helios64
(at least since kernel 6.6). It likely worked with older fusb302
driver versions, but broke after the transition to TCPM.
Solution:
Use the typec-extcon-bridge driver (Armbian patch from Ondrej Jirman/megi)
which translates Type-C connector class events to the extcon interface.
The Pinebook Pro patch (board-pbp-add-dp-alt-mode.patch) implements this
correctly: it has a typec_extcon_bridge node, and all extcon references
point to it rather than directly to fusb0.
Changes:
1. Add typec_extcon_bridge node with compatible = "linux,typec-extcon-bridge"
2. Change extcon = <&fusb0> to extcon = <&typec_extcon_bridge> in
tcphy0, cdn_dp, u2phy0, usbdrd_dwc3_0 nodes
3. Add usb-role-switch, mode-switch, orientation-switch properties
to fusb0 connector for integration with the bridge
4. Update PDO definitions with DUAL_ROLE and DATA_SWAP flags
5. Convert typec-altmodes property to modern altmodes subnode format
(required for TCPM port registration)
6. Add extcon,ignore-usb to u2phy0 (following Pinebook Pro pattern)
7. Add snps,usb3-phy-reset-quirk to usbdrd_dwc3_0
After this fix:
- Type-C PHY (ff7c0000.phy) no longer stuck in deferred probe
- USB 3.0 SuperSpeed via Type-C port should work
- DisplayPort via Type-C (Alt Mode) should work
- Correct cable orientation detection
- USB role switching (host/device)
Known remaining issues:
- FUSB302 fails to register TCPM port with error:
4-0022 typec_fusb302: cannot register tcpm port
This prevents USB Power Delivery negotiation. The root cause
appears to be in the connector configuration and requires
further investigation.1 parent 9e7f6dc commit 711a56b
File tree
1 file changed
+28
-9
lines changed- patch/kernel/archive/rockchip64-6.18
1 file changed
+28
-9
lines changedLines changed: 28 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
252 | 252 | | |
253 | 253 | | |
254 | 254 | | |
255 | | - | |
| 255 | + | |
256 | 256 | | |
257 | 257 | | |
258 | 258 | | |
| |||
335 | 335 | | |
336 | 336 | | |
337 | 337 | | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
338 | 346 | | |
339 | 347 | | |
340 | 348 | | |
| |||
353 | 361 | | |
354 | 362 | | |
355 | 363 | | |
356 | | - | |
| 364 | + | |
357 | 365 | | |
358 | 366 | | |
359 | 367 | | |
| |||
550 | 558 | | |
551 | 559 | | |
552 | 560 | | |
553 | | - | |
| 561 | + | |
554 | 562 | | |
555 | 563 | | |
556 | 564 | | |
| |||
588 | 596 | | |
589 | 597 | | |
590 | 598 | | |
| 599 | + | |
591 | 600 | | |
592 | 601 | | |
593 | 602 | | |
594 | 603 | | |
595 | 604 | | |
596 | 605 | | |
597 | 606 | | |
598 | | - | |
599 | | - | |
| 607 | + | |
| 608 | + | |
600 | 609 | | |
| 610 | + | |
| 611 | + | |
601 | 612 | | |
602 | | - | |
603 | | - | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
604 | 619 | | |
605 | 620 | | |
606 | 621 | | |
| |||
841 | 856 | | |
842 | 857 | | |
843 | 858 | | |
844 | | - | |
| 859 | + | |
845 | 860 | | |
846 | 861 | | |
847 | 862 | | |
| |||
864 | 879 | | |
865 | 880 | | |
866 | 881 | | |
867 | | - | |
| 882 | + | |
868 | 883 | | |
869 | 884 | | |
870 | 885 | | |
871 | 886 | | |
872 | 887 | | |
| 888 | + | |
| 889 | + | |
873 | 890 | | |
874 | 891 | | |
875 | 892 | | |
| |||
923 | 940 | | |
924 | 941 | | |
925 | 942 | | |
| 943 | + | |
| 944 | + | |
926 | 945 | | |
927 | 946 | | |
928 | 947 | | |
| |||
0 commit comments