rk3288-miniarm.dtsi 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521
  1. /*
  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
  5. * whole.
  6. *
  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.
  11. *
  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.
  16. *
  17. * Or, alternatively,
  18. *
  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
  26. * conditions:
  27. *
  28. * The above copyright notice and this permission notice shall be
  29. * included in all copies or substantial portions of the Software.
  30. *
  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.
  39. */
  40. #include "rk3288.dtsi"
  41. / {
  42. memory {
  43. device_type = "memory";
  44. reg = <0x0 0x80000000>;
  45. };
  46. ext_gmac: external-gmac-clock {
  47. compatible = "fixed-clock";
  48. clock-frequency = <125000000>;
  49. clock-output-names = "ext_gmac";
  50. #clock-cells = <0>;
  51. };
  52. gpio-keys {
  53. compatible = "gpio-keys";
  54. #address-cells = <1>;
  55. #size-cells = <0>;
  56. autorepeat;
  57. pinctrl-names = "default";
  58. pinctrl-0 = <&pwrbtn>;
  59. button@0 {
  60. gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
  61. label = "GPIO Key Power";
  62. linux,input-type = <1>;
  63. gpio-key,wakeup = <1>;
  64. debounce-interval = <100>;
  65. };
  66. };
  67. gpio-leds {
  68. compatible = "gpio-leds";
  69. pwr-led {
  70. gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
  71. linux,default-trigger = "default-on";
  72. };
  73. act-led {
  74. gpios=<&gpio2 3 GPIO_ACTIVE_LOW>;
  75. linux,default-trigger="mmc0";
  76. };
  77. };
  78. vcc_sys: vsys-regulator {
  79. compatible = "regulator-fixed";
  80. regulator-name = "vcc_sys";
  81. regulator-min-microvolt = <5000000>;
  82. regulator-max-microvolt = <5000000>;
  83. regulator-always-on;
  84. regulator-boot-on;
  85. };
  86. /*
  87. * NOTE: vcc_sd isn't hooked up on v1.0 boards where power comes from
  88. * vcc_io directly. Those boards won't be able to power cycle SD cards
  89. * but it shouldn't hurt to toggle this pin there anyway.
  90. */
  91. vcc_sd: sdmmc-regulator {
  92. compatible = "regulator-fixed";
  93. gpio = <&gpio7 11 GPIO_ACTIVE_LOW>;
  94. pinctrl-names = "default";
  95. pinctrl-0 = <&sdmmc_pwr>;
  96. regulator-name = "vcc_sd";
  97. regulator-min-microvolt = <3300000>;
  98. regulator-max-microvolt = <3300000>;
  99. startup-delay-us = <100000>;
  100. vin-supply = <&vcc_io>;
  101. };
  102. };
  103. &cpu0 {
  104. cpu0-supply = <&vdd_cpu>;
  105. };
  106. &sdmmc {
  107. bus-width = <4>;
  108. cap-mmc-highspeed;
  109. cap-sd-highspeed;
  110. card-detect-delay = <200>;
  111. disable-wp; /* wp not hooked up */
  112. num-slots = <1>;
  113. pinctrl-names = "default";
  114. pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_cd &sdmmc_bus4>;
  115. status = "okay";
  116. supports-sd;
  117. vmmc-supply = <&vcc_sd>;
  118. vqmmc-supply = <&vccio_sd>;
  119. };
  120. &gpu {
  121. mali-supply = <&vdd_gpu>;
  122. status = "okay";
  123. };
  124. &gmac {
  125. phy-supply = <&vcc33_lan>;
  126. phy-mode = "rgmii";
  127. clock_in_out = "input";
  128. snps,reset-gpio = <&gpio4 7 0>;
  129. snps,reset-active-low;
  130. snps,reset-delays-us = <0 10000 1000000>;
  131. assigned-clocks = <&cru SCLK_MAC>;
  132. assigned-clock-parents = <&ext_gmac>;
  133. pinctrl-names = "default";
  134. pinctrl-0 = <&rgmii_pins>;
  135. tx_delay = <0x30>;
  136. rx_delay = <0x10>;
  137. status = "ok";
  138. };
  139. &hdmi {
  140. ddc-i2c-bus = <&i2c5>;
  141. status = "okay";
  142. };
  143. &i2c0 {
  144. status = "okay";
  145. clock-frequency = <400000>;
  146. rk808: pmic@1b {
  147. compatible = "rockchip,rk808";
  148. reg = <0x1b>;
  149. interrupt-parent = <&gpio0>;
  150. interrupts = <4 IRQ_TYPE_LEVEL_LOW>;
  151. pinctrl-names = "default";
  152. pinctrl-0 = <&pmic_int &global_pwroff>;
  153. rockchip,system-power-controller;
  154. wakeup-source;
  155. #clock-cells = <1>;
  156. clock-output-names = "xin32k", "rk808-clkout2";
  157. vcc1-supply = <&vcc_sys>;
  158. vcc2-supply = <&vcc_sys>;
  159. vcc3-supply = <&vcc_sys>;
  160. vcc4-supply = <&vcc_sys>;
  161. vcc6-supply = <&vcc_sys>;
  162. vcc7-supply = <&vcc_sys>;
  163. vcc8-supply = <&vcc_18>;
  164. vcc9-supply = <&vcc_io>;
  165. vcc10-supply = <&vcc_io>;
  166. vcc11-supply = <&vcc_sys>;
  167. vcc12-supply = <&vcc_io>;
  168. vddio-supply = <&vcc18_ldo1>;
  169. regulators {
  170. vdd_cpu: DCDC_REG1 {
  171. regulator-always-on;
  172. regulator-boot-on;
  173. regulator-min-microvolt = <750000>;
  174. regulator-max-microvolt = <1350000>;
  175. regulator-name = "vdd_arm";
  176. regulator-state-mem {
  177. regulator-off-in-suspend;
  178. };
  179. };
  180. vdd_gpu: DCDC_REG2 {
  181. regulator-always-on;
  182. regulator-boot-on;
  183. regulator-min-microvolt = <850000>;
  184. regulator-max-microvolt = <1250000>;
  185. regulator-name = "vdd_gpu";
  186. regulator-state-mem {
  187. regulator-on-in-suspend;
  188. regulator-suspend-microvolt = <1000000>;
  189. };
  190. };
  191. vcc_ddr: DCDC_REG3 {
  192. regulator-always-on;
  193. regulator-boot-on;
  194. regulator-name = "vcc_ddr";
  195. regulator-state-mem {
  196. regulator-on-in-suspend;
  197. };
  198. };
  199. vcc_io: DCDC_REG4 {
  200. regulator-always-on;
  201. regulator-boot-on;
  202. regulator-min-microvolt = <3300000>;
  203. regulator-max-microvolt = <3300000>;
  204. regulator-name = "vcc_io";
  205. regulator-state-mem {
  206. regulator-on-in-suspend;
  207. regulator-suspend-microvolt = <3300000>;
  208. };
  209. };
  210. vcc18_ldo1: LDO_REG1 {
  211. regulator-always-on;
  212. regulator-boot-on;
  213. regulator-min-microvolt = <1800000>;
  214. regulator-max-microvolt = <1800000>;
  215. regulator-name = "vcc18_ldo1";
  216. regulator-state-mem {
  217. regulator-on-in-suspend;
  218. regulator-suspend-microvolt = <1800000>;
  219. };
  220. };
  221. vcc33_mipi: LDO_REG2 {
  222. regulator-always-on;
  223. regulator-boot-on;
  224. regulator-min-microvolt = <3300000>;
  225. regulator-max-microvolt = <3300000>;
  226. regulator-name = "vcc33_mipi";
  227. regulator-state-mem {
  228. regulator-off-in-suspend;
  229. };
  230. };
  231. vdd_10: LDO_REG3 {
  232. regulator-always-on;
  233. regulator-boot-on;
  234. regulator-min-microvolt = <1000000>;
  235. regulator-max-microvolt = <1000000>;
  236. regulator-name = "vdd_10";
  237. regulator-state-mem {
  238. regulator-on-in-suspend;
  239. regulator-suspend-microvolt = <1000000>;
  240. };
  241. };
  242. vcc18_codec: LDO_REG4 {
  243. regulator-always-on;
  244. regulator-boot-on;
  245. regulator-min-microvolt = <1800000>;
  246. regulator-max-microvolt = <1800000>;
  247. regulator-name = "vcc18_codec";
  248. regulator-state-mem {
  249. regulator-on-in-suspend;
  250. regulator-suspend-microvolt = <1800000>;
  251. };
  252. };
  253. vccio_sd: LDO_REG5 {
  254. regulator-always-on;
  255. regulator-boot-on;
  256. regulator-min-microvolt = <1800000>;
  257. regulator-max-microvolt = <3300000>;
  258. regulator-name = "vccio_sd";
  259. regulator-state-mem {
  260. regulator-on-in-suspend;
  261. regulator-suspend-microvolt = <3300000>;
  262. };
  263. };
  264. vdd10_lcd: LDO_REG6 {
  265. regulator-always-on;
  266. regulator-boot-on;
  267. regulator-min-microvolt = <1000000>;
  268. regulator-max-microvolt = <1000000>;
  269. regulator-name = "vdd10_lcd";
  270. regulator-state-mem {
  271. regulator-on-in-suspend;
  272. regulator-suspend-microvolt = <1000000>;
  273. };
  274. };
  275. vcc_18: LDO_REG7 {
  276. regulator-always-on;
  277. regulator-boot-on;
  278. regulator-min-microvolt = <1800000>;
  279. regulator-max-microvolt = <1800000>;
  280. regulator-name = "vcc_18";
  281. regulator-state-mem {
  282. regulator-on-in-suspend;
  283. regulator-suspend-microvolt = <1800000>;
  284. };
  285. };
  286. vcc18_lcd: LDO_REG8 {
  287. regulator-always-on;
  288. regulator-boot-on;
  289. regulator-min-microvolt = <1800000>;
  290. regulator-max-microvolt = <1800000>;
  291. regulator-name = "vcc18_lcd";
  292. regulator-state-mem {
  293. regulator-on-in-suspend;
  294. regulator-suspend-microvolt = <1800000>;
  295. };
  296. };
  297. vcc33_sd: SWITCH_REG1 {
  298. regulator-always-on;
  299. regulator-boot-on;
  300. regulator-name = "vcc33_sd";
  301. regulator-state-mem {
  302. regulator-on-in-suspend;
  303. };
  304. };
  305. vcc33_lan: SWITCH_REG2 {
  306. regulator-always-on;
  307. regulator-boot-on;
  308. regulator-name = "vcc33_lan";
  309. regulator-state-mem {
  310. regulator-on-in-suspend;
  311. };
  312. };
  313. };
  314. };
  315. };
  316. &i2c2 {
  317. status = "okay";
  318. headset: nau8825@1a {
  319. compatible = "nuvoton,nau8825";
  320. #sound-dai-cells = <0>;
  321. reg = <0x1a>;
  322. interrupt-parent = <&gpio6>;
  323. interrupts = <5 IRQ_TYPE_LEVEL_LOW>;
  324. nuvoton,jkdet-enable = <1>;
  325. nuvoton,jkdet-pull-enable = <1>;
  326. nuvoton,jkdet-pull-up = <0>;
  327. nuvoton,jkdet-polarity = <1>;
  328. nuvoton,vref-impedance = <2>;
  329. nuvoton,micbias-voltage = <6>;
  330. nuvoton,sar-threshold-num = <4>;
  331. nuvoton,sar-threshold = <0xa 0x14 0x26 0x73>;
  332. nuvoton,sar-hysteresis = <0>;
  333. nuvoton,sar-voltage = <6>;
  334. nuvoton,sar-compare-time = <0>;
  335. nuvoton,sar-sampling-time = <0>;
  336. nuvoton,short-key-debounce = <3>;
  337. nuvoton,jack-insert-debounce = <7>;
  338. nuvoton,jack-eject-debounce = <7>;
  339. clock-names = "mclk";
  340. clocks = <&cru SCLK_I2S0_OUT>;
  341. };
  342. };
  343. &i2c5 {
  344. status = "okay";
  345. };
  346. &wdt {
  347. status = "okay";
  348. };
  349. &pwm0 {
  350. status = "okay";
  351. };
  352. &saradc {
  353. vref-supply = <&vcc18_ldo1>;
  354. status ="okay";
  355. };
  356. &uart0 {
  357. status = "okay";
  358. };
  359. &uart1 {
  360. status = "okay";
  361. };
  362. &uart2 {
  363. status = "okay";
  364. };
  365. &uart3 {
  366. status = "okay";
  367. };
  368. &uart4 {
  369. status = "okay";
  370. };
  371. &tsadc {
  372. rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */
  373. rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */
  374. status = "okay";
  375. };
  376. &usbphy {
  377. status = "okay";
  378. };
  379. &usb_host0_ehci {
  380. status = "okay";
  381. };
  382. &usb_host1 {
  383. status = "okay";
  384. };
  385. &usb_otg {
  386. status= "okay";
  387. };
  388. &vopb {
  389. status = "okay";
  390. };
  391. &vopb_mmu {
  392. status = "okay";
  393. };
  394. &vopl {
  395. status = "okay";
  396. };
  397. &vopl_mmu {
  398. status = "okay";
  399. };
  400. &pinctrl {
  401. pcfg_pull_none_drv_8ma: pcfg-pull-none-drv-8ma {
  402. drive-strength = <8>;
  403. };
  404. pcfg_pull_up_drv_8ma: pcfg-pull-up-drv-8ma {
  405. bias-pull-up;
  406. drive-strength = <8>;
  407. };
  408. backlight {
  409. bl_en: bl-en {
  410. rockchip,pins = <7 2 RK_FUNC_GPIO &pcfg_pull_none>;
  411. };
  412. };
  413. buttons {
  414. pwrbtn: pwrbtn {
  415. rockchip,pins = <0 5 RK_FUNC_GPIO &pcfg_pull_up>;
  416. };
  417. };
  418. eth_phy {
  419. eth_phy_pwr: eth-phy-pwr {
  420. rockchip,pins = <0 6 RK_FUNC_GPIO &pcfg_pull_none>;
  421. };
  422. };
  423. pmic {
  424. pmic_int: pmic-int {
  425. rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>;
  426. };
  427. };
  428. sdmmc {
  429. /*
  430. * Default drive strength isn't enough to achieve even
  431. * high-speed mode on EVB board so bump up to 8ma.
  432. */
  433. sdmmc_bus4: sdmmc-bus4 {
  434. rockchip,pins = <6 16 RK_FUNC_1 &pcfg_pull_up_drv_8ma>,
  435. <6 17 RK_FUNC_1 &pcfg_pull_up_drv_8ma>,
  436. <6 18 RK_FUNC_1 &pcfg_pull_up_drv_8ma>,
  437. <6 19 RK_FUNC_1 &pcfg_pull_up_drv_8ma>;
  438. };
  439. sdmmc_clk: sdmmc-clk {
  440. rockchip,pins = <6 20 RK_FUNC_1 &pcfg_pull_none_drv_8ma>;
  441. };
  442. sdmmc_cmd: sdmmc-cmd {
  443. rockchip,pins = <6 21 RK_FUNC_1 &pcfg_pull_up_drv_8ma>;
  444. };
  445. sdmmc_pwr: sdmmc-pwr {
  446. rockchip,pins = <7 11 RK_FUNC_GPIO &pcfg_pull_none>;
  447. };
  448. };
  449. usb {
  450. host_vbus_drv: host-vbus-drv {
  451. rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>;
  452. };
  453. pwr_3g: pwr-3g {
  454. rockchip,pins = <7 8 RK_FUNC_GPIO &pcfg_pull_none>;
  455. };
  456. };
  457. };