]> git.kernelconcepts.de Git - meta-kc-bsp.git/blob - recipes-kernel/linux/linux-karo-4.9.11/txbase/aclavis/txbase-aclavis.dtsi
linux-karo: Add initial version of linux-karo 4.9.11 based on NXP kernel tree
[meta-kc-bsp.git] / recipes-kernel / linux / linux-karo-4.9.11 / txbase / aclavis / txbase-aclavis.dtsi
1 /*
2  * Copyright 2016 Lothar Waßmann <LW@KARO-electronics.de>
3  * Copyright 2017 Oliver Wendt <OW@KARO-electronics.de>
4  * Copyright 2017 Michael Vyskocil <MV@KARO-electronics.de>
5  *
6  * This file is dual-licensed: you can use it either under the terms
7  * of the GPL or the X11 license, at your option. Note that this dual
8  * licensing only applies to this file, and not this project as a
9  * whole.
10  *
11  *  a) This file is free software; you can redistribute it and/or
12  *     modify it under the terms of the GNU General Public License
13  *     version 2 as published by the Free Software Foundation.
14  *
15  *     This file is distributed in the hope that it will be useful,
16  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
17  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  *     GNU General Public License for more details.
19  *
20  * Or, alternatively,
21  *
22  *  b) Permission is hereby granted, free of charge, to any person
23  *     obtaining a copy of this software and associated documentation
24  *     files (the "Software"), to deal in the Software without
25  *     restriction, including without limitation the rights to use,
26  *     copy, modify, merge, publish, distribute, sublicense, and/or
27  *     sell copies of the Software, and to permit persons to whom the
28  *     Software is furnished to do so, subject to the following
29  *     conditions:
30  *
31  *     The above copyright notice and this permission notice shall be
32  *     included in all copies or substantial portions of the Software.
33  *
34  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
35  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
36  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
37  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
38  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
39  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
40  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
41  *     OTHER DEALINGS IN THE SOFTWARE.
42  */
43
44 /*
45  * Please be reminded that in general DTSI file(s) are include files that are
46  * for more than one purpose (usually bound to a SoC) and as such shouldn't be
47  * edited. For end-user products it should be the DTS file(s) that choose which
48  * devices and pins are active and setup.
49  *
50  * The setup of DT files for Ka-Ro TX COM Modules under Yocto follow a
51  * different, non-standard, implementation, which can make it necessary.
52  */
53
54 /*
55  * Please see the imx6*-tx6-gpio.h && imx6*-tx6.dtsi in "linux-karo-x.y.ab/tx6"
56  * for the definitions like TX_NAND or TX_EMMC, etc.
57  */
58
59 / {
60         aliases {
61                 backlight = &backlight0;
62                 backlight0 = &backlight0;
63                 /*
64                  * The node/alias 'display' is needed for U-Boot to be able to
65                  * show a logo/splash image at boot time. It needs to include
66                  * 'display-timings' as direct sub-node.
67                  */
68                 display = TX_LCD;
69                 mxcfb0 = TX_LCD_FB;
70         };
71
72         backlight0: backlight0 {
73                 compatible = "pwm-backlight";
74                 pwms = <TX_PWM 0 500000>;
75                 power-supply = <&reg_lcd0_pwr>;
76                 /*
77                 * a poor man's way to create a 1:1 relationship between
78                 * the PWM value and the actual duty cycle
79                 */
80                 brightness-levels = < 0  1  2  3  4  5  6  7  8  9
81                                      10 11 12 13 14 15 16 17 18 19
82                                      20 21 22 23 24 25 26 27 28 29
83                                      30 31 32 33 34 35 36 37 38 39
84                                      40 41 42 43 44 45 46 47 48 49
85                                      50 51 52 53 54 55 56 57 58 59
86                                      60 61 62 63 64 65 66 67 68 69
87                                      70 71 72 73 74 75 76 77 78 79
88                                      80 81 82 83 84 85 86 87 88 89
89                                      90 91 92 93 94 95 96 97 98 99
90                                     100>;
91                 default-brightness-level = <50>;
92                 status = "disabled";
93         };
94
95         leds {
96                 compatible = "gpio-leds";
97                 pinctrl-names = "default";
98                 pinctrl-0 = <&pinctrl_gpio_leds>;
99
100                 user_led: user {
101                         label = "Heartbeat";
102                         gpios = <TX_GPIO_PIN153 GPIO_ACTIVE_HIGH>;
103                         linux,default-trigger = "heartbeat";
104                 };
105         };
106
107         regulators {
108                 reg_lcd0_pwr: regulator-lcd-power {
109                         compatible = "regulator-fixed";
110                         regulator-name = "LCD0 RESET";
111                         regulator-min-microvolt = <3300000>;
112                         regulator-max-microvolt = <3300000>;
113                         pinctrl-names = "default";
114                         pinctrl-0 = <&pinctrl_lcd0_pwr>;
115                         gpio = <TX_GPIO_PIN150 GPIO_ACTIVE_HIGH>;
116                         enable-active-high;
117                         regulator-boot-on;
118                         regulator-always-on;
119                 };
120         };
121 };
122
123 TX_CAN1 {
124         status = "okay";
125 };
126
127 TX_I2C {
128         status = "okay";
129
130         polytouch: edt-ft5x06@38 {
131                 compatible = "edt,edt-ft5x06";
132                 reg = <0x38>;
133                 pinctrl-names = "default";
134                 pinctrl-0 = <&pinctrl_edt_ft5x06>;
135                 interrupts-extended = <TX_GPIO_PIN148 0>;
136                 reset-gpios = <TX_GPIO_PIN149 GPIO_ACTIVE_LOW>;
137                 wake-gpios = <TX_GPIO_PIN152 GPIO_ACTIVE_HIGH>;
138                 linux,wakeup;
139         };
140 };
141
142 TX_LCD {
143 /*
144  * The node/alias 'display' is needed for U-Boot to be able to show a
145  * logo/splash image at boot time. It needs to include 'display-timings'
146  * as direct sub-node.
147  *
148  * Other naming is only needed for the NXP/Freescale non-mainline
149  * compliant/proprietary display driver in their Yocto 4.1 Kernel
150  * implementation.
151  */
152         compatible = "fsl,lcd";
153         ipu_id = <0>;
154         disp_id = <0>;
155         default_ifmt = "RGB565";
156         pinctrl-names = "default";
157         pinctrl-0 = <&pinctrl_ipu1>;
158         status = "disabled";
159         display-timings {
160                 VGA {
161                         clock-frequency = <25200000>;
162                         hactive = <640>;
163                         vactive = <480>;
164                         hback-porch = <48>;
165                         hsync-len = <96>;
166                         hfront-porch = <16>;
167                         vback-porch = <31>;
168                         vsync-len = <2>;
169                         vfront-porch = <12>;
170                         hsync-active = <0>;
171                         vsync-active = <0>;
172                         de-active = <1>;
173                         pixelclk-active = <0>;
174                 };
175
176                 ETV570 {
177                         clock-frequency = <25200000>;
178                         hactive = <640>;
179                         vactive = <480>;
180                         hback-porch = <114>;
181                         hsync-len = <30>;
182                         hfront-porch = <16>;
183                         vback-porch = <32>;
184                         vsync-len = <3>;
185                         vfront-porch = <10>;
186                         hsync-active = <0>;
187                         vsync-active = <0>;
188                         de-active = <1>;
189                         pixelclk-active = <0>;
190                 };
191
192                 ET0350 {
193                         clock-frequency = <6413760>;
194                         hactive = <320>;
195                         vactive = <240>;
196                         hback-porch = <34>;
197                         hsync-len = <34>;
198                         hfront-porch = <20>;
199                         vback-porch = <15>;
200                         vsync-len = <3>;
201                         vfront-porch = <4>;
202                         hsync-active = <0>;
203                         vsync-active = <0>;
204                         de-active = <1>;
205                         pixelclk-active = <0>;
206                 };
207
208                 ET0430 {
209                         clock-frequency = <9009000>;
210                         hactive = <480>;
211                         vactive = <272>;
212                         hback-porch = <2>;
213                         hsync-len = <41>;
214                         hfront-porch = <2>;
215                         vback-porch = <2>;
216                         vsync-len = <10>;
217                         vfront-porch = <2>;
218                         hsync-active = <0>;
219                         vsync-active = <0>;
220                         de-active = <1>;
221                         pixelclk-active = <1>;
222                 };
223
224                 ET0500 {
225                         clock-frequency = <33264000>;
226                         hactive = <800>;
227                         vactive = <480>;
228                         hback-porch = <88>;
229                         hsync-len = <128>;
230                         hfront-porch = <40>;
231                         vback-porch = <33>;
232                         vsync-len = <2>;
233                         vfront-porch = <10>;
234                         hsync-active = <0>;
235                         vsync-active = <0>;
236                         de-active = <1>;
237                         pixelclk-active = <0>;
238                 };
239
240                 ET0700 { /* same as ET0500 */
241                         clock-frequency = <33264000>;
242                         hactive = <800>;
243                         vactive = <480>;
244                         hback-porch = <88>;
245                         hsync-len = <128>;
246                         hfront-porch = <40>;
247                         vback-porch = <33>;
248                         vsync-len = <2>;
249                         vfront-porch = <10>;
250                         hsync-active = <0>;
251                         vsync-active = <0>;
252                         de-active = <1>;
253                         pixelclk-active = <0>;
254                 };
255
256                 ETQ570 {
257                         clock-frequency = <6596040>;
258                         hactive = <320>;
259                         vactive = <240>;
260                         hback-porch = <38>;
261                         hsync-len = <30>;
262                         hfront-porch = <30>;
263                         vback-porch = <16>;
264                         vsync-len = <3>;
265                         vfront-porch = <4>;
266                         hsync-active = <0>;
267                         vsync-active = <0>;
268                         de-active = <1>;
269                         pixelclk-active = <0>;
270                 };
271         };
272 };
273
274 TX_LCD_FB {
275         compatible = "fsl,mxc_sdc_fb";
276         disp_dev = "lcd";
277         interface_pix_fmt = "RGB24";
278         default_bpp = <16>;
279         int_clk = <0>;
280         late_init = <0>;
281         status = "disabled";
282 };
283
284 TX_PWM {
285         status = "okay";
286 };
287
288 TX_SD1 {
289         status = "okay";
290 };
291
292 TX_UART1 {
293         status = "okay";
294 };
295
296 TX_UART2 {
297         status = "okay";
298         fsl,uart-has-rtscts;
299         uart-has-rtscts;
300 };
301
302 TX_USBH {
303         status = "okay";
304 };
305
306 TX_USBOTG {
307         status = "okay";
308 };
309
310 &iomuxc {
311         tx6 {
312                 pinctrl_edt_ft5x06: edt-ft5x06grp {
313                         fsl,pins = <
314                                 TX_GPIO_PAD148          /* Interrupt */
315                                 TX_GPIO_PAD149          /* Reset */
316                                 TX_GPIO_PAD152          /* Wake */
317                         >;
318                 };
319
320                 pinctrl_gpio_leds: gpioledsgrp {
321                         fsl,pins = <
322                                 TX_GPIO_PAD153          /* LED Heartbeat */
323                         >;
324                 };
325
326                 pinctrl_lcd0_pwr: lcd0-pwrgrp {
327                         fsl,pins = <
328                                 TX_GPIO_PAD150          /* LCD Reset */
329                         >;
330                 };
331         };
332 };