Merge remote-tracking branch 'regmap/for-5.7' into regmap-linus
[linux-2.6-microblaze.git] / arch / arm / boot / dts / at91-sama5d27_wlsom1_ek.dts
1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2 /*
3  * at91-sama5d27_wlsom1_ek.dts - Device Tree file for SAMA5D27 WLSOM1 EK
4  *
5  * Copyright (C) 2019 Microchip Technology Inc. and its subsidiaries
6  *
7  * Author: Nicolas Ferre <nicolas.ferre@microcihp.com>
8  */
9 /dts-v1/;
10 #include "at91-sama5d27_wlsom1.dtsi"
11
12 / {
13         model = "Microchip SAMA5D27 WLSOM1 EK";
14         compatible = "microchip,sama5d27-wlsom1-ek", "microchip,sama5d27-wlsom1", "atmel,sama5d27", "atmel,sama5d2", "atmel,sama5";
15
16         aliases {
17                 serial0 = &uart0;       /* DBGU */
18                 serial1 = &uart6;       /* BT */
19                 serial2 = &uart5;       /* mikro BUS 2 */
20                 serial3 = &uart3;       /* mikro BUS 1 */
21                 i2c1    = &i2c1;
22         };
23
24         chosen {
25                 stdout-path = "serial0:115200n8";
26         };
27
28         gpio_keys {
29                 compatible = "gpio-keys";
30
31                 pinctrl-names = "default";
32                 pinctrl-0 = <&pinctrl_key_gpio_default>;
33                 status = "okay";
34
35                 sw4 {
36                         label = "USER BUTTON";
37                         gpios = <&pioA PIN_PB2 GPIO_ACTIVE_LOW>;
38                         linux,code = <0x104>;
39                         wakeup-source;
40                 };
41         };
42
43         leds {
44                 compatible = "gpio-leds";
45                 pinctrl-names = "default";
46                 pinctrl-0 = <&pinctrl_led_gpio_default>;
47                 status = "okay";
48
49                 red {
50                         label = "red";
51                         gpios = <&pioA PIN_PA6 GPIO_ACTIVE_HIGH>;
52                 };
53
54                 green {
55                         label = "green";
56                         gpios = <&pioA PIN_PA7 GPIO_ACTIVE_HIGH>;
57                 };
58
59                 blue {
60                         label = "blue";
61                         gpios = <&pioA PIN_PA8 GPIO_ACTIVE_HIGH>;
62                         linux,default-trigger = "heartbeat";
63                 };
64         };
65 };
66
67 &adc {
68         vddana-supply = <&vdd_3v3>;
69         vref-supply = <&vdd_3v3>;
70         pinctrl-names = "default";
71         pinctrl-0 = <&pinctrl_adc_default>;
72         status = "okay";
73 };
74
75 &flx0 {
76         atmel,flexcom-mode = <ATMEL_FLEXCOM_MODE_USART>;
77         status = "okay";
78
79         uart5: serial@200 {
80                 compatible = "atmel,at91sam9260-usart";
81                 reg = <0x200 0x200>;
82                 interrupts = <19 IRQ_TYPE_LEVEL_HIGH 7>;
83                 dmas = <&dma0
84                         (AT91_XDMAC_DT_MEM_IF(0) | AT91_XDMAC_DT_PER_IF(1) |
85                          AT91_XDMAC_DT_PERID(11))>,
86                        <&dma0
87                         (AT91_XDMAC_DT_MEM_IF(0) | AT91_XDMAC_DT_PER_IF(1) |
88                          AT91_XDMAC_DT_PERID(12))>;
89                 dma-names = "tx", "rx";
90                 clocks = <&pmc PMC_TYPE_PERIPHERAL 19>;
91                 clock-names = "usart";
92                 pinctrl-0 = <&pinctrl_flx0_default>;
93                 pinctrl-names = "default";
94                 atmel,use-dma-rx;
95                 atmel,use-dma-tx;
96                 status = "okay";
97         };
98 };
99
100 &flx1 {
101         status = "okay";
102
103         uart6: serial@200 {
104                 atmel,use-dma-rx;
105                 atmel,use-dma-tx;
106                 status = "okay";
107         };
108 };
109
110 &macb0 {
111         status = "okay";
112 };
113
114 &pioA {
115         /*
116          * There is no real pinmux for ADC, if the pin
117          * is not requested by another peripheral then
118          * the muxing is done when channel is enabled.
119          * Requesting pins for ADC is GPIO is
120          * encouraged to prevent conflicts and to
121          * disable bias in order to be in the same
122          * state when the pin is not muxed to the adc.
123          */
124         pinctrl_adc_default: adc_default {
125                 pinmux = <PIN_PD25__GPIO>,
126                          <PIN_PD26__GPIO>;
127                 bias-disable;
128         };
129
130         pinctrl_flx0_default: flx0_usart_default {
131                 pinmux = <PIN_PB28__FLEXCOM0_IO0>,
132                          <PIN_PB29__FLEXCOM0_IO1>;
133                 bias-disable;
134         };
135
136         pinctrl_key_gpio_default: key_gpio_default {
137                 pinmux = <PIN_PB2__GPIO>;
138                 bias-pull-up;
139         };
140
141         pinctrl_led_gpio_default: led_gpio_default {
142                 pinmux = <PIN_PA6__GPIO>,
143                          <PIN_PA7__GPIO>,
144                          <PIN_PA8__GPIO>;
145                 bias-pull-down;
146         };
147
148         pinctrl_sdmmc0_default: sdmmc0_default {
149                 cmd_data {
150                         pinmux = <PIN_PA1__SDMMC0_CMD>,
151                                  <PIN_PA2__SDMMC0_DAT0>,
152                                  <PIN_PA3__SDMMC0_DAT1>,
153                                  <PIN_PA4__SDMMC0_DAT2>,
154                                  <PIN_PA5__SDMMC0_DAT3>;
155                         bias-disable;
156                 };
157
158                 ck_cd_vddsel {
159                         pinmux = <PIN_PA0__SDMMC0_CK>,
160                                  <PIN_PA11__SDMMC0_VDDSEL>,
161                                  <PIN_PA12__SDMMC0_WP>,
162                                  <PIN_PA13__SDMMC0_CD>;
163                         bias-disable;
164                 };
165         };
166
167         pinctrl_uart0_default: uart0_default {
168                 pinmux = <PIN_PB26__URXD0>,
169                          <PIN_PB27__UTXD0>;
170                 bias-disable;
171         };
172
173         pinctrl_uart3_default: uart3_default {
174                 pinmux = <PIN_PB11__URXD3>,
175                          <PIN_PB12__UTXD3>;
176                 bias-disable;
177         };
178
179         pinctrl_pwm0_default: pwm0_default {
180                 pinmux = <PIN_PA31__PWML0>,
181                          <PIN_PA30__PWMH0>;
182                 bias-disable;
183         };
184
185         pinctrl_usb_default: usb_default {
186                 pinmux = <PIN_PA10__GPIO>;
187                 bias-disable;
188         };
189
190         pinctrl_usba_vbus: usba_vbus {
191                 pinmux = <PIN_PA16__GPIO>;
192                 bias-disable;
193         };
194 };
195
196 &pwm0 {
197         pinctrl-names = "default";
198         pinctrl-0 = <&pinctrl_pwm0_default>;
199         status = "okay";
200 };
201
202 &qspi1 {
203         status = "okay";
204
205         qspi1_flash: spi_flash@0 {
206                 status = "okay";
207         };
208 };
209
210 &sdmmc0 {
211         bus-width = <4>;
212         mmc-ddr-3_3v;
213         pinctrl-names = "default";
214         pinctrl-0 = <&pinctrl_sdmmc0_default>;
215         status = "okay";
216 };
217
218 &shutdown_controller {
219         atmel,shdwc-debouncer = <976>;
220         atmel,wakeup-rtc-timer;
221
222         input@0 {
223                 reg = <0>;
224                 atmel,wakeup-type = "low";
225         };
226 };
227
228 &tcb0 {
229         timer0: timer@0 {
230                 compatible = "atmel,tcb-timer";
231                 reg = <0>;
232         };
233
234         timer1: timer@1 {
235                 compatible = "atmel,tcb-timer";
236                 reg = <1>;
237         };
238 };
239
240 &uart0 {
241         pinctrl-names = "default";
242         pinctrl-0 = <&pinctrl_uart0_default>;
243         atmel,use-dma-rx;
244         atmel,use-dma-tx;
245         status = "okay";
246 };
247
248 &uart3 {
249         pinctrl-names = "default";
250         pinctrl-0 = <&pinctrl_uart3_default>;
251         atmel,use-dma-rx;
252         atmel,use-dma-tx;
253         status = "okay";
254 };
255
256 &usb0 {
257         atmel,vbus-gpio = <&pioA PIN_PA16 GPIO_ACTIVE_HIGH>;
258         pinctrl-names = "default";
259         pinctrl-0 = <&pinctrl_usba_vbus>;
260         status = "okay";
261 };
262
263 &usb1 {
264         num-ports = <3>;
265         atmel,vbus-gpio = <0
266                            &pioA PIN_PA10 GPIO_ACTIVE_HIGH
267                            0
268                           >;
269         pinctrl-names = "default";
270         pinctrl-0 = <&pinctrl_usb_default>;
271         status = "okay";
272 };
273
274 &usb2 {
275         phy_type = "hsic";
276         status = "okay";
277 };
278
279 &watchdog {
280         status = "okay";
281 };
282