xref: /linux/arch/arm/boot/dts/nxp/imx/imx6qdl-dhcom-pdk2.dtsi (revision 724ba6751532055db75992fc6ae21c3e322e94a7)
1*724ba675SRob Herring// SPDX-License-Identifier: GPL-2.0+
2*724ba675SRob Herring/*
3*724ba675SRob Herring * Copyright (C) 2015-2021 DH electronics GmbH
4*724ba675SRob Herring * Copyright (C) 2018 Marek Vasut <marex@denx.de>
5*724ba675SRob Herring */
6*724ba675SRob Herring
7*724ba675SRob Herring#include <dt-bindings/gpio/gpio.h>
8*724ba675SRob Herring#include <dt-bindings/input/input.h>
9*724ba675SRob Herring#include <dt-bindings/leds/common.h>
10*724ba675SRob Herring#include <dt-bindings/pwm/pwm.h>
11*724ba675SRob Herring
12*724ba675SRob Herring/ {
13*724ba675SRob Herring	chosen {
14*724ba675SRob Herring		stdout-path = "serial0:115200n8";
15*724ba675SRob Herring	};
16*724ba675SRob Herring
17*724ba675SRob Herring	clk_ext_audio_codec: clock-codec {
18*724ba675SRob Herring		#clock-cells = <0>;
19*724ba675SRob Herring		clock-frequency = <24000000>;
20*724ba675SRob Herring		compatible = "fixed-clock";
21*724ba675SRob Herring	};
22*724ba675SRob Herring
23*724ba675SRob Herring	display_bl: display-bl {
24*724ba675SRob Herring		brightness-levels = <0 16 22 30 40 55 75 102 138 188 255>;
25*724ba675SRob Herring		compatible = "pwm-backlight";
26*724ba675SRob Herring		default-brightness-level = <8>;
27*724ba675SRob Herring		enable-gpios = <&gpio3 27 GPIO_ACTIVE_HIGH>; /* GPIO G */
28*724ba675SRob Herring		pwms = <&pwm1 0 50000 PWM_POLARITY_INVERTED>;
29*724ba675SRob Herring		status = "okay";
30*724ba675SRob Herring	};
31*724ba675SRob Herring
32*724ba675SRob Herring	lcd_display: disp0 {
33*724ba675SRob Herring		#address-cells = <1>;
34*724ba675SRob Herring		#size-cells = <0>;
35*724ba675SRob Herring		compatible = "fsl,imx-parallel-display";
36*724ba675SRob Herring		interface-pix-fmt = "rgb24";
37*724ba675SRob Herring		pinctrl-0 = <&pinctrl_ipu1_lcdif &pinctrl_dhcom_g>;
38*724ba675SRob Herring		pinctrl-names = "default";
39*724ba675SRob Herring		status = "okay";
40*724ba675SRob Herring
41*724ba675SRob Herring		port@0 {
42*724ba675SRob Herring			reg = <0>;
43*724ba675SRob Herring
44*724ba675SRob Herring			lcd_display_in: endpoint {
45*724ba675SRob Herring				remote-endpoint = <&ipu1_di0_disp0>;
46*724ba675SRob Herring			};
47*724ba675SRob Herring		};
48*724ba675SRob Herring
49*724ba675SRob Herring		port@1 {
50*724ba675SRob Herring			reg = <1>;
51*724ba675SRob Herring
52*724ba675SRob Herring			lcd_display_out: endpoint {
53*724ba675SRob Herring				remote-endpoint = <&lcd_panel_in>;
54*724ba675SRob Herring			};
55*724ba675SRob Herring		};
56*724ba675SRob Herring	};
57*724ba675SRob Herring
58*724ba675SRob Herring	gpio-keys {
59*724ba675SRob Herring		#size-cells = <0>;
60*724ba675SRob Herring		compatible = "gpio-keys";
61*724ba675SRob Herring
62*724ba675SRob Herring		button-0 {
63*724ba675SRob Herring			gpios = <&gpio1 2 GPIO_ACTIVE_LOW>; /* GPIO A */
64*724ba675SRob Herring			label = "TA1-GPIO-A";
65*724ba675SRob Herring			linux,code = <KEY_A>;
66*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_a>;
67*724ba675SRob Herring			pinctrl-names = "default";
68*724ba675SRob Herring			wakeup-source;
69*724ba675SRob Herring		};
70*724ba675SRob Herring
71*724ba675SRob Herring		button-1 {
72*724ba675SRob Herring			gpios = <&gpio1 4 GPIO_ACTIVE_LOW>; /* GPIO B */
73*724ba675SRob Herring			label = "TA2-GPIO-B";
74*724ba675SRob Herring			linux,code = <KEY_B>;
75*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_b>;
76*724ba675SRob Herring			pinctrl-names = "default";
77*724ba675SRob Herring			wakeup-source;
78*724ba675SRob Herring		};
79*724ba675SRob Herring
80*724ba675SRob Herring		button-2 {
81*724ba675SRob Herring			gpios = <&gpio1 5 GPIO_ACTIVE_LOW>; /* GPIO C */
82*724ba675SRob Herring			label = "TA3-GPIO-C";
83*724ba675SRob Herring			linux,code = <KEY_C>;
84*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_c>;
85*724ba675SRob Herring			pinctrl-names = "default";
86*724ba675SRob Herring			wakeup-source;
87*724ba675SRob Herring		};
88*724ba675SRob Herring
89*724ba675SRob Herring		button-3 {
90*724ba675SRob Herring			gpios = <&gpio6 3 GPIO_ACTIVE_LOW>; /* GPIO D */
91*724ba675SRob Herring			label = "TA4-GPIO-D";
92*724ba675SRob Herring			linux,code = <KEY_D>;
93*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_d>;
94*724ba675SRob Herring			pinctrl-names = "default";
95*724ba675SRob Herring			wakeup-source;
96*724ba675SRob Herring		};
97*724ba675SRob Herring	};
98*724ba675SRob Herring
99*724ba675SRob Herring	led {
100*724ba675SRob Herring		compatible = "gpio-leds";
101*724ba675SRob Herring
102*724ba675SRob Herring		/*
103*724ba675SRob Herring		 * Disable led-5, because GPIO E is
104*724ba675SRob Herring		 * already used as touch interrupt.
105*724ba675SRob Herring		 */
106*724ba675SRob Herring		led-5 {
107*724ba675SRob Herring			color = <LED_COLOR_ID_GREEN>;
108*724ba675SRob Herring			default-state = "off";
109*724ba675SRob Herring			function = LED_FUNCTION_INDICATOR;
110*724ba675SRob Herring			gpios = <&gpio4 5 GPIO_ACTIVE_HIGH>; /* GPIO E */
111*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_e>;
112*724ba675SRob Herring			pinctrl-names = "default";
113*724ba675SRob Herring			status = "disabled";
114*724ba675SRob Herring		};
115*724ba675SRob Herring
116*724ba675SRob Herring		led-6 {
117*724ba675SRob Herring			color = <LED_COLOR_ID_GREEN>;
118*724ba675SRob Herring			default-state = "off";
119*724ba675SRob Herring			function = LED_FUNCTION_INDICATOR;
120*724ba675SRob Herring			gpios = <&gpio4 20 GPIO_ACTIVE_HIGH>; /* GPIO F */
121*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_f>;
122*724ba675SRob Herring			pinctrl-names = "default";
123*724ba675SRob Herring		};
124*724ba675SRob Herring
125*724ba675SRob Herring		led-7 {
126*724ba675SRob Herring			color = <LED_COLOR_ID_GREEN>;
127*724ba675SRob Herring			default-state = "off";
128*724ba675SRob Herring			function = LED_FUNCTION_INDICATOR;
129*724ba675SRob Herring			gpios = <&gpio4 7 GPIO_ACTIVE_HIGH>; /* GPIO H */
130*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_h>;
131*724ba675SRob Herring			pinctrl-names = "default";
132*724ba675SRob Herring		};
133*724ba675SRob Herring
134*724ba675SRob Herring		led-8 {
135*724ba675SRob Herring			color = <LED_COLOR_ID_GREEN>;
136*724ba675SRob Herring			default-state = "off";
137*724ba675SRob Herring			function = LED_FUNCTION_INDICATOR;
138*724ba675SRob Herring			gpios = <&gpio4 8 GPIO_ACTIVE_HIGH>; /* GPIO I */
139*724ba675SRob Herring			pinctrl-0 = <&pinctrl_dhcom_i>;
140*724ba675SRob Herring			pinctrl-names = "default";
141*724ba675SRob Herring		};
142*724ba675SRob Herring	};
143*724ba675SRob Herring
144*724ba675SRob Herring	panel {
145*724ba675SRob Herring		backlight = <&display_bl>;
146*724ba675SRob Herring		compatible = "edt,etm0700g0edh6";
147*724ba675SRob Herring
148*724ba675SRob Herring		port {
149*724ba675SRob Herring			lcd_panel_in: endpoint {
150*724ba675SRob Herring				remote-endpoint = <&lcd_display_out>;
151*724ba675SRob Herring			};
152*724ba675SRob Herring		};
153*724ba675SRob Herring	};
154*724ba675SRob Herring
155*724ba675SRob Herring	sound {
156*724ba675SRob Herring		audio-codec = <&sgtl5000>;
157*724ba675SRob Herring		audio-routing =
158*724ba675SRob Herring			"MIC_IN", "Mic Jack",
159*724ba675SRob Herring			"Mic Jack", "Mic Bias",
160*724ba675SRob Herring			"LINE_IN", "Line In Jack",
161*724ba675SRob Herring			"Headphone Jack", "HP_OUT";
162*724ba675SRob Herring		compatible = "fsl,imx-audio-sgtl5000";
163*724ba675SRob Herring		model = "imx-sgtl5000";
164*724ba675SRob Herring		mux-ext-port = <3>;
165*724ba675SRob Herring		mux-int-port = <1>;
166*724ba675SRob Herring		ssi-controller = <&ssi1>;
167*724ba675SRob Herring	};
168*724ba675SRob Herring};
169*724ba675SRob Herring
170*724ba675SRob Herring&audmux {
171*724ba675SRob Herring	pinctrl-0 = <&pinctrl_audmux_ext>;
172*724ba675SRob Herring	pinctrl-names = "default";
173*724ba675SRob Herring	status = "okay";
174*724ba675SRob Herring};
175*724ba675SRob Herring
176*724ba675SRob Herring&can1 {
177*724ba675SRob Herring	status = "okay";
178*724ba675SRob Herring};
179*724ba675SRob Herring
180*724ba675SRob Herring&can2 {
181*724ba675SRob Herring	status = "disabled";
182*724ba675SRob Herring};
183*724ba675SRob Herring
184*724ba675SRob Herring/* 1G ethernet */
185*724ba675SRob Herring/delete-node/ &ethphy0;
186*724ba675SRob Herring&fec {
187*724ba675SRob Herring	phy-mode = "rgmii";
188*724ba675SRob Herring	phy-handle = <&ethphy7>;
189*724ba675SRob Herring	pinctrl-0 = <&pinctrl_enet_1G>;
190*724ba675SRob Herring	pinctrl-names = "default";
191*724ba675SRob Herring	status = "okay";
192*724ba675SRob Herring
193*724ba675SRob Herring	mdio {
194*724ba675SRob Herring		#address-cells = <1>;
195*724ba675SRob Herring		#size-cells = <0>;
196*724ba675SRob Herring
197*724ba675SRob Herring		ethphy7: ethernet-phy@7 { /* KSZ 9021 */
198*724ba675SRob Herring			compatible = "ethernet-phy-ieee802.3-c22";
199*724ba675SRob Herring			interrupt-parent = <&gpio1>;
200*724ba675SRob Herring			interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
201*724ba675SRob Herring			pinctrl-0 = <&pinctrl_ethphy7>;
202*724ba675SRob Herring			pinctrl-names = "default";
203*724ba675SRob Herring			reg = <7>;
204*724ba675SRob Herring			reset-assert-us = <1000>;
205*724ba675SRob Herring			reset-deassert-us = <1000>;
206*724ba675SRob Herring			reset-gpios = <&gpio3 29 GPIO_ACTIVE_LOW>;
207*724ba675SRob Herring			rxc-skew-ps = <3000>;
208*724ba675SRob Herring			rxd0-skew-ps = <0>;
209*724ba675SRob Herring			rxd1-skew-ps = <0>;
210*724ba675SRob Herring			rxd2-skew-ps = <0>;
211*724ba675SRob Herring			rxd3-skew-ps = <0>;
212*724ba675SRob Herring			rxdv-skew-ps = <0>;
213*724ba675SRob Herring			txc-skew-ps = <3000>;
214*724ba675SRob Herring			txd0-skew-ps = <0>;
215*724ba675SRob Herring			txd1-skew-ps = <0>;
216*724ba675SRob Herring			txd2-skew-ps = <0>;
217*724ba675SRob Herring			txd3-skew-ps = <0>;
218*724ba675SRob Herring			txen-skew-ps = <0>;
219*724ba675SRob Herring		};
220*724ba675SRob Herring	};
221*724ba675SRob Herring};
222*724ba675SRob Herring
223*724ba675SRob Herring&hdmi {
224*724ba675SRob Herring	ddc-i2c-bus = <&i2c2>;
225*724ba675SRob Herring	status = "okay";
226*724ba675SRob Herring};
227*724ba675SRob Herring
228*724ba675SRob Herring&i2c2 {
229*724ba675SRob Herring	sgtl5000: codec@a {
230*724ba675SRob Herring		#sound-dai-cells = <0>;
231*724ba675SRob Herring		clocks = <&clk_ext_audio_codec>;
232*724ba675SRob Herring		compatible = "fsl,sgtl5000";
233*724ba675SRob Herring		reg = <0x0a>;
234*724ba675SRob Herring		VDDA-supply = <&reg_3p3v>;
235*724ba675SRob Herring		VDDIO-supply = <&sw2_reg>;
236*724ba675SRob Herring	};
237*724ba675SRob Herring
238*724ba675SRob Herring	touchscreen@38 {
239*724ba675SRob Herring		compatible = "edt,edt-ft5406";
240*724ba675SRob Herring		interrupt-parent = <&gpio4>;
241*724ba675SRob Herring		interrupts = <5 IRQ_TYPE_EDGE_FALLING>; /* GPIO E */
242*724ba675SRob Herring		pinctrl-0 = <&pinctrl_dhcom_e>;
243*724ba675SRob Herring		pinctrl-names = "default";
244*724ba675SRob Herring		reg = <0x38>;
245*724ba675SRob Herring	};
246*724ba675SRob Herring};
247*724ba675SRob Herring
248*724ba675SRob Herring&ipu1_di0_disp0 {
249*724ba675SRob Herring	remote-endpoint = <&lcd_display_in>;
250*724ba675SRob Herring};
251*724ba675SRob Herring
252*724ba675SRob Herring&pcie {
253*724ba675SRob Herring	pinctrl-0 = <&pinctrl_pcie &pinctrl_dhcom_j>;
254*724ba675SRob Herring	reset-gpio = <&gpio6 14 GPIO_ACTIVE_LOW>; /* GPIO J */
255*724ba675SRob Herring	status = "okay";
256*724ba675SRob Herring};
257*724ba675SRob Herring
258*724ba675SRob Herring&pwm1 {
259*724ba675SRob Herring	status = "okay";
260*724ba675SRob Herring};
261*724ba675SRob Herring
262*724ba675SRob Herring&ssi1 {
263*724ba675SRob Herring	status = "okay";
264*724ba675SRob Herring};
265*724ba675SRob Herring
266*724ba675SRob Herring&usbh1 {
267*724ba675SRob Herring	disable-over-current;
268*724ba675SRob Herring};
269*724ba675SRob Herring
270*724ba675SRob Herring&usdhc2 { /* SD card */
271*724ba675SRob Herring	status = "okay";
272*724ba675SRob Herring};
273*724ba675SRob Herring
274*724ba675SRob Herring&iomuxc {
275*724ba675SRob Herring	pinctrl-0 = <
276*724ba675SRob Herring			/*
277*724ba675SRob Herring			 * The following DHCOM GPIOs are used on this board.
278*724ba675SRob Herring			 * Therefore, they have been removed from the list below.
279*724ba675SRob Herring			 * A: key TA1
280*724ba675SRob Herring			 * B: key TA2
281*724ba675SRob Herring			 * C: key TA3
282*724ba675SRob Herring			 * D: key TA4
283*724ba675SRob Herring			 * E: touchscreen
284*724ba675SRob Herring			 * F: led6
285*724ba675SRob Herring			 * G: backlight enable
286*724ba675SRob Herring			 * H: led7
287*724ba675SRob Herring			 * I: led8
288*724ba675SRob Herring			 * J: PCIe reset
289*724ba675SRob Herring			 */
290*724ba675SRob Herring			&pinctrl_hog_base
291*724ba675SRob Herring			&pinctrl_dhcom_k &pinctrl_dhcom_l
292*724ba675SRob Herring			&pinctrl_dhcom_m &pinctrl_dhcom_n &pinctrl_dhcom_o
293*724ba675SRob Herring			&pinctrl_dhcom_p &pinctrl_dhcom_q &pinctrl_dhcom_r
294*724ba675SRob Herring			&pinctrl_dhcom_s &pinctrl_dhcom_t &pinctrl_dhcom_u
295*724ba675SRob Herring			&pinctrl_dhcom_v &pinctrl_dhcom_w &pinctrl_dhcom_int
296*724ba675SRob Herring		>;
297*724ba675SRob Herring	pinctrl-names = "default";
298*724ba675SRob Herring
299*724ba675SRob Herring	pinctrl_audmux_ext: audmux-ext-grp {
300*724ba675SRob Herring		fsl,pins = <
301*724ba675SRob Herring			MX6QDL_PAD_CSI0_DAT4__AUD3_TXC		0x130b0
302*724ba675SRob Herring			MX6QDL_PAD_CSI0_DAT5__AUD3_TXD		0x110b0
303*724ba675SRob Herring			MX6QDL_PAD_CSI0_DAT6__AUD3_TXFS		0x130b0
304*724ba675SRob Herring			MX6QDL_PAD_CSI0_DAT7__AUD3_RXD		0x130b0
305*724ba675SRob Herring		>;
306*724ba675SRob Herring	};
307*724ba675SRob Herring
308*724ba675SRob Herring	pinctrl_enet_1G: enet-1G-grp {
309*724ba675SRob Herring		fsl,pins = <
310*724ba675SRob Herring			MX6QDL_PAD_ENET_MDC__ENET_MDC		0x100b0
311*724ba675SRob Herring			MX6QDL_PAD_ENET_MDIO__ENET_MDIO		0x100b0
312*724ba675SRob Herring			MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK	0x100b0
313*724ba675SRob Herring			MX6QDL_PAD_RGMII_RD0__RGMII_RD0		0x1b0b0
314*724ba675SRob Herring			MX6QDL_PAD_RGMII_RD1__RGMII_RD1		0x1b0b0
315*724ba675SRob Herring			MX6QDL_PAD_RGMII_RD2__RGMII_RD2		0x1b0b0
316*724ba675SRob Herring			MX6QDL_PAD_RGMII_RD3__RGMII_RD3		0x1b0b0
317*724ba675SRob Herring			MX6QDL_PAD_RGMII_RX_CTL__RGMII_RX_CTL	0x1b0b0
318*724ba675SRob Herring			MX6QDL_PAD_RGMII_RXC__RGMII_RXC		0x1b0b0
319*724ba675SRob Herring			MX6QDL_PAD_RGMII_TD0__RGMII_TD0		0x100b0
320*724ba675SRob Herring			MX6QDL_PAD_RGMII_TD1__RGMII_TD1		0x100b0
321*724ba675SRob Herring			MX6QDL_PAD_RGMII_TD2__RGMII_TD2		0x100b0
322*724ba675SRob Herring			MX6QDL_PAD_RGMII_TD3__RGMII_TD3		0x100b0
323*724ba675SRob Herring			MX6QDL_PAD_RGMII_TX_CTL__RGMII_TX_CTL	0x100b0
324*724ba675SRob Herring			MX6QDL_PAD_RGMII_TXC__RGMII_TXC		0x100b0
325*724ba675SRob Herring		>;
326*724ba675SRob Herring	};
327*724ba675SRob Herring
328*724ba675SRob Herring	pinctrl_ethphy7: ethphy7-grp {
329*724ba675SRob Herring		fsl,pins = <
330*724ba675SRob Herring			MX6QDL_PAD_EIM_D26__GPIO3_IO26		0xb1 /* WOL */
331*724ba675SRob Herring			MX6QDL_PAD_EIM_D29__GPIO3_IO29		0xb0 /* Reset */
332*724ba675SRob Herring			MX6QDL_PAD_GPIO_0__GPIO1_IO00		0xb1 /* Int */
333*724ba675SRob Herring		>;
334*724ba675SRob Herring	};
335*724ba675SRob Herring};
336