1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Copyright (C) 2024 Arm Ltd. 4 */ 5 6/dts-v1/; 7 8#include "sun50i-h616.dtsi" 9 10#include <dt-bindings/gpio/gpio.h> 11#include <dt-bindings/interrupt-controller/arm-gic.h> 12#include <dt-bindings/input/linux-event-codes.h> 13#include <dt-bindings/leds/common.h> 14 15/ { 16 model = "Tanix TX1"; 17 compatible = "oranth,tanix-tx1", "allwinner,sun50i-h616"; 18 19 aliases { 20 serial0 = &uart0; 21 ethernet0 = &sdio_wifi; 22 }; 23 24 chosen { 25 stdout-path = "serial0:115200n8"; 26 }; 27 28 gpio-keys { 29 compatible = "gpio-keys"; 30 31 key { 32 label = "hidden"; 33 linux,code = <BTN_0>; 34 gpios = <&pio 7 9 GPIO_ACTIVE_LOW>; /* PH9 */ 35 }; 36 }; 37 38 leds { 39 compatible = "gpio-leds"; 40 41 led-0 { 42 function = LED_FUNCTION_POWER; 43 color = <LED_COLOR_ID_BLUE>; 44 gpios = <&pio 7 6 GPIO_ACTIVE_HIGH>; /* PH6 */ 45 default-state = "on"; 46 }; 47 }; 48 49 wifi_pwrseq: pwrseq { 50 compatible = "mmc-pwrseq-simple"; 51 clocks = <&rtc CLK_OSC32K_FANOUT>; 52 clock-names = "ext_clock"; 53 pinctrl-0 = <&x32clk_fanout_pin>; 54 pinctrl-names = "default"; 55 reset-gpios = <&pio 6 18 GPIO_ACTIVE_LOW>; /* PG18 */ 56 }; 57 58 reg_vcc5v: vcc5v { 59 /* board wide 5V supply directly from the DC input */ 60 compatible = "regulator-fixed"; 61 regulator-name = "vcc-5v"; 62 regulator-min-microvolt = <5000000>; 63 regulator-max-microvolt = <5000000>; 64 regulator-always-on; 65 }; 66}; 67 68&codec { 69 allwinner,audio-routing = "Line Out", "LINEOUT"; 70 status = "okay"; 71}; 72 73&cpu0 { 74 cpu-supply = <®_dcdc2>; 75}; 76 77&ehci0 { 78 status = "okay"; 79}; 80 81&ir { 82 status = "okay"; 83}; 84 85&mmc1 { 86 vmmc-supply = <®_dldo1>; 87 vqmmc-supply = <®_aldo1>; 88 mmc-pwrseq = <&wifi_pwrseq>; 89 bus-width = <4>; 90 non-removable; 91 status = "okay"; 92 93 sdio_wifi: wifi@1 { 94 reg = <1>; 95 }; 96}; 97 98&mmc2 { 99 vmmc-supply = <®_dldo1>; 100 vqmmc-supply = <®_aldo1>; 101 bus-width = <8>; 102 non-removable; 103 max-frequency = <100000000>; 104 cap-mmc-hw-reset; 105 mmc-ddr-1_8v; 106 status = "okay"; 107}; 108 109&ohci0 { 110 status = "okay"; 111}; 112 113&pio { 114 vcc-pc-supply = <®_aldo1>; 115 vcc-pf-supply = <®_dldo1>; 116 vcc-pg-supply = <®_aldo1>; 117 vcc-ph-supply = <®_dldo1>; 118 vcc-pi-supply = <®_dldo1>; 119}; 120 121&r_i2c { 122 status = "okay"; 123 124 axp313: pmic@36 { 125 compatible = "x-powers,axp313a"; 126 reg = <0x36>; 127 #interrupt-cells = <1>; 128 interrupt-controller; 129 130 vin1-supply = <®_vcc5v>; 131 vin2-supply = <®_vcc5v>; 132 vin3-supply = <®_vcc5v>; 133 134 regulators { 135 /* Supplies VCC-PLL, so needs to be always on. */ 136 reg_aldo1: aldo1 { 137 regulator-always-on; 138 regulator-min-microvolt = <1800000>; 139 regulator-max-microvolt = <1800000>; 140 regulator-name = "vcc1v8"; 141 }; 142 143 /* Supplies VCC-IO, so needs to be always on. */ 144 reg_dldo1: dldo1 { 145 regulator-always-on; 146 regulator-min-microvolt = <3300000>; 147 regulator-max-microvolt = <3300000>; 148 regulator-name = "vcc3v3"; 149 }; 150 151 reg_dcdc1: dcdc1 { 152 regulator-always-on; 153 regulator-min-microvolt = <810000>; 154 regulator-max-microvolt = <990000>; 155 regulator-name = "vdd-gpu-sys"; 156 }; 157 158 reg_dcdc2: dcdc2 { 159 regulator-always-on; 160 regulator-min-microvolt = <810000>; 161 regulator-max-microvolt = <1120000>; 162 regulator-name = "vdd-cpu"; 163 }; 164 165 reg_dcdc3: dcdc3 { 166 regulator-always-on; 167 regulator-min-microvolt = <1200000>; 168 regulator-max-microvolt = <1200000>; 169 regulator-name = "vdd-dram"; 170 }; 171 }; 172 }; 173}; 174 175&uart0 { 176 pinctrl-names = "default"; 177 pinctrl-0 = <&uart0_ph_pins>; 178 status = "okay"; 179}; 180 181&usbotg { 182 dr_mode = "host"; /* USB A type receptable */ 183 status = "okay"; 184}; 185 186&usbphy { 187 status = "okay"; 188}; 189