rk3368-geekbox.dts 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281
  1. // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
  2. /*
  3. * Copyright (c) 2016 Andreas Färber
  4. */
  5. /dts-v1/;
  6. #include "rk3368.dtsi"
  7. #include <dt-bindings/input/input.h>
  8. / {
  9. model = "GeekBox";
  10. compatible = "geekbuying,geekbox", "rockchip,rk3368";
  11. aliases {
  12. mmc0 = &emmc;
  13. };
  14. chosen {
  15. stdout-path = "serial2:115200n8";
  16. };
  17. memory@0 {
  18. device_type = "memory";
  19. reg = <0x0 0x0 0x0 0x80000000>;
  20. };
  21. ext_gmac: gmac-clk {
  22. compatible = "fixed-clock";
  23. clock-frequency = <125000000>;
  24. clock-output-names = "ext_gmac";
  25. #clock-cells = <0>;
  26. };
  27. ir: ir-receiver {
  28. compatible = "gpio-ir-receiver";
  29. gpios = <&gpio3 RK_PD6 GPIO_ACTIVE_LOW>;
  30. pinctrl-names = "default";
  31. pinctrl-0 = <&ir_int>;
  32. };
  33. keys: gpio-keys {
  34. compatible = "gpio-keys";
  35. pinctrl-names = "default";
  36. pinctrl-0 = <&pwr_key>;
  37. key-power {
  38. gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_LOW>;
  39. label = "GPIO Power";
  40. linux,code = <KEY_POWER>;
  41. wakeup-source;
  42. };
  43. };
  44. leds: gpio-leds {
  45. compatible = "gpio-leds";
  46. blue_led: led-0 {
  47. gpios = <&gpio2 RK_PA2 GPIO_ACTIVE_HIGH>;
  48. label = "geekbox:blue:led";
  49. default-state = "on";
  50. };
  51. red_led: led-1 {
  52. gpios = <&gpio2 RK_PA3 GPIO_ACTIVE_HIGH>;
  53. label = "geekbox:red:led";
  54. default-state = "off";
  55. };
  56. };
  57. vcc_sys: vcc-sys-regulator {
  58. compatible = "regulator-fixed";
  59. regulator-name = "vcc_sys";
  60. regulator-min-microvolt = <5000000>;
  61. regulator-max-microvolt = <5000000>;
  62. regulator-always-on;
  63. regulator-boot-on;
  64. };
  65. };
  66. &emmc {
  67. status = "okay";
  68. bus-width = <8>;
  69. cap-mmc-highspeed;
  70. clock-frequency = <150000000>;
  71. non-removable;
  72. vmmc-supply = <&vcc_io>;
  73. vqmmc-supply = <&vcc18_flash>;
  74. pinctrl-names = "default";
  75. pinctrl-0 = <&emmc_clk>, <&emmc_cmd>, <&emmc_bus8>;
  76. };
  77. &gmac {
  78. status = "okay";
  79. phy-supply = <&vcc_lan>;
  80. phy-mode = "rgmii";
  81. clock_in_out = "input";
  82. assigned-clocks = <&cru SCLK_MAC>;
  83. assigned-clock-parents = <&ext_gmac>;
  84. pinctrl-names = "default";
  85. pinctrl-0 = <&rgmii_pins>;
  86. tx_delay = <0x30>;
  87. rx_delay = <0x10>;
  88. };
  89. &i2c0 {
  90. status = "okay";
  91. rk808: pmic@1b {
  92. compatible = "rockchip,rk808";
  93. reg = <0x1b>;
  94. pinctrl-names = "default";
  95. pinctrl-0 = <&pmic_int>, <&pmic_sleep>;
  96. interrupt-parent = <&gpio0>;
  97. interrupts = <RK_PA5 IRQ_TYPE_LEVEL_LOW>;
  98. rockchip,system-power-controller;
  99. vcc1-supply = <&vcc_sys>;
  100. vcc2-supply = <&vcc_sys>;
  101. vcc3-supply = <&vcc_sys>;
  102. vcc4-supply = <&vcc_sys>;
  103. vcc6-supply = <&vcc_sys>;
  104. vcc7-supply = <&vcc_sys>;
  105. vcc8-supply = <&vcc_io>;
  106. vcc9-supply = <&vcc_sys>;
  107. vcc10-supply = <&vcc_sys>;
  108. vcc11-supply = <&vcc_sys>;
  109. vcc12-supply = <&vcc_io>;
  110. clock-output-names = "xin32k", "rk808-clkout2";
  111. #clock-cells = <1>;
  112. regulators {
  113. vdd_cpu: DCDC_REG1 {
  114. regulator-always-on;
  115. regulator-boot-on;
  116. regulator-min-microvolt = <700000>;
  117. regulator-max-microvolt = <1500000>;
  118. regulator-name = "vdd_cpu";
  119. };
  120. vdd_log: DCDC_REG2 {
  121. regulator-always-on;
  122. regulator-boot-on;
  123. regulator-min-microvolt = <700000>;
  124. regulator-max-microvolt = <1500000>;
  125. regulator-name = "vdd_log";
  126. };
  127. vcc_ddr: DCDC_REG3 {
  128. regulator-always-on;
  129. regulator-boot-on;
  130. regulator-name = "vcc_ddr";
  131. };
  132. vcc_io: DCDC_REG4 {
  133. regulator-always-on;
  134. regulator-boot-on;
  135. regulator-min-microvolt = <3300000>;
  136. regulator-max-microvolt = <3300000>;
  137. regulator-name = "vcc_io";
  138. };
  139. vcc18_flash: LDO_REG1 {
  140. regulator-always-on;
  141. regulator-boot-on;
  142. regulator-min-microvolt = <1800000>;
  143. regulator-max-microvolt = <1800000>;
  144. regulator-name = "vcc18_flash";
  145. };
  146. vcc33_lcd: LDO_REG2 {
  147. regulator-always-on;
  148. regulator-boot-on;
  149. regulator-min-microvolt = <3300000>;
  150. regulator-max-microvolt = <3300000>;
  151. regulator-name = "vcc33_lcd";
  152. };
  153. vdd_10: LDO_REG3 {
  154. regulator-always-on;
  155. regulator-boot-on;
  156. regulator-min-microvolt = <1000000>;
  157. regulator-max-microvolt = <1000000>;
  158. regulator-name = "vdd_10";
  159. };
  160. vcca_18: LDO_REG4 {
  161. regulator-boot-on;
  162. regulator-min-microvolt = <1800000>;
  163. regulator-max-microvolt = <1800000>;
  164. regulator-name = "vcca_18";
  165. };
  166. vccio_sd: LDO_REG5 {
  167. regulator-always-on;
  168. regulator-boot-on;
  169. regulator-min-microvolt = <1800000>;
  170. regulator-max-microvolt = <3300000>;
  171. regulator-name = "vccio_sd";
  172. };
  173. vdd10_lcd: LDO_REG6 {
  174. regulator-always-on;
  175. regulator-boot-on;
  176. regulator-min-microvolt = <1000000>;
  177. regulator-max-microvolt = <1000000>;
  178. regulator-name = "vdd10_lcd";
  179. };
  180. vcc_18: LDO_REG7 {
  181. regulator-always-on;
  182. regulator-boot-on;
  183. regulator-min-microvolt = <1800000>;
  184. regulator-max-microvolt = <1800000>;
  185. regulator-name = "vcc_18";
  186. };
  187. vcc18_lcd: LDO_REG8 {
  188. regulator-always-on;
  189. regulator-boot-on;
  190. regulator-min-microvolt = <1800000>;
  191. regulator-max-microvolt = <1800000>;
  192. regulator-name = "vcc18_lcd";
  193. };
  194. vcc_sd: SWITCH_REG1 {
  195. regulator-name = "vcc_sd";
  196. };
  197. vcc_lan: SWITCH_REG2 {
  198. regulator-always-on;
  199. regulator-boot-on;
  200. regulator-name = "vcc_lan";
  201. };
  202. };
  203. };
  204. };
  205. &pinctrl {
  206. ir {
  207. ir_int: ir-int {
  208. rockchip,pins = <3 RK_PD6 RK_FUNC_GPIO &pcfg_pull_none>;
  209. };
  210. };
  211. keys {
  212. pwr_key: pwr-key {
  213. rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
  214. };
  215. };
  216. pmic {
  217. pmic_sleep: pmic-sleep {
  218. rockchip,pins = <0 RK_PA0 2 &pcfg_pull_none>;
  219. };
  220. pmic_int: pmic-int {
  221. rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>;
  222. };
  223. };
  224. };
  225. &tsadc {
  226. status = "okay";
  227. rockchip,hw-tshut-mode = <0>; /* CRU */
  228. rockchip,hw-tshut-polarity = <1>; /* high */
  229. };
  230. &uart2 {
  231. status = "okay";
  232. };
  233. &usb_host0_ehci {
  234. status = "okay";
  235. };
  236. &usb_otg {
  237. status = "okay";
  238. };
  239. &wdt {
  240. status = "okay";
  241. };