xref: /linux/arch/arm64/boot/dts/freescale/imx8mp-kontron-smarc-eval-carrier.dts (revision 7f71507851fc7764b36a3221839607d3a45c2025)
1// SPDX-License-Identifier: GPL-2.0+ OR MIT
2/*
3 * Copyright (C) 2024 Kontron Electronics GmbH
4 */
5
6/dts-v1/;
7
8#include <dt-bindings/phy/phy-imx8-pcie.h>
9#include "imx8mp-kontron-smarc.dtsi"
10
11/ {
12	model = "Kontron SMARC Eval Carrier with i.MX8MP";
13	compatible = "kontron,imx8mp-smarc-eval-carrier", "kontron,imx8mp-smarc",
14		     "kontron,imx8mp-osm-s", "fsl,imx8mp";
15
16	backlight: backlight {
17		compatible = "pwm-backlight";
18		pwms = <&pwm1 0 50000 0>;
19		brightness-levels = <0 100>;
20		num-interpolated-steps = <100>;
21		default-brightness-level = <100>;
22		enable-gpios = <&gpio3 19 GPIO_ACTIVE_HIGH>;
23	};
24
25	extcon_usbc: usbc {
26		compatible = "linux,extcon-usb-gpio";
27		pinctrl-names = "default";
28		pinctrl-0 = <&pinctrl_usb1_id>;
29		id-gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>;
30	};
31
32	sound {
33		compatible = "simple-audio-card";
34		simple-audio-card,bitclock-master = <&codec_dai>;
35		simple-audio-card,format = "i2s";
36		simple-audio-card,frame-master = <&codec_dai>;
37		simple-audio-card,mclk-fs = <256>;
38		simple-audio-card,name = "imx8mp-wm8904";
39		simple-audio-card,routing =
40			"Headphone Jack", "HPOUTL",
41			"Headphone Jack", "HPOUTR",
42			"IN2L", "Line In Jack",
43			"IN2R", "Line In Jack",
44			"Headphone Jack", "MICBIAS",
45			"IN1L", "Headphone Jack";
46		simple-audio-card,widgets =
47			"Microphone", "Headphone Jack",
48			"Headphone", "Headphone Jack",
49			"Line", "Line In Jack";
50
51		codec_dai: simple-audio-card,codec {
52			clocks = <&audio_blk_ctrl IMX8MP_CLK_AUDIOMIX_SAI3_MCLK1>;
53			sound-dai = <&wm8904>;
54		};
55
56		simple-audio-card,cpu {
57			sound-dai = <&sai3>;
58		};
59	};
60
61	regulator_can0: can0-regulator {
62		compatible = "regulator-fixed";
63		regulator-name = "can0_en";
64		gpio = <&expander_pm_out 6 GPIO_ACTIVE_HIGH>;
65		enable-active-high;
66	};
67
68	regulator_can1: can1-regulator {
69		compatible = "regulator-fixed";
70		regulator-name = "can1_en";
71		gpio = <&expander_pm_out 7 GPIO_ACTIVE_HIGH>;
72		enable-active-high;
73	};
74};
75
76&ecspi1 {
77	status = "okay";
78};
79
80&ecspi2 {
81	status = "okay";
82};
83
84&eqos {
85	status = "okay";
86};
87
88&fec {
89	status = "okay";
90};
91
92&flexcan1 {
93	xceiver-supply = <&regulator_can0>;
94	status = "okay";
95};
96
97&flexcan2 {
98	xceiver-supply = <&regulator_can1>;
99	status = "okay";
100};
101
102&hdmi_pvi {
103	status = "okay";
104};
105
106&hdmi_tx {
107	pinctrl-names = "default";
108	pinctrl-0 = <&pinctrl_hdmi>;
109	ddc-i2c-bus = <&i2c3>;
110	status = "okay";
111};
112
113&hdmi_tx_phy {
114	status = "okay";
115};
116
117&i2c1 {
118	status = "okay";
119
120	expander_pm_out: io-expander@22 {
121		compatible = "nxp,pca9554";
122		reg = <0x22>;
123		gpio-controller;
124		#gpio-cells = <2>;
125		gpio-line-names = "EN_5V0_S0", "EN_3V3_S0", "EN_1V8_S0",
126				  "EN_1V5_S0", "EN_12V0_PCIE", "EN_3V3_S5",
127				  "CAN0_EN", "CAN1_EN";
128	};
129
130	expander_pm_in: io-expander@24 {
131		compatible = "nxp,pca9554";
132		reg = <0x24>;
133		gpio-controller;
134		#gpio-cells = <2>;
135		gpio-line-names = "PG_5V0_3V3_S0", "PG_5V0_3V3_S5", "PG_1V8_S0",
136				  "PG_1V5_S0", "PG_BKLT_5V", "PG_BKLT_12V";
137	};
138};
139
140&i2c2 {
141	status = "okay";
142
143	wm8904: audio-codec@1a {
144		compatible = "wlf,wm8904";
145		reg = <0x1a>;
146		#sound-dai-cells = <0>;
147		clocks = <&audio_blk_ctrl IMX8MP_CLK_AUDIOMIX_SAI3_MCLK1>;
148		clock-names = "mclk";
149		AVDD-supply = <&reg_vdd_1v8>;
150		CPVDD-supply = <&reg_vdd_1v8>;
151		DBVDD-supply = <&reg_vdd_1v8>;
152		DCVDD-supply = <&reg_vdd_1v8>;
153		MICVDD-supply = <&reg_vdd_3v3>;
154	};
155
156	expander_audio: io-expander@20 {
157		compatible = "nxp,pca9554";
158		reg = <0x20>;
159		gpio-controller;
160		#gpio-cells = <2>;
161		gpio-line-names = "I2C_SEL_CODEC_LOOPBACK", "FPAH_PRESENCE",
162				  "CODEC_OPTION_SW_I2S_HDA", "LINE_IN_JD",
163				  "LINE_OUT_JD", "HEADPHONES_JD", "MIC_JD";
164	};
165};
166
167&i2c3 {
168	status = "okay";
169};
170
171&i2c4 {
172	status = "okay";
173};
174
175&lcdif3 {
176	status = "okay";
177};
178
179&pcie_phy {
180	fsl,refclk-pad-mode = <IMX8_PCIE_REFCLK_PAD_OUTPUT>;
181	fsl,clkreq-unsupported;
182	clocks = <&hsio_blk_ctrl>;
183	clock-names = "ref";
184	status = "okay";
185};
186
187&pcie {
188	pinctrl-names = "default";
189	pinctrl-0 = <&pinctrl_pcie>;
190	reset-gpio = <&gpio3 2 GPIO_ACTIVE_LOW>;
191	status = "okay";
192};
193
194&pwm1 {
195	status = "okay";
196};
197
198&sai3 {
199	assigned-clocks = <&clk IMX8MP_CLK_SAI3>;
200	assigned-clock-parents = <&clk IMX8MP_AUDIO_PLL1_OUT>;
201	assigned-clock-rates = <24576000>;
202	fsl,sai-mclk-direction-output;
203	status = "okay";
204};
205
206&uart1 {
207	uart-has-rtscts;
208	status = "okay";
209};
210
211&uart2 {
212	status = "okay";
213};
214
215&uart4 {
216	uart-has-rtscts;
217	status = "okay";
218};
219
220&usb_dwc3_0 {
221	adp-disable;
222	hnp-disable;
223	srp-disable;
224	dr_mode = "otg";
225	extcon = <&extcon_usbc>;
226	usb-role-switch;
227	status = "okay";
228};
229
230&usb_dwc3_1 {
231	status = "okay";
232};
233
234&usb3_0 {
235	status = "okay";
236};
237
238&usb3_1 {
239	status = "okay";
240};
241
242&usb3_phy0 {
243	vbus-supply = <&reg_usb1_vbus>;
244	status = "okay";
245};
246
247&usb3_phy1 {
248	status = "okay";
249};
250
251&usdhc2 {
252	vmmc-supply = <&reg_vdd_3v3>;
253	status = "okay";
254};
255