Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 1 | // SPDX-License-Identifier: (GPL-2.0+ or MIT) |
| 2 | /* |
| 3 | * Copyright (c) 2017 Icenowy Zheng <icenowy@aosc.io> |
| 4 | */ |
| 5 | |
| 6 | /dts-v1/; |
| 7 | |
| 8 | #include "sun50i-h6.dtsi" |
| 9 | |
| 10 | #include <dt-bindings/gpio/gpio.h> |
| 11 | |
| 12 | / { |
| 13 | model = "Pine H64"; |
| 14 | compatible = "pine64,pine-h64", "allwinner,sun50i-h6"; |
| 15 | |
| 16 | aliases { |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 17 | ethernet0 = &emac; |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 18 | serial0 = &uart0; |
| 19 | }; |
| 20 | |
| 21 | chosen { |
| 22 | stdout-path = "serial0:115200n8"; |
| 23 | }; |
| 24 | |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 25 | connector { |
| 26 | compatible = "hdmi-connector"; |
| 27 | type = "a"; |
| 28 | |
| 29 | port { |
| 30 | hdmi_con_in: endpoint { |
| 31 | remote-endpoint = <&hdmi_out_con>; |
| 32 | }; |
| 33 | }; |
| 34 | }; |
| 35 | |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 36 | leds { |
| 37 | compatible = "gpio-leds"; |
| 38 | |
| 39 | heartbeat { |
| 40 | label = "pine-h64:green:heartbeat"; |
| 41 | gpios = <&r_pio 0 4 GPIO_ACTIVE_HIGH>; /* PL4 */ |
| 42 | }; |
| 43 | |
| 44 | link { |
| 45 | label = "pine-h64:white:link"; |
| 46 | gpios = <&r_pio 0 3 GPIO_ACTIVE_HIGH>; /* PL3 */ |
| 47 | }; |
| 48 | |
| 49 | status { |
| 50 | label = "pine-h64:blue:status"; |
| 51 | gpios = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */ |
| 52 | }; |
| 53 | }; |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 54 | |
| 55 | reg_usb_vbus: vbus { |
| 56 | compatible = "regulator-fixed"; |
| 57 | regulator-name = "usb-vbus"; |
| 58 | regulator-min-microvolt = <5000000>; |
| 59 | regulator-max-microvolt = <5000000>; |
| 60 | startup-delay-us = <100000>; |
| 61 | gpio = <&r_pio 0 5 GPIO_ACTIVE_HIGH>; |
| 62 | enable-active-high; |
| 63 | }; |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 64 | }; |
| 65 | |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 66 | &emac { |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 67 | pinctrl-names = "default"; |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 68 | pinctrl-0 = <&ext_rgmii_pins>; |
| 69 | phy-mode = "rgmii"; |
| 70 | phy-handle = <&ext_rgmii_phy>; |
| 71 | phy-supply = <®_aldo2>; |
| 72 | allwinner,rx-delay-ps = <200>; |
| 73 | allwinner,tx-delay-ps = <200>; |
| 74 | status = "okay"; |
| 75 | }; |
| 76 | |
| 77 | &mdio { |
| 78 | ext_rgmii_phy: ethernet-phy@1 { |
| 79 | compatible = "ethernet-phy-ieee802.3-c22"; |
| 80 | reg = <1>; |
| 81 | }; |
| 82 | }; |
| 83 | |
| 84 | &de { |
| 85 | status = "okay"; |
| 86 | }; |
| 87 | |
| 88 | &hdmi { |
| 89 | status = "okay"; |
| 90 | }; |
| 91 | |
| 92 | &hdmi_out { |
| 93 | hdmi_out_con: endpoint { |
| 94 | remote-endpoint = <&hdmi_con_in>; |
| 95 | }; |
| 96 | }; |
| 97 | |
| 98 | &ehci0 { |
| 99 | status = "okay"; |
| 100 | }; |
| 101 | |
| 102 | &ehci3 { |
| 103 | status = "okay"; |
| 104 | }; |
| 105 | |
| 106 | &mmc0 { |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 107 | vmmc-supply = <®_cldo1>; |
| 108 | cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 109 | bus-width = <4>; |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 110 | status = "okay"; |
| 111 | }; |
| 112 | |
| 113 | &mmc2 { |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 114 | vmmc-supply = <®_cldo1>; |
| 115 | vqmmc-supply = <®_bldo2>; |
| 116 | non-removable; |
| 117 | cap-mmc-hw-reset; |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 118 | bus-width = <8>; |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 119 | status = "okay"; |
| 120 | }; |
| 121 | |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 122 | &ohci0 { |
| 123 | status = "okay"; |
| 124 | }; |
| 125 | |
| 126 | &ohci3 { |
| 127 | status = "okay"; |
| 128 | }; |
| 129 | |
Clément Péron | 725089c | 2019-08-25 18:04:18 +0200 | [diff] [blame] | 130 | &pio { |
| 131 | vcc-pc-supply = <®_bldo2>; |
| 132 | vcc-pd-supply = <®_cldo1>; |
| 133 | vcc-pg-supply = <®_aldo1>; |
| 134 | }; |
| 135 | |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 136 | &r_i2c { |
| 137 | status = "okay"; |
| 138 | |
| 139 | axp805: pmic@36 { |
| 140 | compatible = "x-powers,axp805", "x-powers,axp806"; |
| 141 | reg = <0x36>; |
| 142 | interrupt-parent = <&r_intc>; |
| 143 | interrupts = <0 IRQ_TYPE_LEVEL_LOW>; |
| 144 | interrupt-controller; |
| 145 | #interrupt-cells = <1>; |
| 146 | x-powers,self-working-mode; |
| 147 | |
| 148 | regulators { |
| 149 | reg_aldo1: aldo1 { |
| 150 | regulator-always-on; |
| 151 | regulator-min-microvolt = <3300000>; |
| 152 | regulator-max-microvolt = <3300000>; |
| 153 | regulator-name = "vcc-pl"; |
| 154 | }; |
| 155 | |
| 156 | reg_aldo2: aldo2 { |
| 157 | regulator-min-microvolt = <3300000>; |
| 158 | regulator-max-microvolt = <3300000>; |
| 159 | regulator-name = "vcc-ac200"; |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 160 | regulator-enable-ramp-delay = <100000>; |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 161 | }; |
| 162 | |
| 163 | reg_aldo3: aldo3 { |
| 164 | /* This regulator is connected with CLDO1 */ |
| 165 | regulator-always-on; |
| 166 | regulator-min-microvolt = <3300000>; |
| 167 | regulator-max-microvolt = <3300000>; |
| 168 | regulator-name = "vcc-3v3-1"; |
| 169 | }; |
| 170 | |
| 171 | reg_bldo1: bldo1 { |
| 172 | regulator-always-on; |
| 173 | regulator-min-microvolt = <1800000>; |
| 174 | regulator-max-microvolt = <1800000>; |
| 175 | regulator-name = "vcc-bias-pll"; |
| 176 | }; |
| 177 | |
| 178 | reg_bldo2: bldo2 { |
| 179 | regulator-always-on; |
| 180 | regulator-min-microvolt = <1800000>; |
| 181 | regulator-max-microvolt = <1800000>; |
| 182 | regulator-name = "vcc-efuse-pcie-hdmi-io"; |
| 183 | }; |
| 184 | |
| 185 | reg_bldo3: bldo3 { |
| 186 | regulator-always-on; |
| 187 | regulator-min-microvolt = <1800000>; |
| 188 | regulator-max-microvolt = <1800000>; |
| 189 | regulator-name = "vcc-dcxoio"; |
| 190 | }; |
| 191 | |
| 192 | bldo4 { |
| 193 | /* unused */ |
| 194 | }; |
| 195 | |
| 196 | reg_cldo1: cldo1 { |
| 197 | /* This regulator is connected with ALDO3 */ |
| 198 | regulator-always-on; |
| 199 | regulator-min-microvolt = <3300000>; |
| 200 | regulator-max-microvolt = <3300000>; |
| 201 | regulator-name = "vcc-3v3-2"; |
| 202 | }; |
| 203 | |
| 204 | reg_cldo2: cldo2 { |
| 205 | regulator-min-microvolt = <3300000>; |
| 206 | regulator-max-microvolt = <3300000>; |
| 207 | regulator-name = "vcc-wifi-1"; |
| 208 | }; |
| 209 | |
| 210 | reg_cldo3: cldo3 { |
| 211 | regulator-min-microvolt = <3300000>; |
| 212 | regulator-max-microvolt = <3300000>; |
| 213 | regulator-name = "vcc-wifi-2"; |
| 214 | }; |
| 215 | |
| 216 | reg_dcdca: dcdca { |
| 217 | regulator-always-on; |
| 218 | regulator-min-microvolt = <810000>; |
| 219 | regulator-max-microvolt = <1080000>; |
| 220 | regulator-name = "vdd-cpu"; |
| 221 | }; |
| 222 | |
| 223 | reg_dcdcc: dcdcc { |
| 224 | regulator-min-microvolt = <810000>; |
| 225 | regulator-max-microvolt = <1080000>; |
| 226 | regulator-name = "vdd-gpu"; |
| 227 | }; |
| 228 | |
| 229 | reg_dcdcd: dcdcd { |
| 230 | regulator-always-on; |
| 231 | regulator-min-microvolt = <960000>; |
| 232 | regulator-max-microvolt = <960000>; |
| 233 | regulator-name = "vdd-sys"; |
| 234 | }; |
| 235 | |
| 236 | reg_dcdce: dcdce { |
| 237 | regulator-always-on; |
| 238 | regulator-min-microvolt = <1200000>; |
| 239 | regulator-max-microvolt = <1200000>; |
| 240 | regulator-name = "vcc-dram"; |
| 241 | }; |
| 242 | |
| 243 | sw { |
| 244 | /* unused */ |
| 245 | }; |
| 246 | }; |
| 247 | }; |
| 248 | |
| 249 | pcf8563: rtc@51 { |
| 250 | compatible = "nxp,pcf8563"; |
| 251 | reg = <0x51>; |
Clément Péron | 725089c | 2019-08-25 18:04:18 +0200 | [diff] [blame] | 252 | interrupt-parent = <&r_intc>; |
| 253 | interrupts = <0 IRQ_TYPE_LEVEL_LOW>; |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 254 | #clock-cells = <0>; |
| 255 | }; |
| 256 | }; |
| 257 | |
Clément Péron | 725089c | 2019-08-25 18:04:18 +0200 | [diff] [blame] | 258 | &r_pio { |
| 259 | vcc-pm-supply = <®_aldo1>; |
| 260 | }; |
| 261 | |
Icenowy Zheng | 1259869 | 2018-07-21 16:20:32 +0800 | [diff] [blame] | 262 | &uart0 { |
| 263 | pinctrl-names = "default"; |
| 264 | pinctrl-0 = <&uart0_ph_pins>; |
| 265 | status = "okay"; |
| 266 | }; |
Jagan Teki | 7d412cd | 2019-04-14 22:22:21 +0530 | [diff] [blame] | 267 | |
| 268 | &usb2otg { |
| 269 | dr_mode = "host"; |
| 270 | status = "okay"; |
| 271 | }; |
| 272 | |
| 273 | &usb2phy { |
| 274 | usb0_vbus-supply = <®_usb_vbus>; |
| 275 | usb3_vbus-supply = <®_usb_vbus>; |
| 276 | status = "okay"; |
| 277 | }; |