treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / arch / arm64 / boot / dts / amlogic / meson-gxbb-nexbox-a95x.dts
blob65ec7dea828c1e417c742db28e0c3b1aa63250cd
1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2 /*
3  * Copyright (c) 2016 Andreas Färber
4  * Copyright (c) 2016 BayLibre, Inc.
5  * Author: Neil Armstrong <narmstrong@kernel.org>
6  */
8 /dts-v1/;
10 #include "meson-gxbb.dtsi"
11 #include <dt-bindings/gpio/gpio.h>
12 #include <dt-bindings/input/input.h>
14 / {
15         compatible = "nexbox,a95x", "amlogic,meson-gxbb";
16         model = "NEXBOX A95X";
18         aliases {
19                 serial0 = &uart_AO;
20                 ethernet0 = &ethmac;
21         };
23         chosen {
24                 stdout-path = "serial0:115200n8";
25         };
27         memory@0 {
28                 device_type = "memory";
29                 reg = <0x0 0x0 0x0 0x40000000>;
30         };
32         leds {
33                 compatible = "gpio-leds";
34                 blue {
35                         label = "a95x:system-status";
36                         gpios = <&gpio_ao GPIOAO_13 GPIO_ACTIVE_LOW>;
37                         linux,default-trigger = "heartbeat";
38                         default-state = "off";
39                 };
40         };
42         gpio-keys-polled {
43                 compatible = "gpio-keys-polled";
44                 #address-cells = <1>;
45                 #size-cells = <0>;
46                 poll-interval = <100>;
48                 button@0 {
49                         label = "reset";
50                         linux,code = <KEY_RESTART>;
51                         gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_LOW>;
52                 };
53         };
55         usb_pwr: regulator-usb-pwrs {
56                 compatible = "regulator-fixed";
58                 regulator-name = "USB_PWR";
60                 regulator-min-microvolt = <5000000>;
61                 regulator-max-microvolt = <5000000>;
63                 gpio = <&gpio GPIODV_24 GPIO_ACTIVE_HIGH>;
64                 enable-active-high;
65         };
67         vddio_card: gpio-regulator {
68                 compatible = "regulator-gpio";
70                 regulator-name = "VDDIO_CARD";
71                 regulator-min-microvolt = <1800000>;
72                 regulator-max-microvolt = <3300000>;
74                 gpios = <&gpio_ao GPIOAO_5 GPIO_ACTIVE_HIGH>;
75                 gpios-states = <1>;
77                 /* Based on P200 schematics, signal CARD_1.8V/3.3V_CTR */
78                 states = <1800000 0>,
79                          <3300000 1>;
80         };
82         vddio_boot: regulator-vddio_boot {
83                 compatible = "regulator-fixed";
84                 regulator-name = "VDDIO_BOOT";
85                 regulator-min-microvolt = <1800000>;
86                 regulator-max-microvolt = <1800000>;
87         };
89         vddao_3v3: regulator-vddao_3v3 {
90                 compatible = "regulator-fixed";
91                 regulator-name = "VDDAO_3V3";
92                 regulator-min-microvolt = <3300000>;
93                 regulator-max-microvolt = <3300000>;
94         };
96         vcc_3v3: regulator-vcc_3v3 {
97                 compatible = "regulator-fixed";
98                 regulator-name = "VCC_3V3";
99                 regulator-min-microvolt = <3300000>;
100                 regulator-max-microvolt = <3300000>;
101         };
103         emmc_pwrseq: emmc-pwrseq {
104                 compatible = "mmc-pwrseq-emmc";
105                 reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>;
106         };
108         wifi32k: wifi32k {
109                 compatible = "pwm-clock";
110                 #clock-cells = <0>;
111                 clock-frequency = <32768>;
112                 pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */
113         };
115         sdio_pwrseq: sdio-pwrseq {
116                 compatible = "mmc-pwrseq-simple";
117                 reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>;
118                 clocks = <&wifi32k>;
119                 clock-names = "ext_clock";
120         };
122         cvbs-connector {
123                 compatible = "composite-video-connector";
125                 port {
126                         cvbs_connector_in: endpoint {
127                                 remote-endpoint = <&cvbs_vdac_out>;
128                         };
129                 };
130         };
132         hdmi-connector {
133                 compatible = "hdmi-connector";
134                 type = "a";
136                 port {
137                         hdmi_connector_in: endpoint {
138                                 remote-endpoint = <&hdmi_tx_tmds_out>;
139                         };
140                 };
141         };
144 &cvbs_vdac_port {
145         cvbs_vdac_out: endpoint {
146                 remote-endpoint = <&cvbs_connector_in>;
147         };
150 &cec_AO {
151         status = "okay";
152         pinctrl-0 = <&ao_cec_pins>;
153         pinctrl-names = "default";
154         hdmi-phandle = <&hdmi_tx>;
157 &ethmac {
158         status = "okay";
159         pinctrl-0 = <&eth_rmii_pins>;
160         pinctrl-names = "default";
162         phy-handle = <&eth_phy0>;
163         phy-mode = "rmii";
165         mdio {
166                 compatible = "snps,dwmac-mdio";
167                 #address-cells = <1>;
168                 #size-cells = <0>;
170                 eth_phy0: ethernet-phy@0 {
171                         /* IC Plus IP101GR (0x02430c54) */
172                         reg = <0>;
174                         reset-assert-us = <10000>;
175                         reset-deassert-us = <10000>;
176                         reset-gpios = <&gpio GPIOZ_14 GPIO_ACTIVE_LOW>;
177                 };
178         };
181 &hdmi_tx {
182         status = "okay";
183         pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i2c_pins>;
184         pinctrl-names = "default";
187 &hdmi_tx_tmds_port {
188         hdmi_tx_tmds_out: endpoint {
189                 remote-endpoint = <&hdmi_connector_in>;
190         };
193 &ir {
194         status = "okay";
195         pinctrl-0 = <&remote_input_ao_pins>;
196         pinctrl-names = "default";
199 &pwm_ef {
200         status = "okay";
201         pinctrl-0 = <&pwm_e_pins>;
202         pinctrl-names = "default";
203         clocks = <&clkc CLKID_FCLK_DIV4>;
204         clock-names = "clkin0";
207 /* Wireless SDIO Module */
208 &sd_emmc_a {
209         status = "okay";
210         pinctrl-0 = <&sdio_pins>;
211         pinctrl-1 = <&sdio_clk_gate_pins>;
212         pinctrl-names = "default", "clk-gate";
213         #address-cells = <1>;
214         #size-cells = <0>;
216         bus-width = <4>;
217         cap-sd-highspeed;
218         max-frequency = <100000000>;
220         non-removable;
221         disable-wp;
223         /* WiFi firmware requires power to be kept while in suspend */
224         keep-power-in-suspend;
226         mmc-pwrseq = <&sdio_pwrseq>;
228         vmmc-supply = <&vddao_3v3>;
229         vqmmc-supply = <&vddio_boot>;
232 /* SD card */
233 &sd_emmc_b {
234         status = "okay";
235         pinctrl-0 = <&sdcard_pins>;
236         pinctrl-1 = <&sdcard_clk_gate_pins>;
237         pinctrl-names = "default", "clk-gate";
239         bus-width = <4>;
240         cap-sd-highspeed;
241         max-frequency = <50000000>;
242         disable-wp;
244         cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_LOW>;
246         vmmc-supply = <&vddao_3v3>;
247         vqmmc-supply = <&vddio_card>;
250 /* eMMC */
251 &sd_emmc_c {
252         status = "okay";
253         pinctrl-0 = <&emmc_pins>, <&emmc_ds_pins>;
254         pinctrl-1 = <&emmc_clk_gate_pins>;
255         pinctrl-names = "default", "clk-gate";
257         bus-width = <8>;
258         cap-mmc-highspeed;
259         max-frequency = <200000000>;
260         non-removable;
261         disable-wp;
262         mmc-ddr-1_8v;
263         mmc-hs200-1_8v;
265         mmc-pwrseq = <&emmc_pwrseq>;
266         vmmc-supply = <&vcc_3v3>;
267         vqmmc-supply = <&vddio_boot>;
270 &uart_AO {
271         status = "okay";
272         pinctrl-0 = <&uart_ao_a_pins>;
273         pinctrl-names = "default";
276 &usb0_phy {
277         status = "okay";
278         phy-supply = <&usb_pwr>;
281 &usb1_phy {
282         status = "okay";
285 &usb0 {
286         status = "okay";
289 &usb1 {
290         status = "okay";