Back to home page

OSCL-LXR

 
 

    


0001 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
0002 // Copyright (C) 2019 Clément Péron <peron.clem@gmail.com>
0003 
0004 /dts-v1/;
0005 
0006 #include "sun50i-h6.dtsi"
0007 #include "sun50i-h6-cpu-opp.dtsi"
0008 
0009 #include <dt-bindings/gpio/gpio.h>
0010 
0011 / {
0012         model = "Beelink GS1";
0013         compatible = "azw,beelink-gs1", "allwinner,sun50i-h6";
0014 
0015         aliases {
0016                 ethernet0 = &emac;
0017                 serial0 = &uart0;
0018         };
0019 
0020         chosen {
0021                 stdout-path = "serial0:115200n8";
0022         };
0023 
0024         connector {
0025                 compatible = "hdmi-connector";
0026                 type = "a";
0027                 ddc-en-gpios = <&pio 7 2 GPIO_ACTIVE_HIGH>; /* PH2 */
0028 
0029                 port {
0030                         hdmi_con_in: endpoint {
0031                                 remote-endpoint = <&hdmi_out_con>;
0032                         };
0033                 };
0034         };
0035 
0036         ext_osc32k: ext_osc32k_clk {
0037                 #clock-cells = <0>;
0038                 compatible = "fixed-clock";
0039                 clock-frequency = <32768>;
0040                 clock-output-names = "ext_osc32k";
0041         };
0042 
0043         leds {
0044                 compatible = "gpio-leds";
0045 
0046                 led {
0047                         label = "beelink:white:power";
0048                         gpios = <&r_pio 0 4 GPIO_ACTIVE_HIGH>; /* PL4 */
0049                         default-state = "on";
0050                 };
0051         };
0052 
0053         reg_vcc5v: vcc5v {
0054                 /* board wide 5V supply directly from the DC jack */
0055                 compatible = "regulator-fixed";
0056                 regulator-name = "vcc-5v";
0057                 regulator-min-microvolt = <5000000>;
0058                 regulator-max-microvolt = <5000000>;
0059                 regulator-always-on;
0060         };
0061 
0062         sound-spdif {
0063                 compatible = "simple-audio-card";
0064                 simple-audio-card,name = "sun50i-h6-spdif";
0065 
0066                 simple-audio-card,cpu {
0067                         sound-dai = <&spdif>;
0068                 };
0069 
0070                 simple-audio-card,codec {
0071                         sound-dai = <&spdif_out>;
0072                 };
0073         };
0074 
0075         spdif_out: spdif-out {
0076                 #sound-dai-cells = <0>;
0077                 compatible = "linux,spdif-dit";
0078         };
0079 };
0080 
0081 &cpu0 {
0082         cpu-supply = <&reg_dcdca>;
0083 };
0084 
0085 &de {
0086         status = "okay";
0087 };
0088 
0089 &dwc3 {
0090         status = "okay";
0091 };
0092 
0093 &ehci0 {
0094         status = "okay";
0095 };
0096 
0097 &emac {
0098         pinctrl-names = "default";
0099         pinctrl-0 = <&ext_rgmii_pins>;
0100         phy-mode = "rgmii-id";
0101         phy-handle = <&ext_rgmii_phy>;
0102         phy-supply = <&reg_aldo2>;
0103         status = "okay";
0104 };
0105 
0106 &gpu {
0107         mali-supply = <&reg_dcdcc>;
0108         status = "okay";
0109 };
0110 
0111 &hdmi {
0112         status = "okay";
0113 };
0114 
0115 &hdmi_out {
0116         hdmi_out_con: endpoint {
0117                 remote-endpoint = <&hdmi_con_in>;
0118         };
0119 };
0120 
0121 &mdio {
0122         ext_rgmii_phy: ethernet-phy@1 {
0123                 compatible = "ethernet-phy-ieee802.3-c22";
0124                 reg = <1>;
0125         };
0126 };
0127 
0128 &mmc0 {
0129         vmmc-supply = <&reg_cldo1>;
0130         cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>;
0131         bus-width = <4>;
0132         status = "okay";
0133 };
0134 
0135 &mmc2 {
0136         vmmc-supply = <&reg_cldo1>;
0137         vqmmc-supply = <&reg_bldo2>;
0138         non-removable;
0139         cap-mmc-hw-reset;
0140         bus-width = <8>;
0141         status = "okay";
0142 };
0143 
0144 &ohci0 {
0145         status = "okay";
0146 };
0147 
0148 &pio {
0149         vcc-pd-supply = <&reg_cldo1>;
0150         vcc-pg-supply = <&reg_aldo1>;
0151 };
0152 
0153 &r_ir {
0154         linux,rc-map-name = "rc-beelink-gs1";
0155         status = "okay";
0156 };
0157 
0158 &r_pio {
0159         /*
0160          * FIXME: We can't add that supply for now since it would
0161          * create a circular dependency between pinctrl, the regulator
0162          * and the RSB Bus.
0163          *
0164          * vcc-pl-supply = <&reg_aldo1>;
0165          */
0166         vcc-pm-supply = <&reg_aldo1>;
0167 };
0168 
0169 &r_rsb {
0170         status = "okay";
0171 
0172         axp805: pmic@745 {
0173                 compatible = "x-powers,axp805", "x-powers,axp806";
0174                 reg = <0x745>;
0175                 interrupt-parent = <&r_intc>;
0176                 interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_LOW>;
0177                 interrupt-controller;
0178                 #interrupt-cells = <1>;
0179                 x-powers,self-working-mode;
0180                 vina-supply = <&reg_vcc5v>;
0181                 vinb-supply = <&reg_vcc5v>;
0182                 vinc-supply = <&reg_vcc5v>;
0183                 vind-supply = <&reg_vcc5v>;
0184                 vine-supply = <&reg_vcc5v>;
0185                 aldoin-supply = <&reg_vcc5v>;
0186                 bldoin-supply = <&reg_vcc5v>;
0187                 cldoin-supply = <&reg_vcc5v>;
0188 
0189                 regulators {
0190                         reg_aldo1: aldo1 {
0191                                 regulator-always-on;
0192                                 regulator-min-microvolt = <3300000>;
0193                                 regulator-max-microvolt = <3300000>;
0194                                 regulator-name = "vcc-pl";
0195                         };
0196 
0197                         reg_aldo2: aldo2 {
0198                                 regulator-min-microvolt = <3300000>;
0199                                 regulator-max-microvolt = <3300000>;
0200                                 regulator-name = "vcc-ac200";
0201                                 regulator-enable-ramp-delay = <100000>;
0202                         };
0203 
0204                         reg_aldo3: aldo3 {
0205                                 regulator-always-on;
0206                                 regulator-min-microvolt = <3300000>;
0207                                 regulator-max-microvolt = <3300000>;
0208                                 regulator-name = "vcc25-dram";
0209                         };
0210 
0211                         reg_bldo1: bldo1 {
0212                                 regulator-always-on;
0213                                 regulator-min-microvolt = <1800000>;
0214                                 regulator-max-microvolt = <1800000>;
0215                                 regulator-name = "vcc-bias-pll";
0216                         };
0217 
0218                         reg_bldo2: bldo2 {
0219                                 regulator-always-on;
0220                                 regulator-min-microvolt = <1800000>;
0221                                 regulator-max-microvolt = <1800000>;
0222                                 regulator-name = "vcc-efuse-pcie-hdmi-io";
0223                         };
0224 
0225                         reg_bldo3: bldo3 {
0226                                 regulator-always-on;
0227                                 regulator-min-microvolt = <1800000>;
0228                                 regulator-max-microvolt = <1800000>;
0229                                 regulator-name = "vcc-dcxoio";
0230                         };
0231 
0232                         bldo4 {
0233                                 /* unused */
0234                         };
0235 
0236                         reg_cldo1: cldo1 {
0237                                 regulator-always-on;
0238                                 regulator-min-microvolt = <3300000>;
0239                                 regulator-max-microvolt = <3300000>;
0240                                 regulator-name = "vcc-3v3";
0241                         };
0242 
0243                         reg_cldo2: cldo2 {
0244                                 regulator-min-microvolt = <3300000>;
0245                                 regulator-max-microvolt = <3300000>;
0246                                 regulator-name = "vcc-wifi-1";
0247                         };
0248 
0249                         reg_cldo3: cldo3 {
0250                                 regulator-min-microvolt = <3300000>;
0251                                 regulator-max-microvolt = <3300000>;
0252                                 regulator-name = "vcc-wifi-2";
0253                         };
0254 
0255                         reg_dcdca: dcdca {
0256                                 regulator-always-on;
0257                                 regulator-min-microvolt = <810000>;
0258                                 regulator-max-microvolt = <1160000>;
0259                                 regulator-ramp-delay = <2500>;
0260                                 regulator-name = "vdd-cpu";
0261                         };
0262 
0263                         reg_dcdcc: dcdcc {
0264                                 regulator-enable-ramp-delay = <32000>;
0265                                 regulator-min-microvolt = <810000>;
0266                                 regulator-max-microvolt = <1080000>;
0267                                 regulator-ramp-delay = <2500>;
0268                                 regulator-name = "vdd-gpu";
0269                         };
0270 
0271                         reg_dcdcd: dcdcd {
0272                                 regulator-always-on;
0273                                 regulator-min-microvolt = <960000>;
0274                                 regulator-max-microvolt = <960000>;
0275                                 regulator-name = "vdd-sys";
0276                         };
0277 
0278                         reg_dcdce: dcdce {
0279                                 regulator-always-on;
0280                                 regulator-min-microvolt = <1200000>;
0281                                 regulator-max-microvolt = <1200000>;
0282                                 regulator-name = "vcc-dram";
0283                         };
0284 
0285                         sw {
0286                                 /* unused */
0287                         };
0288                 };
0289         };
0290 };
0291 
0292 &spdif {
0293         status = "okay";
0294 };
0295 
0296 &uart0 {
0297         pinctrl-names = "default";
0298         pinctrl-0 = <&uart0_ph_pins>;
0299         status = "okay";
0300 };
0301 
0302 &usb2otg {
0303         dr_mode = "host";
0304         status = "okay";
0305 };
0306 
0307 &usb2phy {
0308         usb0_vbus-supply = <&reg_vcc5v>;
0309         status = "okay";
0310 };
0311 
0312 &usb3phy {
0313         status = "okay";
0314 };