xref: /rk3399_rockchip-uboot/arch/arm/dts/sun5i-a10s-mk802.dts (revision c6b968da78ce3fa7224c0ddf15fe170c7c05b27e)
153ab4af3SHans de Goede/*
253ab4af3SHans de Goede * Copyright 2015 Hans de Goede <hdegoede@redhat.com>
353ab4af3SHans de Goede *
453ab4af3SHans de Goede * This file is dual-licensed: you can use it either under the terms
553ab4af3SHans de Goede * of the GPL or the X11 license, at your option. Note that this dual
653ab4af3SHans de Goede * licensing only applies to this file, and not this project as a
753ab4af3SHans de Goede * whole.
853ab4af3SHans de Goede *
953ab4af3SHans de Goede *  a) This file is free software; you can redistribute it and/or
1053ab4af3SHans de Goede *     modify it under the terms of the GNU General Public License as
1153ab4af3SHans de Goede *     published by the Free Software Foundation; either version 2 of the
1253ab4af3SHans de Goede *     License, or (at your option) any later version.
1353ab4af3SHans de Goede *
1453ab4af3SHans de Goede *     This file is distributed in the hope that it will be useful,
1553ab4af3SHans de Goede *     but WITHOUT ANY WARRANTY; without even the implied warranty of
1653ab4af3SHans de Goede *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1753ab4af3SHans de Goede *     GNU General Public License for more details.
1853ab4af3SHans de Goede *
1953ab4af3SHans de Goede * Or, alternatively,
2053ab4af3SHans de Goede *
2153ab4af3SHans de Goede *  b) Permission is hereby granted, free of charge, to any person
2253ab4af3SHans de Goede *     obtaining a copy of this software and associated documentation
2353ab4af3SHans de Goede *     files (the "Software"), to deal in the Software without
2453ab4af3SHans de Goede *     restriction, including without limitation the rights to use,
2553ab4af3SHans de Goede *     copy, modify, merge, publish, distribute, sublicense, and/or
2653ab4af3SHans de Goede *     sell copies of the Software, and to permit persons to whom the
2753ab4af3SHans de Goede *     Software is furnished to do so, subject to the following
2853ab4af3SHans de Goede *     conditions:
2953ab4af3SHans de Goede *
3053ab4af3SHans de Goede *     The above copyright notice and this permission notice shall be
3153ab4af3SHans de Goede *     included in all copies or substantial portions of the Software.
3253ab4af3SHans de Goede *
3353ab4af3SHans de Goede *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
3453ab4af3SHans de Goede *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
3553ab4af3SHans de Goede *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
3653ab4af3SHans de Goede *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
3753ab4af3SHans de Goede *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
3853ab4af3SHans de Goede *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
3953ab4af3SHans de Goede *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
4053ab4af3SHans de Goede *     OTHER DEALINGS IN THE SOFTWARE.
4153ab4af3SHans de Goede */
4253ab4af3SHans de Goede
4353ab4af3SHans de Goede/dts-v1/;
4453ab4af3SHans de Goede#include "sun5i-a10s.dtsi"
4553ab4af3SHans de Goede#include "sunxi-common-regulators.dtsi"
4653ab4af3SHans de Goede#include <dt-bindings/gpio/gpio.h>
4753ab4af3SHans de Goede
4853ab4af3SHans de Goede/ {
4953ab4af3SHans de Goede	model = "MK802-A10s";
5053ab4af3SHans de Goede	compatible = "allwinner,a10s-mk802", "allwinner,sun5i-a10s";
5153ab4af3SHans de Goede
5253ab4af3SHans de Goede	aliases {
5353ab4af3SHans de Goede		serial0 = &uart0;
5453ab4af3SHans de Goede	};
5553ab4af3SHans de Goede
5653ab4af3SHans de Goede	chosen {
5753ab4af3SHans de Goede		stdout-path = "serial0:115200n8";
5853ab4af3SHans de Goede	};
5953ab4af3SHans de Goede
6053ab4af3SHans de Goede	leds {
6153ab4af3SHans de Goede		compatible = "gpio-leds";
6253ab4af3SHans de Goede		pinctrl-names = "default";
6353ab4af3SHans de Goede		pinctrl-0 = <&led_pins_mk802>;
6453ab4af3SHans de Goede
6553ab4af3SHans de Goede		red {
6653ab4af3SHans de Goede			label = "mk802:red:usr";
6753ab4af3SHans de Goede			gpios = <&pio 1 2 GPIO_ACTIVE_HIGH>; /* PB2 */
6853ab4af3SHans de Goede		};
6953ab4af3SHans de Goede	};
7053ab4af3SHans de Goede};
7153ab4af3SHans de Goede
7253ab4af3SHans de Goede&ehci0 {
7353ab4af3SHans de Goede	status = "okay";
7453ab4af3SHans de Goede};
7553ab4af3SHans de Goede
76*860fbdd4SHans de Goede&i2c0 {
77*860fbdd4SHans de Goede	pinctrl-names = "default";
78*860fbdd4SHans de Goede	pinctrl-0 = <&i2c0_pins_a>;
79*860fbdd4SHans de Goede	status = "okay";
80*860fbdd4SHans de Goede
81*860fbdd4SHans de Goede	axp152: pmic@30 {
82*860fbdd4SHans de Goede		compatible = "x-powers,axp152";
83*860fbdd4SHans de Goede		reg = <0x30>;
84*860fbdd4SHans de Goede		interrupts = <0>;
85*860fbdd4SHans de Goede		interrupt-controller;
86*860fbdd4SHans de Goede		#interrupt-cells = <1>;
87*860fbdd4SHans de Goede	};
88*860fbdd4SHans de Goede};
89*860fbdd4SHans de Goede
9053ab4af3SHans de Goede&mmc0 {
9153ab4af3SHans de Goede	pinctrl-names = "default";
9253ab4af3SHans de Goede	pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_mk802>;
9353ab4af3SHans de Goede	vmmc-supply = <&reg_vcc3v3>;
9453ab4af3SHans de Goede	bus-width = <4>;
9553ab4af3SHans de Goede	cd-gpios = <&pio 6 1 GPIO_ACTIVE_HIGH>; /* PG1 */
9653ab4af3SHans de Goede	cd-inverted;
9753ab4af3SHans de Goede	status = "okay";
9853ab4af3SHans de Goede};
9953ab4af3SHans de Goede
100*860fbdd4SHans de Goede&mmc1 {
101*860fbdd4SHans de Goede	pinctrl-names = "default";
102*860fbdd4SHans de Goede	pinctrl-0 = <&mmc1_pins_a>;
103*860fbdd4SHans de Goede	vmmc-supply = <&reg_vcc3v3>;
104*860fbdd4SHans de Goede	bus-width = <4>;
105*860fbdd4SHans de Goede	non-removable;
106*860fbdd4SHans de Goede	status = "okay";
107*860fbdd4SHans de Goede};
108*860fbdd4SHans de Goede
10953ab4af3SHans de Goede&ohci0 {
11053ab4af3SHans de Goede	status = "okay";
11153ab4af3SHans de Goede};
11253ab4af3SHans de Goede
113*860fbdd4SHans de Goede&otg_sram {
114*860fbdd4SHans de Goede	status = "okay";
115*860fbdd4SHans de Goede};
116*860fbdd4SHans de Goede
11753ab4af3SHans de Goede&pio {
11853ab4af3SHans de Goede	led_pins_mk802: led_pins@0 {
11953ab4af3SHans de Goede		allwinner,pins = "PB2";
12053ab4af3SHans de Goede		allwinner,function = "gpio_out";
12153ab4af3SHans de Goede		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
12253ab4af3SHans de Goede		allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
12353ab4af3SHans de Goede	};
12453ab4af3SHans de Goede
12553ab4af3SHans de Goede	mmc0_cd_pin_mk802: mmc0_cd_pin@0 {
12653ab4af3SHans de Goede		allwinner,pins = "PG1";
12753ab4af3SHans de Goede		allwinner,function = "gpio_in";
12853ab4af3SHans de Goede		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
12953ab4af3SHans de Goede		allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
13053ab4af3SHans de Goede	};
13153ab4af3SHans de Goede
13253ab4af3SHans de Goede	usb1_vbus_pin_mk802: usb1_vbus_pin@0 {
13353ab4af3SHans de Goede		allwinner,pins = "PB10";
13453ab4af3SHans de Goede		allwinner,function = "gpio_out";
13553ab4af3SHans de Goede		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
13653ab4af3SHans de Goede		allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
13753ab4af3SHans de Goede	};
13853ab4af3SHans de Goede};
13953ab4af3SHans de Goede
14053ab4af3SHans de Goede&reg_usb1_vbus {
14153ab4af3SHans de Goede	pinctrl-0 = <&usb1_vbus_pin_mk802>;
14253ab4af3SHans de Goede	gpio = <&pio 1 10 GPIO_ACTIVE_HIGH>; /* PB10 */
14353ab4af3SHans de Goede	status = "okay";
14453ab4af3SHans de Goede};
14553ab4af3SHans de Goede
14653ab4af3SHans de Goede&uart0 {
14753ab4af3SHans de Goede	pinctrl-names = "default";
14853ab4af3SHans de Goede	pinctrl-0 = <&uart0_pins_a>;
14953ab4af3SHans de Goede	status = "okay";
15053ab4af3SHans de Goede};
15153ab4af3SHans de Goede
152*860fbdd4SHans de Goede&usb_otg {
153*860fbdd4SHans de Goede	dr_mode = "otg";
154*860fbdd4SHans de Goede	status = "okay";
155*860fbdd4SHans de Goede};
156*860fbdd4SHans de Goede
15753ab4af3SHans de Goede&usbphy {
15853ab4af3SHans de Goede	usb1_vbus-supply = <&reg_usb1_vbus>;
15953ab4af3SHans de Goede	status = "okay";
16053ab4af3SHans de Goede};
161