1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Copyright (C) 2018 Amarula Solutions B.V. 4 * Author: Jagan Teki <jagan@amarulasolutions.com> 5 */ 6 7/dts-v1/; 8 9#include "sun50i-a64.dtsi" 10 11#include <dt-bindings/gpio/gpio.h> 12 13/ { 14 model = "Amarula A64-Relic"; 15 compatible = "amarula,a64-relic", "allwinner,sun50i-a64"; 16 17 aliases { 18 serial0 = &uart0; 19 }; 20 21 chosen { 22 stdout-path = "serial0:115200n8"; 23 }; 24 25 wifi_pwrseq: wifi-pwrseq { 26 compatible = "mmc-pwrseq-simple"; 27 clocks = <&rtc 1>; 28 clock-names = "ext_clock"; 29 reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* WL-PMU-EN: PL2 */ 30 }; 31}; 32 33&ehci0 { 34 status = "okay"; 35}; 36 37&i2c0 { 38 pinctrl-names = "default"; 39 pinctrl-0 = <&i2c0_pins>; 40 status = "okay"; 41 42 sensor@48 { 43 compatible = "st,stlm75"; 44 reg = <0x48>; 45 }; 46}; 47 48&i2c0_pins { 49 bias-pull-up; 50}; 51 52&mmc1 { 53 pinctrl-names = "default"; 54 pinctrl-0 = <&mmc1_pins>; 55 vmmc-supply = <®_dcdc1>; 56 /* 57 * Schematic shows both dldo4 and eldo1 connected for vcc-io-wifi, but 58 * dldo4 connection shows DNP(Do Not Populate) and eldo1 connected with 59 * 0Ohm register to vcc-io-wifi so eldo1 is used. 60 */ 61 vqmmc-supply = <®_eldo1>; 62 mmc-pwrseq = <&wifi_pwrseq>; 63 bus-width = <4>; 64 non-removable; 65 status = "okay"; 66 67 brcmf: wifi@1 { 68 reg = <1>; 69 compatible = "brcm,bcm4329-fmac"; 70 interrupt-parent = <&r_pio>; 71 interrupts = <0 3 IRQ_TYPE_LEVEL_LOW>; /* WL-WAKE-AP: PL3 */ 72 interrupt-names = "host-wake"; 73 }; 74}; 75 76&mmc2 { 77 pinctrl-names = "default"; 78 pinctrl-0 = <&mmc2_pins>; 79 vmmc-supply = <®_dcdc1>; 80 bus-width = <8>; 81 non-removable; 82 cap-mmc-hw-reset; 83 status = "okay"; 84}; 85 86&ohci0 { 87 status = "okay"; 88}; 89 90&r_rsb { 91 status = "okay"; 92 93 axp803: pmic@3a3 { 94 compatible = "x-powers,axp803"; 95 reg = <0x3a3>; 96 interrupt-parent = <&r_intc>; 97 interrupts = <0 IRQ_TYPE_LEVEL_LOW>; 98 x-powers,drive-vbus-en; /* set N_VBUSEN as output pin */ 99 }; 100}; 101 102#include "axp803.dtsi" 103 104®_aldo1 { 105 regulator-always-on; 106 regulator-min-microvolt = <2800000>; 107 regulator-max-microvolt = <2800000>; 108 regulator-name = "avdd-csi"; 109}; 110 111®_aldo2 { 112 regulator-always-on; 113 regulator-min-microvolt = <1800000>; 114 regulator-max-microvolt = <3300000>; 115 regulator-name = "vcc-pl"; 116}; 117 118®_aldo3 { 119 regulator-always-on; 120 regulator-min-microvolt = <3000000>; 121 regulator-max-microvolt = <3000000>; 122 regulator-name = "vcc-pll-avcc"; 123}; 124 125®_dcdc1 { 126 regulator-always-on; 127 regulator-min-microvolt = <3300000>; 128 regulator-max-microvolt = <3300000>; 129 regulator-name = "vcc-3v3"; 130}; 131 132®_dcdc2 { 133 regulator-always-on; 134 regulator-min-microvolt = <1040000>; 135 regulator-max-microvolt = <1300000>; 136 regulator-name = "vdd-cpux"; 137}; 138 139/* DCDC3 is polyphased with DCDC2 */ 140 141®_dcdc5 { 142 regulator-always-on; 143 regulator-min-microvolt = <1500000>; 144 regulator-max-microvolt = <1500000>; 145 regulator-name = "vcc-dram"; 146}; 147 148®_dcdc6 { 149 regulator-always-on; 150 regulator-min-microvolt = <1100000>; 151 regulator-max-microvolt = <1100000>; 152 regulator-name = "vdd-sys"; 153}; 154 155®_dldo1 { 156 regulator-min-microvolt = <3300000>; 157 regulator-max-microvolt = <3300000>; 158 regulator-name = "vcc-hdmi-dsi-sensor"; 159}; 160 161®_dldo2 { 162 regulator-min-microvolt = <3300000>; 163 regulator-max-microvolt = <3300000>; 164 regulator-name = "vcc-mipi"; 165}; 166 167®_dldo3 { 168 regulator-min-microvolt = <2800000>; 169 regulator-max-microvolt = <2800000>; 170 regulator-name = "dovdd-csi"; 171}; 172 173®_dldo4 { 174 regulator-min-microvolt = <3300000>; 175 regulator-max-microvolt = <3300000>; 176 regulator-name = "vcc-wifi-io"; 177}; 178 179®_drivevbus { 180 regulator-name = "usb0-vbus"; 181 status = "okay"; 182}; 183 184®_eldo1 { 185 regulator-always-on; 186 regulator-min-microvolt = <1800000>; 187 regulator-max-microvolt = <1800000>; 188 regulator-name = "cpvdd"; 189}; 190 191®_eldo3 { 192 regulator-min-microvolt = <1800000>; 193 regulator-max-microvolt = <1800000>; 194 regulator-name = "dvdd-csi"; 195}; 196 197®_fldo1 { 198 regulator-min-microvolt = <1200000>; 199 regulator-max-microvolt = <1200000>; 200 regulator-name = "vcc-1v2-hsic"; 201}; 202 203/* 204 * The A64 chip cannot work without this regulator off, although 205 * it seems to be only driving the AR100 core. 206 * Maybe we don't still know well about CPUs domain. 207 */ 208®_fldo2 { 209 regulator-always-on; 210 regulator-min-microvolt = <1100000>; 211 regulator-max-microvolt = <1100000>; 212 regulator-name = "vdd-cpus"; 213}; 214 215®_rtc_ldo { 216 regulator-name = "vcc-rtc"; 217}; 218 219&uart0 { 220 pinctrl-names = "default"; 221 pinctrl-0 = <&uart0_pb_pins>; 222 status = "okay"; 223}; 224 225&usb_otg { 226 dr_mode = "otg"; 227 status = "okay"; 228}; 229 230&usbphy { 231 usb0_id_det-gpios = <&pio 7 9 GPIO_ACTIVE_HIGH>; /* PH9 */ 232 usb0_vbus-supply = <®_drivevbus>; 233 status = "okay"; 234}; 235