sun8i-a33-sinlinx-sina33.dts 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275
  1. /*
  2. * Copyright 2015 Chen-Yu Tsai
  3. *
  4. * Chen-Yu Tsai <[email protected]>
  5. *
  6. * This file is dual-licensed: you can use it either under the terms
  7. * of the GPL or the X11 license, at your option. Note that this dual
  8. * licensing only applies to this file, and not this project as a
  9. * whole.
  10. *
  11. * a) This file is free software; you can redistribute it and/or
  12. * modify it under the terms of the GNU General Public License as
  13. * published by the Free Software Foundation; either version 2 of the
  14. * License, or (at your option) any later version.
  15. *
  16. * This file is distributed in the hope that it will be useful,
  17. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  19. * GNU General Public License for more details.
  20. *
  21. * Or, alternatively,
  22. *
  23. * b) Permission is hereby granted, free of charge, to any person
  24. * obtaining a copy of this software and associated documentation
  25. * files (the "Software"), to deal in the Software without
  26. * restriction, including without limitation the rights to use,
  27. * copy, modify, merge, publish, distribute, sublicense, and/or
  28. * sell copies of the Software, and to permit persons to whom the
  29. * Software is furnished to do so, subject to the following
  30. * conditions:
  31. *
  32. * The above copyright notice and this permission notice shall be
  33. * included in all copies or substantial portions of the Software.
  34. *
  35. * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  36. * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
  37. * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  38. * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
  39. * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
  40. * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  41. * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  42. * OTHER DEALINGS IN THE SOFTWARE.
  43. */
  44. /dts-v1/;
  45. #include "sun8i-a33.dtsi"
  46. #include "sunxi-common-regulators.dtsi"
  47. #include <dt-bindings/gpio/gpio.h>
  48. #include <dt-bindings/input/input.h>
  49. / {
  50. model = "Sinlinx SinA33";
  51. compatible = "sinlinx,sina33", "allwinner,sun8i-a33";
  52. aliases {
  53. serial0 = &uart0;
  54. };
  55. chosen {
  56. stdout-path = "serial0:115200n8";
  57. };
  58. panel {
  59. compatible = "netron-dy,e231732";
  60. power-supply = <&reg_vcc3v3>;
  61. port {
  62. panel_input: endpoint {
  63. remote-endpoint = <&tcon0_out_panel>;
  64. };
  65. };
  66. };
  67. };
  68. &codec {
  69. status = "okay";
  70. };
  71. &cpu0 {
  72. cpu-supply = <&reg_dcdc3>;
  73. };
  74. &cpu0_opp_table {
  75. opp-1104000000 {
  76. opp-hz = /bits/ 64 <1104000000>;
  77. opp-microvolt = <1320000>;
  78. clock-latency-ns = <244144>; /* 8 32k periods */
  79. };
  80. opp-1200000000 {
  81. opp-hz = /bits/ 64 <1200000000>;
  82. opp-microvolt = <1320000>;
  83. clock-latency-ns = <244144>; /* 8 32k periods */
  84. };
  85. };
  86. &de {
  87. status = "okay";
  88. };
  89. &dai {
  90. status = "okay";
  91. };
  92. &ehci0 {
  93. status = "okay";
  94. };
  95. &lradc {
  96. vref-supply = <&reg_dcdc1>;
  97. status = "okay";
  98. button-200 {
  99. label = "Volume Up";
  100. linux,code = <KEY_VOLUMEUP>;
  101. channel = <0>;
  102. voltage = <191011>;
  103. };
  104. button-400 {
  105. label = "Volume Down";
  106. linux,code = <KEY_VOLUMEDOWN>;
  107. channel = <0>;
  108. voltage = <391304>;
  109. };
  110. button-600 {
  111. label = "Home";
  112. linux,code = <KEY_HOME>;
  113. channel = <0>;
  114. voltage = <600000>;
  115. };
  116. };
  117. &mmc0 {
  118. vmmc-supply = <&reg_dcdc1>;
  119. bus-width = <4>;
  120. cd-gpios = <&pio 1 4 GPIO_ACTIVE_LOW>; /* PB4 */
  121. status = "okay";
  122. };
  123. &mmc2 {
  124. pinctrl-names = "default";
  125. pinctrl-0 = <&mmc2_8bit_pins>;
  126. vmmc-supply = <&reg_dcdc1>;
  127. bus-width = <8>;
  128. non-removable;
  129. cap-mmc-hw-reset;
  130. status = "okay";
  131. };
  132. &mmc2_8bit_pins {
  133. /* Increase drive strength for DDR modes */
  134. drive-strength = <40>;
  135. };
  136. &ohci0 {
  137. status = "okay";
  138. };
  139. &r_rsb {
  140. status = "okay";
  141. axp22x: pmic@3a3 {
  142. compatible = "x-powers,axp223";
  143. reg = <0x3a3>;
  144. interrupt-parent = <&r_intc>;
  145. interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_LOW>;
  146. eldoin-supply = <&reg_dcdc1>;
  147. };
  148. };
  149. #include "axp223.dtsi"
  150. &ac_power_supply {
  151. status = "okay";
  152. };
  153. &battery_power_supply {
  154. status = "okay";
  155. };
  156. &reg_aldo1 {
  157. regulator-always-on;
  158. regulator-min-microvolt = <3000000>;
  159. regulator-max-microvolt = <3000000>;
  160. regulator-name = "vcc-io";
  161. };
  162. &reg_aldo2 {
  163. regulator-always-on;
  164. regulator-min-microvolt = <2350000>;
  165. regulator-max-microvolt = <2650000>;
  166. regulator-name = "vdd-dll";
  167. };
  168. &reg_aldo3 {
  169. regulator-always-on;
  170. regulator-min-microvolt = <2700000>;
  171. regulator-max-microvolt = <3300000>;
  172. regulator-name = "vcc-pll-avcc";
  173. };
  174. &reg_dc5ldo {
  175. regulator-always-on;
  176. regulator-min-microvolt = <900000>;
  177. regulator-max-microvolt = <1400000>;
  178. regulator-name = "vdd-cpus";
  179. };
  180. &reg_dcdc1 {
  181. regulator-always-on;
  182. regulator-min-microvolt = <3000000>;
  183. regulator-max-microvolt = <3000000>;
  184. regulator-name = "vcc-3v0";
  185. };
  186. &reg_dcdc2 {
  187. regulator-always-on;
  188. regulator-min-microvolt = <900000>;
  189. regulator-max-microvolt = <1400000>;
  190. regulator-name = "vdd-sys";
  191. };
  192. &reg_dcdc3 {
  193. regulator-always-on;
  194. regulator-min-microvolt = <900000>;
  195. regulator-max-microvolt = <1400000>;
  196. regulator-name = "vdd-cpu";
  197. };
  198. &reg_dcdc5 {
  199. regulator-always-on;
  200. regulator-min-microvolt = <1500000>;
  201. regulator-max-microvolt = <1500000>;
  202. regulator-name = "vcc-dram";
  203. };
  204. &reg_rtc_ldo {
  205. regulator-name = "vcc-rtc";
  206. };
  207. &sound {
  208. status = "okay";
  209. };
  210. &tcon0 {
  211. pinctrl-names = "default";
  212. pinctrl-0 = <&lcd_rgb666_pins>;
  213. status = "okay";
  214. };
  215. &tcon0_out {
  216. tcon0_out_panel: endpoint@0 {
  217. reg = <0>;
  218. remote-endpoint = <&panel_input>;
  219. };
  220. };
  221. &uart0 {
  222. pinctrl-names = "default";
  223. pinctrl-0 = <&uart0_pb_pins>;
  224. status = "okay";
  225. };
  226. &usb_otg {
  227. dr_mode = "peripheral";
  228. status = "okay";
  229. };
  230. &usbphy {
  231. status = "okay";
  232. usb1_vbus-supply = <&reg_vcc5v0>; /* USB1 VBUS is always on */
  233. };