blob: 658eb7ddeaf5fe1fe9515cd016f11714fbb055b0 [file] [log] [blame]
Paweł Jaroszcbab8202016-10-08 22:22:30 +02001/*
2 * Copyright (c) 2016 Paweł Jarosz <paweljarosz3691@gmail.com>
3 *
4 * This file is dual-licensed: you can use it either under the terms
5 * of the GPL or the X11 license, at your option. Note that this dual
6 * licensing only applies to this file, and not this project as a
7 * whole.
8 *
9 * a) This file is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License as
11 * published by the Free Software Foundation; either version 2 of the
12 * License, or (at your option) any later version.
13 *
14 * This file is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
18 *
19 * Or, alternatively,
20 *
21 * b) Permission is hereby granted, free of charge, to any person
22 * obtaining a copy of this software and associated documentation
23 * files (the "Software"), to deal in the Software without
24 * restriction, including without limitation the rights to use,
25 * copy, modify, merge, publish, distribute, sublicense, and/or
26 * sell copies of the Software, and to permit persons to whom the
27 * Software is furnished to do so, subject to the following
28 * conditions:
29 *
30 * The above copyright notice and this permission notice shall be
31 * included in all copies or substantial portions of the Software.
32 *
33 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
34 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
35 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
36 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
37 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
38 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
39 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
40 * OTHER DEALINGS IN THE SOFTWARE.
41 */
42
43/dts-v1/;
44#include "rk3066a.dtsi"
45
46/ {
47 model = "Rikomagic MK808";
48 compatible = "rikomagic,mk808", "rockchip,rk3066a";
49
50 chosen {
51 stdout-path = "serial2:115200n8";
52 };
53
54 memory@60000000 {
55 reg = <0x60000000 0x40000000>;
56 device_type = "memory";
57 };
58
59 gpio-leds {
60 compatible = "gpio-leds";
61
62 blue {
63 label = "mk808:blue:power";
64 gpios = <&gpio0 3 GPIO_ACTIVE_HIGH>;
65 default-state = "off";
66 linux,default-trigger = "default-on";
67 };
68 };
69
70 vcc_io: vcc-io {
71 compatible = "regulator-fixed";
72 regulator-name = "vcc_io";
73 regulator-min-microvolt = <3300000>;
74 regulator-max-microvolt = <3300000>;
75 };
76
77 vcc_host: usb-host-regulator {
78 compatible = "regulator-fixed";
79 enable-active-high;
80 gpio = <&gpio0 6 GPIO_ACTIVE_HIGH>;
81 pinctrl-0 = <&host_drv>;
82 pinctrl-names = "default";
83 regulator-always-on;
84 regulator-name = "host-pwr";
85 regulator-min-microvolt = <5000000>;
86 regulator-max-microvolt = <5000000>;
87 startup-delay-us = <100000>;
88 vin-supply = <&vcc_io>;
89 };
90
91 vcc_otg: usb-otg-regulator {
92 compatible = "regulator-fixed";
93 enable-active-high;
94 gpio = <&gpio0 5 GPIO_ACTIVE_HIGH>;
95 pinctrl-0 = <&otg_drv>;
96 pinctrl-names = "default";
97 regulator-always-on;
98 regulator-name = "vcc_otg";
99 regulator-min-microvolt = <5000000>;
100 regulator-max-microvolt = <5000000>;
101 startup-delay-us = <100000>;
102 vin-supply = <&vcc_io>;
103 };
104
105 vcc_sd: sdmmc-regulator {
106 compatible = "regulator-fixed";
107 gpio = <&gpio3 7 GPIO_ACTIVE_LOW>;
108 pinctrl-0 = <&sdmmc_pwr>;
109 pinctrl-names = "default";
110 regulator-name = "vcc_sd";
111 regulator-min-microvolt = <3300000>;
112 regulator-max-microvolt = <3300000>;
113 startup-delay-us = <100000>;
114 vin-supply = <&vcc_io>;
115 };
116
117 vcc_wifi: sdio-regulator {
118 compatible = "regulator-fixed";
119 enable-active-high;
120 gpio = <&gpio3 24 GPIO_ACTIVE_HIGH>;
121 pinctrl-0 = <&wifi_pwr>;
122 pinctrl-names = "default";
123 regulator-name = "vcc_wifi";
124 regulator-min-microvolt = <3300000>;
125 regulator-max-microvolt = <3300000>;
126 startup-delay-us = <100000>;
127 vin-supply = <&vcc_io>;
128 };
129};
130
131&mmc0 {
132 bus-width = <4>;
133 cap-mmc-highspeed;
134 cap-sd-highspeed;
135 num-slots = <1>;
136 vmmc-supply = <&vcc_sd>;
137 status = "okay";
138};
139
140&mmc1 {
141 bus-width = <4>;
142 disable-wp;
143 non-removable;
144 num-slots = <1>;
145 pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_bus4>;
146 pinctrl-names = "default";
147 vmmc-supply = <&vcc_wifi>;
148 status = "okay";
149};
150
151&pinctrl {
152 usb-host {
153 host_drv: host-drv {
154 rockchip,pins = <RK_GPIO0 6 RK_FUNC_GPIO &pcfg_pull_default>;
155 };
156 };
157
158 usb-otg {
159 otg_drv: otg-drv {
160 rockchip,pins = <RK_GPIO0 5 RK_FUNC_GPIO &pcfg_pull_default>;
161 };
162 };
163
164 sdmmc {
165 sdmmc_pwr: sdmmc-pwr {
166 rockchip,pins = <RK_GPIO3 7 RK_FUNC_GPIO &pcfg_pull_default>;
167 };
168 };
169
170 sdio {
171 wifi_pwr: wifi-pwr {
172 rockchip,pins = <RK_GPIO3 24 RK_FUNC_GPIO &pcfg_pull_none>;
173 };
174 };
175};
176
177&uart2 {
178 status = "okay";
179};
180
181&usb_host {
182 status = "okay";
183};
184
185&usb_otg {
186 status = "okay";
187};
188
189&usbphy {
190 status = "okay";
191};
192
193&wdt {
194 status = "okay";
195};