blob: d12b01c5f41b69029de04bc006be35c1ded3aeaa [file] [log] [blame]
Andre Przywarac2a441c2024-04-19 17:59:52 +01001// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
Andre Przywarab5d4c832024-01-21 00:06:00 +00002/*
3 * Copyright (C) 2023 Martin Botka <martin.botka@somainline.org>.
4 */
5
6/dts-v1/;
7
8#include "sun50i-h616.dtsi"
Andre Przywara3b798212024-04-19 17:59:52 +01009#include "sun50i-h616-cpu-opp.dtsi"
Andre Przywarab5d4c832024-01-21 00:06:00 +000010
11#include <dt-bindings/gpio/gpio.h>
12#include <dt-bindings/interrupt-controller/arm-gic.h>
13#include <dt-bindings/leds/common.h>
14
15/ {
16 aliases {
17 ethernet0 = &rtl8189ftv;
18 };
19
20 leds {
21 compatible = "gpio-leds";
22
23 led-0 {
24 function = LED_FUNCTION_STATUS;
25 color = <LED_COLOR_ID_GREEN>;
26 gpios = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
27 };
28 };
29
30 reg_vcc5v: regulator-vcc5v {
31 /* board wide 5V supply from carrier boards */
32 compatible = "regulator-fixed";
33 regulator-name = "vcc-5v";
34 regulator-min-microvolt = <5000000>;
35 regulator-max-microvolt = <5000000>;
36 regulator-always-on;
37 };
38
39 reg_vcc33_wifi: vcc33-wifi {
40 compatible = "regulator-fixed";
41 regulator-name = "vcc33-wifi";
42 regulator-min-microvolt = <3300000>;
43 regulator-max-microvolt = <3300000>;
44 regulator-always-on;
45 vin-supply = <&reg_vcc5v>;
46 };
47
48 reg_vcc_wifi_io: vcc-wifi-io {
49 compatible = "regulator-fixed";
50 regulator-name = "vcc-wifi-io";
51 regulator-min-microvolt = <1800000>;
52 regulator-max-microvolt = <1800000>;
53 regulator-always-on;
54 vin-supply = <&reg_vcc33_wifi>;
55 };
56
57 wifi_pwrseq: wifi-pwrseq {
58 compatible = "mmc-pwrseq-simple";
59 clocks = <&rtc 1>;
60 clock-names = "ext_clock";
61 reset-gpios = <&pio 6 18 GPIO_ACTIVE_LOW>; /* PG18 */
62 post-power-on-delay-ms = <200>;
63 };
64};
65
Andre Przywara3b798212024-04-19 17:59:52 +010066&cpu0 {
67 cpu-supply = <&reg_dcdc2>;
68};
69
Andre Przywarab5d4c832024-01-21 00:06:00 +000070&mmc0 {
71 vmmc-supply = <&reg_dldo1>;
72 /* Card detection pin is not connected */
73 broken-cd;
74 bus-width = <4>;
75 status = "okay";
76};
77
78&mmc1 {
79 vmmc-supply = <&reg_vcc33_wifi>;
80 vqmmc-supply = <&reg_vcc_wifi_io>;
81 mmc-pwrseq = <&wifi_pwrseq>;
82 bus-width = <4>;
83 non-removable;
84 mmc-ddr-1_8v;
85 status = "okay";
86
87 rtl8189ftv: wifi@1 {
88 reg = <1>;
89 };
90};
91
92&r_i2c {
93 status = "okay";
94
95 axp313a: pmic@36 {
96 compatible = "x-powers,axp313a";
97 reg = <0x36>;
98 interrupt-controller;
99 #interrupt-cells = <1>;
100
Andre Przywarac2a441c2024-04-19 17:59:52 +0100101 regulators {
Andre Przywarab5d4c832024-01-21 00:06:00 +0000102 reg_dcdc1: dcdc1 {
103 regulator-name = "vdd-gpu-sys";
104 regulator-min-microvolt = <810000>;
105 regulator-max-microvolt = <990000>;
106 regulator-always-on;
107 };
108
109 reg_dcdc2: dcdc2 {
110 regulator-name = "vdd-cpu";
111 regulator-min-microvolt = <810000>;
112 regulator-max-microvolt = <1100000>;
113 regulator-ramp-delay = <200>;
114 regulator-always-on;
115 };
116
117 reg_dcdc3: dcdc3 {
118 regulator-name = "vcc-dram";
119 regulator-min-microvolt = <1350000>;
120 regulator-max-microvolt = <1500000>;
121 regulator-always-on;
122 };
123
124 reg_aldo1: aldo1 {
125 regulator-name = "vcc-1v8-pll";
126 regulator-min-microvolt = <1800000>;
127 regulator-max-microvolt = <1800000>;
128 regulator-always-on;
129 };
130
131 reg_dldo1: dldo1 {
132 regulator-name = "vcc-3v3-io";
133 regulator-min-microvolt = <3300000>;
134 regulator-max-microvolt = <3300000>;
135 regulator-always-on;
136 };
137 };
138 };
139};
140
141&usbphy {
142 status = "okay";
143};