Back to home page

OSCL-LXR

 
 

    


0001 /*
0002  * Copyright 2015 Vishnu Patekar
0003  * Vishnu Patekar <vishnupatekar0510@gmail.com>
0004  *
0005  * This file is dual-licensed: you can use it either under the terms
0006  * of the GPL or the X11 license, at your option. Note that this dual
0007  * licensing only applies to this file, and not this project as a
0008  * whole.
0009  *
0010  *  a) This file is free software; you can redistribute it and/or
0011  *     modify it under the terms of the GNU General Public License as
0012  *     published by the Free Software Foundation; either version 2 of the
0013  *     License, or (at your option) any later version.
0014  *
0015  *     This file is distributed in the hope that it will be useful,
0016  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
0017  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0018  *     GNU General Public License for more details.
0019  *
0020  * Or, alternatively,
0021  *
0022  *  b) Permission is hereby granted, free of charge, to any person
0023  *     obtaining a copy of this software and associated documentation
0024  *     files (the "Software"), to deal in the Software without
0025  *     restriction, including without limitation the rights to use,
0026  *     copy, modify, merge, publish, distribute, sublicense, and/or
0027  *     sell copies of the Software, and to permit persons to whom the
0028  *     Software is furnished to do so, subject to the following
0029  *     conditions:
0030  *
0031  *     The above copyright notice and this permission notice shall be
0032  *     included in all copies or substantial portions of the Software.
0033  *
0034  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
0035  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
0036  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
0037  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
0038  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
0039  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
0040  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
0041  *     OTHER DEALINGS IN THE SOFTWARE.
0042  */
0043 
0044 /dts-v1/;
0045 #include "sun8i-a83t.dtsi"
0046 
0047 #include <dt-bindings/gpio/gpio.h>
0048 
0049 / {
0050         model = "Allwinner A83T H8Homlet Proto Dev Board v2.0";
0051         compatible = "allwinner,h8homlet-v2", "allwinner,sun8i-a83t";
0052 
0053         aliases {
0054                 serial0 = &uart0;
0055         };
0056 
0057         chosen {
0058                 stdout-path = "serial0:115200n8";
0059         };
0060 
0061         reg_usb0_vbus: reg-usb0-vbus {
0062                 compatible = "regulator-fixed";
0063                 regulator-name = "usb0-vbus";
0064                 regulator-min-microvolt = <5000000>;
0065                 regulator-max-microvolt = <5000000>;
0066                 regulator-boot-on;
0067                 enable-active-high;
0068                 gpio = <&r_pio 0 5 GPIO_ACTIVE_HIGH>; /* PL5 */
0069         };
0070 
0071         reg_usb1_vbus: reg-usb1-vbus {
0072                 compatible = "regulator-fixed";
0073                 regulator-name = "usb1-vbus";
0074                 regulator-min-microvolt = <5000000>;
0075                 regulator-max-microvolt = <5000000>;
0076                 regulator-boot-on;
0077                 enable-active-high;
0078                 gpio = <&r_pio 0 6 GPIO_ACTIVE_HIGH>; /* PL6 */
0079         };
0080 };
0081 
0082 &cpu0 {
0083         cpu-supply = <&reg_dcdc2>;
0084 };
0085 
0086 &cpu100 {
0087         cpu-supply = <&reg_dcdc3>;
0088 };
0089 
0090 &ehci0 {
0091         status = "okay";
0092 };
0093 
0094 &mmc0 {
0095         pinctrl-names = "default";
0096         pinctrl-0 = <&mmc0_pins>;
0097         vmmc-supply = <&reg_dcdc1>;
0098         cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
0099         bus-width = <4>;
0100         status = "okay";
0101 };
0102 
0103 &mmc2 {
0104         pinctrl-names = "default";
0105         pinctrl-0 = <&mmc2_8bit_emmc_pins>;
0106         vmmc-supply = <&reg_dcdc1>;
0107         vqmmc-supply = <&reg_dcdc1>;
0108         bus-width = <8>;
0109         non-removable;
0110         cap-mmc-hw-reset;
0111         status = "okay";
0112 };
0113 
0114 &ohci0 {
0115         status = "okay";
0116 };
0117 
0118 &r_rsb {
0119         status = "okay";
0120 
0121         axp81x: pmic@3a3 {
0122                 compatible = "x-powers,axp818", "x-powers,axp813";
0123                 reg = <0x3a3>;
0124                 interrupt-parent = <&r_intc>;
0125                 interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_LOW>;
0126                 eldoin-supply = <&reg_dcdc1>;
0127                 swin-supply = <&reg_dcdc1>;
0128         };
0129 
0130         ac100: codec@e89 {
0131                 compatible = "x-powers,ac100";
0132                 reg = <0xe89>;
0133 
0134                 ac100_codec: codec {
0135                         compatible = "x-powers,ac100-codec";
0136                         interrupt-parent = <&r_pio>;
0137                         interrupts = <0 11 IRQ_TYPE_LEVEL_LOW>; /* PL11 */
0138                         #clock-cells = <0>;
0139                         clock-output-names = "4M_adda";
0140                 };
0141 
0142                 ac100_rtc: rtc {
0143                         compatible = "x-powers,ac100-rtc";
0144                         interrupt-parent = <&r_intc>;
0145                         interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_LOW>;
0146                         clocks = <&ac100_codec>;
0147                         #clock-cells = <1>;
0148                         clock-output-names = "cko1_rtc",
0149                                              "cko2_rtc",
0150                                              "cko3_rtc";
0151                 };
0152         };
0153 };
0154 
0155 #include "axp81x.dtsi"
0156 
0157 &ac_power_supply {
0158         status = "okay";
0159 };
0160 
0161 &reg_aldo1 {
0162         regulator-always-on;
0163         regulator-min-microvolt = <1800000>;
0164         regulator-max-microvolt = <1800000>;
0165         regulator-name = "vcc-1v8";
0166 };
0167 
0168 &reg_aldo2 {
0169         regulator-always-on;
0170         regulator-min-microvolt = <1800000>;
0171         regulator-max-microvolt = <1800000>;
0172         regulator-name = "dram-pll";
0173 };
0174 
0175 &reg_aldo3 {
0176         regulator-always-on;
0177         regulator-min-microvolt = <3000000>;
0178         regulator-max-microvolt = <3000000>;
0179         regulator-name = "avcc";
0180 };
0181 
0182 &reg_dcdc1 {
0183         regulator-always-on;
0184         regulator-min-microvolt = <3300000>;
0185         regulator-max-microvolt = <3300000>;
0186         regulator-name = "vcc-3v3";
0187 };
0188 
0189 &reg_dcdc2 {
0190         regulator-always-on;
0191         regulator-min-microvolt = <700000>;
0192         regulator-max-microvolt = <1100000>;
0193         regulator-name = "vdd-cpua";
0194 };
0195 
0196 &reg_dcdc3 {
0197         regulator-always-on;
0198         regulator-min-microvolt = <700000>;
0199         regulator-max-microvolt = <1100000>;
0200         regulator-name = "vdd-cpub";
0201 };
0202 
0203 &reg_dcdc4 {
0204         regulator-min-microvolt = <700000>;
0205         regulator-max-microvolt = <1100000>;
0206         regulator-name = "vdd-gpu";
0207 };
0208 
0209 &reg_dcdc5 {
0210         regulator-always-on;
0211         regulator-min-microvolt = <1500000>;
0212         regulator-max-microvolt = <1500000>;
0213         regulator-name = "vcc-dram";
0214 };
0215 
0216 &reg_dcdc6 {
0217         regulator-always-on;
0218         regulator-min-microvolt = <900000>;
0219         regulator-max-microvolt = <900000>;
0220         regulator-name = "vdd-sys";
0221 };
0222 
0223 &reg_dldo2 {
0224         regulator-min-microvolt = <3300000>;
0225         regulator-max-microvolt = <3300000>;
0226         regulator-name = "vcc-mipi";
0227 };
0228 
0229 &reg_dldo4 {
0230         /*
0231          * The PHY requires 20ms after all voltages are applied until core
0232          * logic is ready and 30ms after the reset pin is de-asserted.
0233          * Set a 100ms delay to account for PMIC ramp time and board traces.
0234          */
0235         regulator-enable-ramp-delay = <100000>;
0236         regulator-min-microvolt = <3300000>;
0237         regulator-max-microvolt = <3300000>;
0238         regulator-name = "vcc-ephy";
0239 };
0240 
0241 &reg_fldo1 {
0242         regulator-min-microvolt = <1080000>;
0243         regulator-max-microvolt = <1320000>;
0244         regulator-name = "vdd12-hsic";
0245 };
0246 
0247 &reg_fldo2 {
0248         /*
0249          * Despite the embedded CPUs core not being used in any way,
0250          * this must remain on or the system will hang.
0251          */
0252         regulator-always-on;
0253         regulator-min-microvolt = <700000>;
0254         regulator-max-microvolt = <1100000>;
0255         regulator-name = "vdd-cpus";
0256 };
0257 
0258 &reg_rtc_ldo {
0259         regulator-name = "vcc-rtc";
0260 };
0261 
0262 &reg_sw {
0263         regulator-name = "vcc-wifi";
0264 };
0265 
0266 &uart0 {
0267         pinctrl-names = "default";
0268         pinctrl-0 = <&uart0_pb_pins>;
0269         status = "okay";
0270 };
0271 
0272 &usbphy {
0273         usb0_vbus-supply = <&reg_usb0_vbus>;
0274         usb1_vbus-supply = <&reg_usb1_vbus>;
0275         status = "okay";
0276 };
0277 
0278 &usb_otg {
0279         dr_mode = "host";
0280         status = "okay";
0281 };