Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
117 changes: 3 additions & 114 deletions arch/arm64/boot/dts/apple/t6040-j614s.dts
Original file line number Diff line number Diff line change
Expand Up @@ -99,120 +99,9 @@
};

/*
* USB4/Thunderbolt on all three Type-C ports: typec0 (left back, ACIO0),
* typec1 (left front, ACIO1) and typec2 (right, ACIO2), as on the J616s: the
* J614s ADT has the same acio0-2, dart-acio0-2 and acio-cpu0-2. The loader
* hands each router its router, adapter and NHI tuning and its DROM over. No
* PCIe tunnels yet: host-to-host (XDomain, thunderbolt-net) and USB4 links
* only.
* USB4/Thunderbolt on all three Type-C ports: typec0 (left back, ACIO0), typec1 (left front,
* ACIO1) and typec2 (right, ACIO2); the J614s ADT has acio0-2, dart-acio0-2 and acio-cpu0-2.
*/
&pmgr_cio {
status = "okay";
};

&ps_atc0_cio {
status = "okay";
};

&ps_atc0_pcie {
status = "okay";
};

&ps_atc0_cio_pcie {
status = "okay";
};

&ps_atc0_cio_usb {
status = "okay";
};

&usb4_0_mbox {
status = "okay";
};

&usb4_0_acio {
status = "okay";
};

&usb4_0_dart {
power-domains = <&ps_atc0_cio>;
/* ADT dart-acio0 vm-base: the NHI addresses its rings below 1 TiB + 4 GiB. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_0_nhi {
status = "okay";
};

&ps_atc1_cio {
status = "okay";
};

&ps_atc1_pcie {
status = "okay";
};

&ps_atc1_cio_pcie {
status = "okay";
};

&ps_atc1_cio_usb {
status = "okay";
};

&usb4_1_mbox {
status = "okay";
};

&usb4_1_acio {
status = "okay";
};

&usb4_1_dart {
power-domains = <&ps_atc1_cio>;
/* The same DVA window as the ACIO0 router DART. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_1_nhi {
status = "okay";
};

&ps_atc2_cio {
status = "okay";
};

&ps_atc2_pcie {
status = "okay";
};

&ps_atc2_cio_pcie {
status = "okay";
};

&ps_atc2_cio_usb {
status = "okay";
};

&usb4_2_mbox {
status = "okay";
};

&usb4_2_acio {
status = "okay";
};

&usb4_2_dart {
power-domains = <&ps_atc2_cio>;
/* The same DVA window as the ACIO0 router DART. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_2_nhi {
status = "okay";
};
#include "t6040-usb4-routers.dtsi"

#include "t6040-j614s-extdisp-hdmi.dtsi"
115 changes: 3 additions & 112 deletions arch/arm64/boot/dts/apple/t6040-j616s.dts
Original file line number Diff line number Diff line change
Expand Up @@ -195,119 +195,10 @@
};

/*
* USB4/Thunderbolt on all three Type-C ports: typec0 (left back, ACIO0),
* typec1 (left front, ACIO1) and typec2 (right, ACIO2). The loader hands
* each router its router, adapter and NHI tuning and its DROM over. Each
* router carries its PCIe-C tunnel (t6040-pciec.dtsi).
* USB4/Thunderbolt on all three Type-C ports: typec0 (left back, ACIO0), typec1 (left front,
* ACIO1) and typec2 (right, ACIO2); the J616s ADT has acio0-2, dart-acio0-2 and acio-cpu0-2.
*/
&pmgr_cio {
status = "okay";
};

&ps_atc0_cio {
status = "okay";
};

&ps_atc0_pcie {
status = "okay";
};

&ps_atc0_cio_pcie {
status = "okay";
};

&ps_atc0_cio_usb {
status = "okay";
};

&usb4_0_mbox {
status = "okay";
};

&usb4_0_acio {
status = "okay";
};

&usb4_0_dart {
power-domains = <&ps_atc0_cio>;
/* ADT dart-acio0 vm-base: the NHI addresses its rings below 1 TiB + 4 GiB. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_0_nhi {
status = "okay";
};

&ps_atc1_cio {
status = "okay";
};

&ps_atc1_pcie {
status = "okay";
};

&ps_atc1_cio_pcie {
status = "okay";
};

&ps_atc1_cio_usb {
status = "okay";
};

&usb4_1_mbox {
status = "okay";
};

&usb4_1_acio {
status = "okay";
};

&usb4_1_dart {
power-domains = <&ps_atc1_cio>;
/* The same DVA window as the ACIO0 router DART. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_1_nhi {
status = "okay";
};

&ps_atc2_cio {
status = "okay";
};

&ps_atc2_pcie {
status = "okay";
};

&ps_atc2_cio_pcie {
status = "okay";
};

&ps_atc2_cio_usb {
status = "okay";
};

&usb4_2_mbox {
status = "okay";
};

&usb4_2_acio {
status = "okay";
};

&usb4_2_dart {
power-domains = <&ps_atc2_cio>;
/* The same DVA window as the ACIO0 router DART. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_2_nhi {
status = "okay";
};
#include "t6040-usb4-routers.dtsi"

/*
* The internal PCIe controller (Wi-Fi/Bluetooth, SD reader) needs APCIE_GP,
Expand Down
18 changes: 18 additions & 0 deletions arch/arm64/boot/dts/apple/t6040-j773s.dts
Original file line number Diff line number Diff line change
Expand Up @@ -924,3 +924,21 @@
&t6040_sleep {
apple,gp-pcie = <&pcie0>;
};

/*
* USB4/Thunderbolt on the three back ports: typec0 (back middle, hpm0, ACIO0), typec1 (back left,
* hpm1, ACIO1) and typec2 (back right, hpm2, ACIO2). The J773s ADT has acio0-2, dart-acio0-2,
* acio-cpu0-2 and apciec0-2, with hpm0-2's acio-parent and acio0-2's atc-phy-parent pairing them
* this way. The PCIe tunnels are already described (t6040-usb4.dtsi); without the routers they
* cannot come up.
*/
#include "t604x-usb4-typec.dtsi"
#include "t6040-usb4-routers.dtsi"

/*
* The routers' LSTX pins (AOP GPIO 49, 51, 53) are in the AOP pin controller. No display gate
* chain uses it on this board, so it is enabled here.
*/
&pinctrl_aop {
status = "okay";
};
117 changes: 117 additions & 0 deletions arch/arm64/boot/dts/apple/t6040-usb4-routers.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* The T6040 (M4 Pro) USB4/Thunderbolt routers on all three Type-C ports, ACIO0-2, with their
* PCIe tunnels (t6040-usb4.dtsi): the CIO power domains, the router mailboxes, routers, DARTs
* and NHIs. For boards whose ADT has acio0-2, dart-acio0-2 and acio-cpu0-2: J614s, J616s, J773s.
* The loader hands each router its router, adapter and NHI tuning and its DROM over from this
* machine's ADT (usb4-N aliases). The routers' LSTX pins are in the AOP pin controller, which the
* board enables (J773s) or the HDMI display gate enables with its chain (J614s, J616s).
*/
&pmgr_cio {
status = "okay";
};

&ps_atc0_cio {
status = "okay";
};

&ps_atc0_pcie {
status = "okay";
};

&ps_atc0_cio_pcie {
status = "okay";
};

&ps_atc0_cio_usb {
status = "okay";
};

&usb4_0_mbox {
status = "okay";
};

&usb4_0_acio {
status = "okay";
};

&usb4_0_dart {
power-domains = <&ps_atc0_cio>;
/* ADT dart-acio0 vm-base: the NHI addresses its rings below 1 TiB + 4 GiB. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_0_nhi {
status = "okay";
};

&ps_atc1_cio {
status = "okay";
};

&ps_atc1_pcie {
status = "okay";
};

&ps_atc1_cio_pcie {
status = "okay";
};

&ps_atc1_cio_usb {
status = "okay";
};

&usb4_1_mbox {
status = "okay";
};

&usb4_1_acio {
status = "okay";
};

&usb4_1_dart {
power-domains = <&ps_atc1_cio>;
/* The same DVA window as the ACIO0 router DART. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_1_nhi {
status = "okay";
};

&ps_atc2_cio {
status = "okay";
};

&ps_atc2_pcie {
status = "okay";
};

&ps_atc2_cio_pcie {
status = "okay";
};

&ps_atc2_cio_usb {
status = "okay";
};

&usb4_2_mbox {
status = "okay";
};

&usb4_2_acio {
status = "okay";
};

&usb4_2_dart {
power-domains = <&ps_atc2_cio>;
/* The same DVA window as the ACIO0 router DART. */
apple,dma-range = <0x100 0x4000 0x0 0xffff0000>;
status = "okay";
};

&usb4_2_nhi {
status = "okay";
};
2 changes: 1 addition & 1 deletion arch/arm64/boot/dts/apple/t604x-j614-j616.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -3481,7 +3481,7 @@
status = "okay";
};

#include "t604x-j614-j616-usb4.dtsi"
#include "t604x-usb4-typec.dtsi"

&t6040_sleep {
apple,gp-pcie = <&pcie0>;
Expand Down
Loading
Loading