treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / arch / arm / boot / dts / meson8m2-mxiii-plus.dts
blobd54477b1001ca775a2137060870b9cface45ece6
1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2 /*
3  * Copyright (c) 2018 Oleg Ivanov <balbes-150@yandex.ru>
4  * Copyright (c) 2018 Martin Blumenstingl <martin.blumenstingl@googlemail.com>
5  */
7 /dts-v1/;
9 #include "meson8m2.dtsi"
11 #include <dt-bindings/gpio/gpio.h>
12 #include <dt-bindings/input/input.h>
14 / {
15         model = "Tronsmart MXIII Plus";
16         compatible = "tronsmart,mxiii-plus", "amlogic,meson8m2";
18         aliases {
19                 ethernet0 = &ethmac;
20                 i2c0 = &i2c_AO;
21                 serial0 = &uart_AO;
22                 serial1 = &uart_A;
23                 mmc0 = &sd_card_slot;
24         };
26         chosen {
27                 stdout-path = "serial0:115200n8";
28         };
30         memory {
31                 device_type = "memory";
32                 reg = <0x40000000 0x80000000>;
33         };
35         adc-keys {
36                 compatible = "adc-keys";
37                 io-channels = <&saradc 0>;
38                 io-channel-names = "buttons";
39                 keyup-threshold-microvolt = <1710000>;
41                 button-function {
42                         label = "Function";
43                         linux,code = <KEY_FN>;
44                         press-threshold-microvolt = <10000>;
45                 };
46         };
48         iio-hwmon {
49                 compatible = "iio-hwmon";
50                 io-channels = <&saradc 8>;
51         };
53         vcc_3v3: regulator-vcc3v3 {
54                 compatible = "regulator-fixed";
55                 regulator-name = "VCC3V3";
56                 regulator-min-microvolt = <3300000>;
57                 regulator-max-microvolt = <3300000>;
58         };
61 &cpu0 {
62         cpu-supply = <&vcck>;
65 &ethmac {
66         status = "okay";
68         pinctrl-0 = <&eth_rgmii_pins>;
69         pinctrl-names = "default";
71         phy-handle = <&eth_phy0>;
72         phy-mode = "rgmii";
74         amlogic,tx-delay-ns = <4>;
76         mdio {
77                 compatible = "snps,dwmac-mdio";
78                 #address-cells = <1>;
79                 #size-cells = <0>;
81                 eth_phy0: ethernet-phy@0 {
82                         /* Realtek RTL8211F (0x001cc916) */
83                         reg = <0>;
85                         reset-assert-us = <10000>;
86                         reset-deassert-us = <30000>;
87                         reset-gpios = <&gpio GPIOH_4 GPIO_ACTIVE_LOW>;
88                 };
89         };
92 &ir_receiver {
93         status = "okay";
94         pinctrl-0 = <&ir_recv_pins>;
95         pinctrl-names = "default";
98 &i2c_AO {
99         status = "okay";
100         pinctrl-0 = <&i2c_ao_pins>;
101         pinctrl-names = "default";
103         pmic@32 {
104                 compatible = "ricoh,rn5t618";
105                 reg = <0x32>;
106                 system-power-controller;
108                 regulators {
109                         vcck: DCDC1 {
110                                 regulator-name = "VCCK";
111                                 regulator-min-microvolt = <825000>;
112                                 regulator-max-microvolt = <1150000>;
113                                 regulator-boot-on;
114                                 regulator-always-on;
115                         };
117                         vddee: DCDC2 {
118                                 /* the output is also used as VDDAO */
119                                 regulator-name = "VDD_EE";
120                                 regulator-min-microvolt = <950000>;
121                                 regulator-max-microvolt = <1150000>;
122                                 regulator-boot-on;
123                                 regulator-always-on;
124                         };
126                         DCDC3 {
127                                 regulator-name = "VDD_DDR";
128                                 regulator-min-microvolt = <1500000>;
129                                 regulator-max-microvolt = <1500000>;
130                                 regulator-boot-on;
131                                 regulator-always-on;
132                         };
134                         LDO1 {
135                                 regulator-name = "VDDIO_AO28";
136                                 regulator-min-microvolt = <2900000>;
137                                 regulator-max-microvolt = <2900000>;
138                                 regulator-boot-on;
139                                 regulator-always-on;
140                         };
142                         vddio_ao1v8: LDO2 {
143                                 regulator-name = "VDDIO_AO18";
144                                 regulator-min-microvolt = <1800000>;
145                                 regulator-max-microvolt = <1800000>;
146                                 regulator-boot-on;
147                                 regulator-always-on;
148                         };
150                         LDO3 {
151                                 regulator-name = "VCC1V8";
152                                 regulator-min-microvolt = <1800000>;
153                                 regulator-max-microvolt = <1800000>;
154                                 regulator-boot-on;
155                                 regulator-always-on;
156                         };
158                         LDO4 {
159                                 regulator-name = "VCC2V8";
160                                 regulator-min-microvolt = <2850000>;
161                                 regulator-max-microvolt = <2850000>;
162                                 regulator-boot-on;
163                                 regulator-always-on;
164                         };
166                         LDO5 {
167                                 regulator-name = "AVDD1V8";
168                                 regulator-min-microvolt = <1800000>;
169                                 regulator-max-microvolt = <1800000>;
170                                 regulator-boot-on;
171                                 regulator-always-on;
172                         };
174                         LDORTC1 {
175                                 regulator-name = "VDD_LDO";
176                                 regulator-min-microvolt = <2700000>;
177                                 regulator-max-microvolt = <2700000>;
178                                 regulator-boot-on;
179                                 regulator-always-on;
180                         };
182                         LDORTC2 {
183                                 regulator-name = "RTC_0V9";
184                                 regulator-min-microvolt = <900000>;
185                                 regulator-max-microvolt = <900000>;
186                                 regulator-boot-on;
187                                 regulator-always-on;
188                         };
189                 };
190         };
193 &mali {
194         mali-supply = <&vddee>;
197 &saradc {
198         status = "okay";
199         vref-supply = <&vddio_ao1v8>;
202 &sdio {
203         status = "okay";
205         pinctrl-0 = <&sd_b_pins>;
206         pinctrl-names = "default";
208         /* SD card */
209         sd_card_slot: slot@1 {
210                 compatible = "mmc-slot";
211                 reg = <1>;
212                 status = "okay";
214                 bus-width = <4>;
215                 no-sdio;
216                 cap-mmc-highspeed;
217                 cap-sd-highspeed;
218                 disable-wp;
220                 cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_LOW>;
222                 vmmc-supply = <&vcc_3v3>;
223         };
226 /* connected to the Bluetooth module */
227 &uart_A {
228         status = "okay";
229         pinctrl-0 = <&uart_a1_pins>, <&uart_a1_cts_rts_pins>;
230         pinctrl-names = "default";
231         uart-has-rtscts;
234 &uart_AO {
235         status = "okay";
236         pinctrl-0 = <&uart_ao_a_pins>;
237         pinctrl-names = "default";
240 &usb0 {
241         status = "okay";
244 &usb1 {
245         status = "okay";
248 &usb0_phy {
249         status = "okay";
252 &usb1_phy {
253         status = "okay";