blob: 9bc592bcdbfd74e4470cbb4b9dbba8acf99a4498 [file] [log] [blame]
Mark Kettenis3dfef532021-10-23 16:58:06 +02001// SPDX-License-Identifier: GPL-2.0+ OR MIT
2/*
3 * Apple Mac mini (M1, 2020)
4 *
5 * target-type: J274
6 *
7 * Copyright The Asahi Linux Contributors
8 */
9
10/dts-v1/;
11
12#include "t8103.dtsi"
Mark Kettenisc918e2c2022-01-10 20:58:42 +010013#include "t8103-jxxx.dtsi"
Mark Kettenis3dfef532021-10-23 16:58:06 +020014
15/ {
16 compatible = "apple,j274", "apple,t8103", "apple,arm-platform";
17 model = "Apple Mac mini (M1, 2020)";
18
19 aliases {
Mark Kettenisc918e2c2022-01-10 20:58:42 +010020 ethernet0 = &ethernet0;
Mark Kettenis3dfef532021-10-23 16:58:06 +020021 };
Mark Kettenisc918e2c2022-01-10 20:58:42 +010022};
Mark Kettenis3dfef532021-10-23 16:58:06 +020023
Mark Kettenisc918e2c2022-01-10 20:58:42 +010024&wifi0 {
25 brcm,board-type = "apple,atlantisb";
26};
Mark Kettenis3dfef532021-10-23 16:58:06 +020027
Mark Kettenisc918e2c2022-01-10 20:58:42 +010028/*
29 * Provide labels for the USB type C ports.
30 */
Mark Kettenis3dfef532021-10-23 16:58:06 +020031
Mark Kettenisc918e2c2022-01-10 20:58:42 +010032&typec0 {
33 label = "USB-C Back-left";
34};
35
36&typec1 {
37 label = "USB-C Back-right";
38};
39
40/*
41 * Force the bus number assignments so that we can declare some of the
42 * on-board devices and properties that are populated by the bootloader
43 * (such as MAC addresses).
44 */
45
46&port01 {
47 bus-range = <2 2>;
48};
49
50&port02 {
51 bus-range = <3 3>;
52 ethernet0: ethernet@0,0 {
53 reg = <0x30000 0x0 0x0 0x0 0x0>;
54 /* To be filled by the loader */
55 local-mac-address = [00 10 18 00 00 00];
56 };
57};
58
59&i2c1 {
60 clock-frequency = <50000>;
61
62 speaker_amp: codec@31 {
63 compatible = "ti,tas5770l", "ti,tas2770";
64 reg = <0x31>;
65 reset-gpios = <&pinctrl_ap 181 GPIO_ACTIVE_HIGH>;
66 #sound-dai-cells = <0>;
67 };
68};
69
70&i2c2 {
71 status = "okay";
72
73 clock-frequency = <50000>;
74
75 jack_codec: codec@48 {
76 compatible = "cirrus,cs42l83", "cirrus,cs42l42";
77 reg = <0x48>;
78 reset-gpios = <&pinctrl_nub 11 GPIO_ACTIVE_HIGH>;
79 interrupt-parent = <&pinctrl_ap>;
80 interrupts = <183 IRQ_TYPE_LEVEL_LOW>;
81 #sound-dai-cells = <0>;
82 cirrus,ts-inv = <1>;
83 };
84};
85
86/ {
87 sound {
88 compatible = "simple-audio-card";
89 simple-audio-card,name = "Mac mini integrated audio";
90 #address-cells = <1>;
91 #size-cells = <0>;
92
93 simple-audio-card,dai-link@0 {
94 reg = <0>;
95 format = "left_j";
96 tdm-slot-width = <32>;
97 mclk-fs = <64>;
98
99 link0_cpu: cpu {
100 sound-dai = <&mca 0>;
101 bitclock-master;
102 frame-master;
103 };
104
105 link0_codec: codec {
106 sound-dai = <&speaker_amp>;
107 };
108 };
109
110 simple-audio-card,dai-link@1 {
111 bitclock-inversion;
112 frame-inversion;
113 reg = <1>;
114 format = "i2s";
115 mclk-fs = <64>;
116 tdm-slot-width = <32>;
117
118 link1_cpu: cpu {
119 sound-dai = <&mca 2>;
120 bitclock-master;
121 frame-master;
122 };
123
124 link1_codec: codec {
125 sound-dai = <&jack_codec>;
126 };
Mark Kettenis3dfef532021-10-23 16:58:06 +0200127 };
128 };
Mark Kettenis3dfef532021-10-23 16:58:06 +0200129};