ARM: dts: imx6q-apalis: Add LVDS panel support
[platform/kernel/linux-starfive.git] / arch / arm / boot / dts / imx6q-apalis-eval.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /*
3  * Copyright 2014-2022 Toradex
4  * Copyright 2012 Freescale Semiconductor, Inc.
5  * Copyright 2011 Linaro Ltd.
6  */
7
8 /dts-v1/;
9
10 #include <dt-bindings/gpio/gpio.h>
11 #include <dt-bindings/input/input.h>
12 #include <dt-bindings/interrupt-controller/irq.h>
13 #include "imx6q.dtsi"
14 #include "imx6qdl-apalis.dtsi"
15
16 / {
17         model = "Toradex Apalis iMX6Q/D Module on Apalis Evaluation Board";
18         compatible = "toradex,apalis_imx6q-eval", "toradex,apalis_imx6q",
19                      "fsl,imx6q";
20
21         aliases {
22                 i2c0 = &i2c1;
23                 i2c1 = &i2c3;
24                 i2c2 = &i2c2;
25                 rtc0 = &rtc_i2c;
26                 rtc1 = &snvs_rtc;
27         };
28
29         chosen {
30                 stdout-path = "serial0:115200n8";
31         };
32
33         reg_pcie_switch: regulator-pcie-switch {
34                 compatible = "regulator-fixed";
35                 regulator-name = "pcie_switch";
36                 regulator-min-microvolt = <1800000>;
37                 regulator-max-microvolt = <1800000>;
38                 gpio = <&gpio1 2 GPIO_ACTIVE_HIGH>;
39                 startup-delay-us = <100000>;
40                 enable-active-high;
41                 status = "okay";
42         };
43
44         reg_3v3_sw: regulator-3v3-sw {
45                 compatible = "regulator-fixed";
46                 regulator-name = "3.3V_SW";
47                 regulator-min-microvolt = <3300000>;
48                 regulator-max-microvolt = <3300000>;
49                 regulator-always-on;
50         };
51 };
52
53 &can1 {
54         xceiver-supply = <&reg_3v3_sw>;
55         status = "okay";
56 };
57
58 &can2 {
59         xceiver-supply = <&reg_3v3_sw>;
60         status = "okay";
61 };
62
63 &hdmi {
64         status = "okay";
65 };
66
67 /* I2C1_SDA/SCL on MXM3 209/211 (e.g. RTC on carrier board) */
68 &i2c1 {
69         status = "okay";
70
71         pcie-switch@58 {
72                 compatible = "plx,pex8605";
73                 reg = <0x58>;
74         };
75
76         /* M41T0M6 real time clock on carrier board */
77         rtc_i2c: rtc@68 {
78                 compatible = "st,m41t0";
79                 reg = <0x68>;
80         };
81 };
82
83 /*
84  * I2C3_SDA/SCL (CAM) on MXM3 pin 201/203 (e.g. camera sensor on carrier
85  * board)
86  */
87 &i2c3 {
88         status = "okay";
89 };
90
91 &pcie {
92         pinctrl-names = "default";
93         pinctrl-0 = <&pinctrl_reset_moci>;
94         /* active-high meaning opposite of regular PERST# active-low polarity */
95         reset-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;
96         reset-gpio-active-high;
97         vpcie-supply = <&reg_pcie_switch>;
98         status = "okay";
99 };
100
101 &pwm1 {
102         status = "okay";
103 };
104
105 &pwm2 {
106         status = "okay";
107 };
108
109 &pwm3 {
110         status = "okay";
111 };
112
113 &pwm4 {
114         status = "okay";
115 };
116
117 &reg_usb_otg_vbus {
118         status = "okay";
119 };
120
121 &reg_usb_host_vbus {
122         status = "okay";
123 };
124
125 &sata {
126         status = "okay";
127 };
128
129 &sound_spdif {
130         status = "okay";
131 };
132
133 &spdif {
134         status = "okay";
135 };
136
137 &uart1 {
138         status = "okay";
139 };
140
141 &uart2 {
142         status = "okay";
143 };
144
145 &uart4 {
146         status = "okay";
147 };
148
149 &uart5 {
150         status = "okay";
151 };
152
153 &usbh1 {
154         vbus-supply = <&reg_usb_host_vbus>;
155         status = "okay";
156 };
157
158 &usbotg {
159         vbus-supply = <&reg_usb_otg_vbus>;
160         status = "okay";
161 };
162
163 /* MMC1 */
164 &usdhc1 {
165         pinctrl-names = "default";
166         pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_usdhc1_8bit &pinctrl_mmc_cd>;
167         cd-gpios = <&gpio4 20 GPIO_ACTIVE_LOW>;
168         status = "okay";
169 };
170
171 /* SD1 */
172 &usdhc2 {
173         pinctrl-names = "default";
174         pinctrl-0 = <&pinctrl_usdhc2 &pinctrl_sd_cd>;
175         cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
176         status = "okay";
177 };