Commit 9da45d97 authored by Janne Grunau's avatar Janne Grunau Committed by Sven Peter
Browse files

arm64: dts: apple: Add J474s, J475c and J475d device trees



Add device trees for the M2 Pro Mac mini and the M2 Max and Ultra
Mac Studio. These devices are very similar to the M1 Max and Ultra
Mac Studio so reuse the device template, include the .dtsi for the new
SoCs and correct for the minimal differences.

Co-developed-by: default avatarHector Martin <marcan@marcan.st>
Signed-off-by: default avatarHector Martin <marcan@marcan.st>
Reviewed-by: default avatarNeal Gompa <neal@gompa.dev>
Signed-off-by: default avatarJanne Grunau <j@jannau.net>
Reviewed-by: default avatarSven Peter <sven@kernel.org>
Signed-off-by: default avatarSven Peter <sven@kernel.org>
parent 44a95258
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -83,6 +83,9 @@ dtb-$(CONFIG_ARCH_APPLE) += t6020-j414s.dtb
dtb-$(CONFIG_ARCH_APPLE) += t6021-j414c.dtb
dtb-$(CONFIG_ARCH_APPLE) += t6020-j416s.dtb
dtb-$(CONFIG_ARCH_APPLE) += t6021-j416c.dtb
dtb-$(CONFIG_ARCH_APPLE) += t6020-j474s.dtb
dtb-$(CONFIG_ARCH_APPLE) += t6021-j475c.dtb
dtb-$(CONFIG_ARCH_APPLE) += t6022-j475d.dtb
dtb-$(CONFIG_ARCH_APPLE) += t8112-j413.dtb
dtb-$(CONFIG_ARCH_APPLE) += t8112-j415.dtb
dtb-$(CONFIG_ARCH_APPLE) += t8112-j473.dtb
+47 −0
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
 * Mac mini (M2 Pro, 2023)
 *
 * target-type: J474s
 *
 * Copyright The Asahi Linux Contributors
 */

/dts-v1/;

#include "t6020.dtsi"

/*
 * This model is very similar to M1 and M2 Mac Studio models so base it on those
 * and remove the missing SDHCI controller.
 */

#include "t602x-j474-j475.dtsi"

/ {
	compatible = "apple,j474s", "apple,t6020", "apple,arm-platform";
	model = "Apple Mac mini (M2 Pro, 2023)";
};

/* PCIe devices */
&wifi0 {
	compatible = "pci14e4,4434";
	brcm,board-type = "apple,tasmania";
};

&bluetooth0 {
	compatible = "pci14e4,5f72";
	brcm,board-type = "apple,tasmania";
};

/*
 * port01 is unused, remove the PCIe sdhci0 node from t600x-j375.dtsi and adjust
 * the iommu-map.
 */
/delete-node/ &sdhci0;

&pcie0 {
	iommu-map = <0x100 &pcie0_dart_0 1 1>,
			<0x200 &pcie0_dart_2 1 1>,
			<0x300 &pcie0_dart_3 1 1>;
};
+37 −0
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
 * Mac Studio (M2 Max, 2023)
 *
 * target-type: J475c
 *
 * Copyright The Asahi Linux Contributors
 */

/dts-v1/;

#include "t6021.dtsi"
#include "t602x-j474-j475.dtsi"

/ {
	compatible = "apple,j475c", "apple,t6021", "apple,arm-platform";
	model = "Apple Mac Studio (M2 Max, 2023)";
};

&wifi0 {
	compatible = "pci14e4,4434";
	brcm,board-type = "apple,canary";
};

&bluetooth0 {
	compatible = "pci14e4,5f72";
	brcm,board-type = "apple,canary";
};

/* enable PCIe port01 with SDHCI */
&port01 {
	status = "okay";
};

&pcie0_dart_1 {
	status = "okay";
};
+42 −0
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
 * Mac Studio (M2 Ultra, 2023)
 *
 * target-type: J475d
 *
 * Copyright The Asahi Linux Contributors
 */

/dts-v1/;

#include "t6022.dtsi"
#include "t602x-j474-j475.dtsi"
#include "t6022-jxxxd.dtsi"

/ {
	compatible = "apple,j475d", "apple,t6022", "apple,arm-platform";
	model = "Apple Mac Studio (M2 Ultra, 2023)";
};

&framebuffer0 {
	power-domains = <&ps_dispext0_cpu0_die1>, <&ps_dptx_phy_ps_die1>;
};

/* enable PCIe port01 with SDHCI */
&port01 {
	status = "okay";
};

&pcie0_dart_1 {
	status = "okay";
};

&wifi0 {
	compatible = "pci14e4,4434";
	brcm,board-type = "apple,canary";
};

&bluetooth0 {
	compatible = "pci14e4,5f72";
	brcm,board-type = "apple,canary";
};
+38 −0
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
 * Mac Pro (M2 Ultra, 2023) and Mac Studio (M2 Ultra, 2023)
 *
 * This file contains the parts common to J180 and J475 devices with t6022.
 *
 * target-type: J180d / J475d
 *
 * Copyright The Asahi Linux Contributors
 */

/* delete power-domains for missing disp0 / disp0_die1 */
/delete-node/ &ps_disp0_cpu0;
/delete-node/ &ps_disp0_fe;

/delete-node/ &ps_disp0_cpu0_die1;
/delete-node/ &ps_disp0_fe_die1;

/* USB Type C */
&i2c0 {
	/* front-right */
	hpm4: usb-pd@39 {
		compatible = "apple,cd321x";
		reg = <0x39>;
		interrupt-parent = <&pinctrl_ap>;
		interrupts = <44 IRQ_TYPE_LEVEL_LOW>;
		interrupt-names = "irq";
	};

	/* front-left */
	hpm5: usb-pd@3a {
		compatible = "apple,cd321x";
		reg = <0x3a>;
		interrupt-parent = <&pinctrl_ap>;
		interrupts = <44 IRQ_TYPE_LEVEL_LOW>;
		interrupt-names = "irq";
	};
};
Loading