2 * This file is dual-licensed: you can use it either under the terms
3 * of the GPL or the X11 license, at your option. Note that this dual
4 * licensing only applies to this file, and not this project as a
7 * a) This file is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License as
9 * published by the Free Software Foundation; either version 2 of the
10 * License, or (at your option) any later version.
12 * This file is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
19 * b) Permission is hereby granted, free of charge, to any person
20 * obtaining a copy of this software and associated documentation
21 * files (the "Software"), to deal in the Software without
22 * restriction, including without limitation the rights to use,
23 * copy, modify, merge, publish, distribute, sublicense, and/or
24 * sell copies of the Software, and to permit persons to whom the
25 * Software is furnished to do so, subject to the following
28 * The above copyright notice and this permission notice shall be
29 * included in all copies or substantial portions of the Software.
31 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
32 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
33 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
34 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
35 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
36 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
37 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
38 * OTHER DEALINGS IN THE SOFTWARE.
42 #include "rk3288-rock2-som.dtsi"
45 model = "Radxa Rock 2 Square";
46 compatible = "radxa,rock2-square", "rockchip,rk3288";
49 stdout-path = "serial2:115200n8";
53 compatible = "gpio-leds";
56 gpios = <&gpio7 RK_PB7 GPIO_ACTIVE_LOW>;
57 label = "rock2:green:state1";
58 linux,default-trigger = "heartbeat";
62 gpios = <&gpio0 RK_PB3 GPIO_ACTIVE_LOW>;
63 label = "rock2:blue:state2";
64 linux,default-trigger = "mmc0";
69 compatible = "gpio-ir-receiver";
70 gpios = <&gpio8 RK_PA1 GPIO_ACTIVE_LOW>;
71 pinctrl-names = "default";
72 pinctrl-0 = <&ir_int>;
76 compatible = "simple-audio-card";
77 simple-audio-card,name = "SPDIF";
78 simple-audio-card,dai-link@1 { /* S/PDIF - S/PDIF */
79 cpu { sound-dai = <&spdif>; };
80 codec { sound-dai = <&spdif_out>; };
84 sata_pwr: sata-prw-regulator {
85 compatible = "regulator-fixed";
87 gpio = <&gpio0 13 GPIO_ACTIVE_HIGH>;
88 pinctrl-names = "default";
89 pinctrl-0 = <&sata_pwr_en>;
90 /* Always turn on the 5V sata power connector */
92 regulator-name = "sata_pwr";
95 spdif_out: spdif-out {
96 compatible = "linux,spdif-dit";
97 #sound-dai-cells = <0>;
101 compatible = "rockchip,rk3288-hdmi-analog";
102 pinctrl-names = "default";
103 pinctrl-0 = <&phone_ctl>, <&hp_det>;
104 rockchip,audio-codec = <&es8388>;
105 rockchip,hp-det-gpios = <&gpio7 7 GPIO_ACTIVE_HIGH>;
106 rockchip,hp-en-gpios = <&gpio8 0 GPIO_ACTIVE_HIGH>;
107 rockchip,i2s-controller = <&i2s>;
108 rockchip,model = "I2S";
109 rockchip,routing = "Analog", "LOUT2",
113 sdio_pwrseq: sdio-pwrseq {
114 compatible = "mmc-pwrseq-simple";
116 clock-names = "ext_clock";
117 pinctrl-names = "default";
118 pinctrl-0 = <&wifi_enable>;
119 reset-gpios = <&gpio4 RK_PD4 GPIO_ACTIVE_LOW>;
122 vcc_usb_host: vcc-host-regulator {
123 compatible = "regulator-fixed";
125 gpio = <&gpio0 RK_PB6 GPIO_ACTIVE_HIGH>;
126 pinctrl-names = "default";
127 pinctrl-0 = <&host_vbus_drv>;
128 regulator-name = "vcc_host";
131 vcc_sd: sdmmc-regulator {
132 compatible = "regulator-fixed";
133 gpio = <&gpio7 RK_PB3 GPIO_ACTIVE_LOW>;
134 pinctrl-names = "default";
135 pinctrl-0 = <&sdmmc_pwr>;
136 regulator-name = "vcc_sd";
137 regulator-min-microvolt = <3300000>;
138 regulator-max-microvolt = <3300000>;
139 vin-supply = <&vcc_io>;
148 mmc-pwrseq = <&sdio_pwrseq>;
150 pinctrl-names = "default";
151 pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk &sdio0_int>;
152 vmmc-supply = <&vcc_io>;
153 vqmmc-supply = <&vcc_18>;
161 card-detect-delay = <200>;
162 disable-wp; /* wp not hooked up */
163 pinctrl-names = "default";
164 pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_cd &sdmmc_bus4>;
165 vmmc-supply = <&vcc_sd>;
166 vqmmc-supply = <&vccio_sd>;
175 ddc-i2c-bus = <&i2c5>;
180 hym8563: hym8563@51 {
181 compatible = "haoyu,hym8563";
184 clock-frequency = <32768>;
185 clock-output-names = "xin32k";
186 interrupt-parent = <&gpio0>;
187 interrupts = <RK_PA4 IRQ_TYPE_EDGE_FALLING>;
188 pinctrl-names = "default";
189 pinctrl-0 = <&pmic_int>;
198 compatible = "everest,es8388", "everest,es8328";
200 AVDD-supply = <&vccio_codec>;
201 DVDD-supply = <&vccio_codec>;
202 HPVDD-supply = <&vccio_codec>;
203 PVDD-supply = <&vccio_codec>;
204 clocks = <&cru SCLK_I2S0_OUT>;
219 rockchip,pins = <8 1 RK_FUNC_GPIO &pcfg_pull_up>;
225 rockchip,pins = <0 4 RK_FUNC_GPIO &pcfg_pull_up>;
231 rockchip,pins = <7 7 RK_FUNC_GPIO &pcfg_pull_none>;
234 phone_ctl: phone-ctl {
235 rockchip,pins = <8 0 RK_FUNC_GPIO &pcfg_pull_up>;
240 host_vbus_drv: host-vbus-drv {
241 rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>;
246 sata_pwr_en: sata-pwr-en {
247 rockchip,pins = <0 13 RK_FUNC_GPIO &pcfg_pull_none>;
252 sdmmc_pwr: sdmmc-pwr {
253 rockchip,pins = <7 11 RK_FUNC_GPIO &pcfg_pull_none>;
258 wifi_enable: wifi-enable {
259 rockchip,pins = <4 28 RK_FUNC_GPIO &pcfg_pull_none>;
277 vbus-supply = <&vcc_usb_host>;