meson-gxm-rbox-pro.dts 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239
  1. /*
  2. * Copyright (c) 2016-2017 Andreas Färber
  3. *
  4. * Based on nexbox-a1:
  5. *
  6. * Copyright (c) 2016 BayLibre, SAS.
  7. * Author: Neil Armstrong <narmstrong@baylibre.com>
  8. *
  9. * Copyright (c) 2016 Endless Computers, Inc.
  10. * Author: Carlo Caione <carlo@endlessm.com>
  11. *
  12. * This file is dual-licensed: you can use it either under the terms
  13. * of the GPL or the X11 license, at your option. Note that this dual
  14. * licensing only applies to this file, and not this project as a
  15. * whole.
  16. *
  17. * a) This library is free software; you can redistribute it and/or
  18. * modify it under the terms of the GNU General Public License as
  19. * published by the Free Software Foundation; either version 2 of the
  20. * License, or (at your option) any later version.
  21. *
  22. * This library is distributed in the hope that it will be useful,
  23. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  24. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  25. * GNU General Public License for more details.
  26. *
  27. * Or, alternatively,
  28. *
  29. * b) Permission is hereby granted, free of charge, to any person
  30. * obtaining a copy of this software and associated documentation
  31. * files (the "Software"), to deal in the Software without
  32. * restriction, including without limitation the rights to use,
  33. * copy, modify, merge, publish, distribute, sublicense, and/or
  34. * sell copies of the Software, and to permit persons to whom the
  35. * Software is furnished to do so, subject to the following
  36. * conditions:
  37. *
  38. * The above copyright notice and this permission notice shall be
  39. * included in all copies or substantial portions of the Software.
  40. *
  41. * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  42. * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
  43. * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  44. * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
  45. * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
  46. * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  47. * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  48. * OTHER DEALINGS IN THE SOFTWARE.
  49. */
  50. /dts-v1/;
  51. #include "meson-gxm.dtsi"
  52. / {
  53. compatible = "kingnovel,r-box-pro", "amlogic,s912", "amlogic,meson-gxm";
  54. model = "R-Box Pro";
  55. aliases {
  56. serial0 = &uart_AO;
  57. };
  58. chosen {
  59. stdout-path = "serial0:115200n8";
  60. };
  61. memory@0 {
  62. device_type = "memory";
  63. reg = <0x0 0x0 0x0 0x80000000>; /* 2 GiB or 3 GiB */
  64. };
  65. leds {
  66. compatible = "gpio-leds";
  67. blue {
  68. label = "rbox-pro:blue:on";
  69. gpios = <&gpio_ao GPIOAO_9 GPIO_ACTIVE_HIGH>;
  70. default-state = "on";
  71. };
  72. red {
  73. label = "rbox-pro:red:standby";
  74. gpios = <&gpio GPIODV_28 GPIO_ACTIVE_HIGH>;
  75. default-state = "off";
  76. retain-state-suspended;
  77. panic-indicator;
  78. };
  79. };
  80. vddio_boot: regulator-vddio-boot {
  81. compatible = "regulator-fixed";
  82. regulator-name = "VDDIO_BOOT";
  83. regulator-min-microvolt = <1800000>;
  84. regulator-max-microvolt = <1800000>;
  85. };
  86. vddao_3v3: regulator-vddao-3v3 {
  87. compatible = "regulator-fixed";
  88. regulator-name = "VDDAO_3V3";
  89. regulator-min-microvolt = <3300000>;
  90. regulator-max-microvolt = <3300000>;
  91. };
  92. vcc_3v3: regulator-vcc-3v3 {
  93. compatible = "regulator-fixed";
  94. regulator-name = "VCC_3V3";
  95. regulator-min-microvolt = <3300000>;
  96. regulator-max-microvolt = <3300000>;
  97. };
  98. emmc_pwrseq: emmc-pwrseq {
  99. compatible = "mmc-pwrseq-emmc";
  100. reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>;
  101. };
  102. wifi32k: wifi32k {
  103. compatible = "pwm-clock";
  104. #clock-cells = <0>;
  105. clock-frequency = <32768>;
  106. pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */
  107. };
  108. sdio_pwrseq: sdio-pwrseq {
  109. compatible = "mmc-pwrseq-simple";
  110. reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>;
  111. clocks = <&wifi32k>;
  112. clock-names = "ext_clock";
  113. };
  114. };
  115. &ethmac {
  116. status = "okay";
  117. pinctrl-0 = <&eth_pins>;
  118. pinctrl-names = "default";
  119. /* Select external PHY by default */
  120. phy-handle = <&external_phy>;
  121. snps,reset-gpio = <&gpio GPIOZ_14 0>;
  122. snps,reset-delays-us = <0 10000 1000000>;
  123. snps,reset-active-low;
  124. amlogic,tx-delay-ns = <2>;
  125. /* External PHY is in RGMII */
  126. phy-mode = "rgmii";
  127. };
  128. &external_mdio {
  129. external_phy: ethernet-phy@0 {
  130. compatible = "ethernet-phy-id001c.c916", "ethernet-phy-ieee802.3-c22";
  131. reg = <0>;
  132. max-speed = <1000>;
  133. };
  134. };
  135. &ir {
  136. status = "okay";
  137. pinctrl-0 = <&remote_input_ao_pins>;
  138. pinctrl-names = "default";
  139. };
  140. &pwm_ef {
  141. status = "okay";
  142. pinctrl-0 = <&pwm_e_pins>;
  143. pinctrl-names = "default";
  144. clocks = <&clkc CLKID_FCLK_DIV4>;
  145. clock-names = "clkin0";
  146. };
  147. /* Wireless SDIO Module */
  148. &sd_emmc_a {
  149. status = "okay";
  150. pinctrl-0 = <&sdio_pins>;
  151. pinctrl-names = "default";
  152. #address-cells = <1>;
  153. #size-cells = <0>;
  154. bus-width = <4>;
  155. cap-sd-highspeed;
  156. max-frequency = <100000000>;
  157. non-removable;
  158. disable-wp;
  159. mmc-pwrseq = <&sdio_pwrseq>;
  160. vmmc-supply = <&vddao_3v3>;
  161. vqmmc-supply = <&vddio_boot>;
  162. brcmf: brcmf@1 {
  163. reg = <1>;
  164. compatible = "brcm,bcm4329-fmac";
  165. };
  166. };
  167. /* SD card */
  168. &sd_emmc_b {
  169. status = "okay";
  170. pinctrl-0 = <&sdcard_pins>;
  171. pinctrl-names = "default";
  172. bus-width = <4>;
  173. cap-sd-highspeed;
  174. max-frequency = <100000000>;
  175. disable-wp;
  176. cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_HIGH>;
  177. cd-inverted;
  178. vmmc-supply = <&vddao_3v3>;
  179. vqmmc-supply = <&vddio_boot>;
  180. };
  181. /* eMMC */
  182. &sd_emmc_c {
  183. status = "okay";
  184. pinctrl-0 = <&emmc_pins>;
  185. pinctrl-names = "default";
  186. bus-width = <8>;
  187. cap-mmc-highspeed;
  188. max-frequency = <200000000>;
  189. non-removable;
  190. disable-wp;
  191. mmc-ddr-1_8v;
  192. mmc-hs200-1_8v;
  193. mmc-pwrseq = <&emmc_pwrseq>;
  194. vmmc-supply = <&vcc_3v3>;
  195. vqmmc-supply = <&vddio_boot>;
  196. };
  197. &uart_AO {
  198. status = "okay";
  199. pinctrl-0 = <&uart_ao_a_pins>;
  200. pinctrl-names = "default";
  201. };