summaryrefslogtreecommitdiff
path: root/arch/arm64/boot/dts/freescale/fsl-imx8qxp-colibri-eval-v3.dts
blob: 187fc6e297d7cbefe803194d6fc88a4869a49639 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
// SPDX-License-Identifier: GPL-2.0+ OR X11
/*
 * Copyright 2018-2019 Toradex
 */

/dts-v1/;

/*
 * Choose output point for LCDIF block:
 * By default use LCD Panel driver:
 * - Panel connected to
 *   - Generic Display Connector X20;
 *   - Unified Interface Display Connector X34;
 * OR
 * - VGA monitor connected to X24.
 *
 * Define LCDIF_OUT_ADV7125 to use ONLY (!) VGA monitor connected to X24
 * with our without DDC channel to use higher resolutions.
 *
 * NOTE: LCDIF output to LVDS transmitter is not supported for now.
 */
//#define LCDIF_OUT_ADV7125

#include "dt-bindings/pwm/pwm.h"
#include "fsl-imx8qxp-colibri.dtsi"

/ {
	model = "Toradex Colibri iMX8QXP/DX on Colibri Evaluation Board V3";
	compatible = "toradex,colibri-imx8qxp-eval-v3", "toradex,colibri-imx8qxp", "fsl,imx8qxp";

	aliases {
		rtc0 = &rtc_i2c;
		rtc1 = &rtc;
	};

	display-subsystem {
		status = "disabled";
	};

	extcon_usbc_det: usbc_det {
		compatible = "linux,extcon-usb-gpio";
		debounce = <25>;
		id-gpio = <&gpio5 9 GPIO_ACTIVE_HIGH>;
		pinctrl-names = "default";
		pinctrl-0 = <&pinctrl_usbc_det>;
	};

		compatible = "pwm-backlight";
		pinctrl-names = "default";
		pinctrl-0 = <&pinctrl_gpio_bl_on>;
		gpios = <&gpio3 12 GPIO_ACTIVE_HIGH>; /* BKL1_ON */
		pwms = <&pwm_adma_lcdif 0 100000 PWM_POLARITY_INVERTED>;

		brightness-levels = <0 4 8 16 32 64 128 255>;
		default-brightness-level = <6>;
		status = "okay";
	};

	panel {
		compatible = "edt,et070080dh6";
		backlight = <&backlight>;
		enable-gpios = <&gpio4 19 GPIO_ACTIVE_HIGH>;

		port {
			lcd_display_in: endpoint {
				remote-endpoint = <&lcdif_out>;
			};
		};
	};
#else
	vga {
		compatible = "vga-connector";
		label = "vga";
		status = "okay";

		port {
			vga_in: endpoint {
				remote-endpoint = <&adv7125_out>;
			};
		};
	};

	vga-encoder {
		compatible = "adi,adv7125", "adi,adv7123";
		status = "okay";
		vdd-supply = <&vdd_3v3_vga>;

		ports {
			#address-cells = <1>;
			#size-cells = <0>;

			port@0 {
				reg = <0>;
				lcd_display_in: endpoint {
					remote-endpoint = <&lcdif_out>;
				};
			};
			port@1 {
				reg = <1>;
				adv7125_out: endpoint {
					remote-endpoint = <&vga_in>;
				};
			};
		};
	};
#endif

	regulators {
		reg_usbh_vbus: regulator-usbh-vbus {
			compatible = "regulator-fixed";
			pinctrl-names = "default";
			pinctrl-0 = <&pinctrl_usbh1_reg>;
			regulator-name = "usbh_vbus";
			regulator-min-microvolt = <5000000>;
			regulator-max-microvolt = <5000000>;
			gpio = <&gpio4 3 GPIO_ACTIVE_LOW>;
			regulator-always-on;
		};
	};
};

&adma_lcdif {
	pinctrl-names = "default";
	/* Dumb DAC to VGA converter doesn't support backlight, so
	 * instead use enable-gpios for LCDIF driver for this configuration
	 */
#ifndef LCDIF_OUT_ADV7125
	pinctrl-0 = <&pinctrl_lcdif>;
#else
	pinctrl-0 = <&pinctrl_lcdif &pinctrl_gpio_bl_on>;
	enable-gpios = <&gpio3 12 GPIO_ACTIVE_HIGH>; /* BKL1_ON */
	pinctrl-assert-gpios = <&gpio4 19 GPIO_ACTIVE_HIGH>;
#endif
	/* By default, Colibri iMX8QXP uses 18-bits output bus for eLCDIF.
	 * However, you can configure it to support 24-bits output.
	 * "X20 Generic Display Connector" of Colibri Evaluation Board v3.2
	 * supports 24-bits mode.
	 */
	bus-width = <18>;
	status = "okay";

	port@0 {
		lcdif_out: lcdif-endpoint {
			remote-endpoint = <&lcd_display_in>;
		};
	};
};

/* DSI/LVDS port 0 */
&i2c0_mipi_lvds0 {
	#address-cells = <1>;
	#size-cells = <0>;
	pinctrl-names = "default";
	pinctrl-0 = <&pinctrl_i2c0_mipi_lvds0>;
	clock-frequency = <100000>;
	status = "disabled";
};
/* On-module MIPI CSI I2C accessible on FFC (X3) */
&i2c0_mipi_lvds1 {
	status = "okay";

	ov5640_mipi: ov5640_mipi@3c {
		compatible = "ovti,ov5640_mipi_v3";
		clocks = <&clk IMX8QXP_24MHZ>;
		clock-names = "csi_mclk";
		csi_id = <0>;
		mclk = <24000000>;
		mclk_source = <0>;
		mipi_csi;
		pinctrl-names = "default";
		pinctrl-0 = <&pinctrl_csi_ctl>;
		pwn-gpios = <&gpio3 14 GPIO_ACTIVE_HIGH>;
		reg = <0x3c>;
		rst-gpios = <&gpio3 15 GPIO_ACTIVE_LOW>;
		status = "okay";

		port {
			ov5640_ep: endpoint {
				remote-endpoint = <&mipi_csi0_ep>;
			};
		};
	};
};

&ldb1 {
	status = "disabled";
};

&ldb1_phy {
	status = "disabled";
};

/* Colibri SPI */
&lpspi2 {
	status = "okay";

	spidev0: spidev@0 {
		compatible = "toradex,evalspi";
		reg = <0>;
		spi-max-frequency = <10000000>;
	};
};

/* On-module MIPI CSI accessible via FFC (X3) */
&mipi_csi_0 {
	status = "okay";

	/* Camera 0 MIPI CSI-2 (CSIS0) */
	port@0 {
		reg = <0>;

		mipi_csi0_ep: endpoint {
			data-lanes = <1 2>;
			remote-endpoint = <&ov5640_ep>;
		};
	};
};

&i2c1 {
	status = "okay";

	/* M41T0M6 real time clock on carrier board */
	rtc_i2c: rtc@68 {
		compatible = "st,m41t0";
		reg = <0x68>;
	};
};

&ldb2_phy {
	status = "disabled";
};

&ldb2 {
	status = "disabled";

	lvds-channel@0 {
		fsl,data-mapping = "jeida";
		fsl,data-width = <24>;
		status = "okay";
	};
};

&pwm_adma_lcdif {
	pinctrl-names = "default";
	pinctrl-0 = <&pinctrl_pwm_a>;
	status = "okay";
};

&usbotg1 {
	extcon = <&extcon_usbc_det &extcon_usbc_det>;
	vbus-supply = <&reg_usbh_vbus>;
	srp-disable;
	hnp-disable;
	adp-disable;
	power-polarity-active-high;
	disable-over-current;
	status = "okay";
};

&usbotg3 {
	dr_mode = "host";
	status = "okay";
};