r8a7745-iwg22d-sodimm.dts 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329
  1. // SPDX-License-Identifier: GPL-2.0
  2. /*
  3. * Device Tree Source for the iWave-RZG1E SODIMM carrier board
  4. *
  5. * Copyright (C) 2017 Renesas Electronics Corp.
  6. */
  7. /*
  8. * SSI-SGTL5000
  9. *
  10. * This command is required when Playback/Capture
  11. *
  12. * amixer set "DVC Out" 100%
  13. * amixer set "DVC In" 100%
  14. *
  15. * You can use Mute
  16. *
  17. * amixer set "DVC Out Mute" on
  18. * amixer set "DVC In Mute" on
  19. *
  20. * You can use Volume Ramp
  21. *
  22. * amixer set "DVC Out Ramp Up Rate" "0.125 dB/64 steps"
  23. * amixer set "DVC Out Ramp Down Rate" "0.125 dB/512 steps"
  24. * amixer set "DVC Out Ramp" on
  25. * aplay xxx.wav &
  26. * amixer set "DVC Out" 80% // Volume Down
  27. * amixer set "DVC Out" 100% // Volume Up
  28. */
  29. /dts-v1/;
  30. #include "r8a7745-iwg22m.dtsi"
  31. #include <dt-bindings/pwm/pwm.h>
  32. / {
  33. model = "iWave Systems RainboW-G22D-SODIMM board based on RZ/G1E";
  34. compatible = "iwave,g22d", "iwave,g22m", "renesas,r8a7745";
  35. aliases {
  36. ethernet0 = &avb;
  37. serial3 = &scif4;
  38. serial5 = &hscif1;
  39. };
  40. chosen {
  41. bootargs = "ignore_loglevel rw root=/dev/nfs ip=on";
  42. stdout-path = "serial3:115200n8";
  43. };
  44. audio_clock: audio_clock {
  45. compatible = "fixed-clock";
  46. #clock-cells = <0>;
  47. clock-frequency = <26000000>;
  48. };
  49. backlight_lcd: backlight {
  50. compatible = "pwm-backlight";
  51. pwms = <&tpu 3 5000000 PWM_POLARITY_INVERTED>;
  52. brightness-levels = <0 4 8 16 32 64 128 255>;
  53. default-brightness-level = <7>;
  54. };
  55. lcd_panel: lcd {
  56. compatible = "edt,etm043080dh6gp";
  57. power-supply = <&vccq_panel>;
  58. backlight = <&backlight_lcd>;
  59. port {
  60. lcd_in: endpoint {
  61. remote-endpoint = <&du_out_rgb0>;
  62. };
  63. };
  64. };
  65. vccq_panel: regulator-vccq-panel {
  66. compatible = "regulator-fixed";
  67. regulator-name = "Panel VccQ";
  68. regulator-min-microvolt = <3300000>;
  69. regulator-max-microvolt = <3300000>;
  70. gpio = <&gpio1 13 GPIO_ACTIVE_LOW>;
  71. enable-active-high;
  72. };
  73. vccq_sdhi0: regulator-vccq-sdhi0 {
  74. compatible = "regulator-gpio";
  75. regulator-name = "SDHI0 VccQ";
  76. regulator-min-microvolt = <1800000>;
  77. regulator-max-microvolt = <3300000>;
  78. gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
  79. gpios-states = <1>;
  80. states = <3300000 1>, <1800000 0>;
  81. };
  82. rsnd_sgtl5000: sound {
  83. compatible = "simple-audio-card";
  84. simple-audio-card,format = "i2s";
  85. simple-audio-card,bitclock-master = <&sndcodec>;
  86. simple-audio-card,frame-master = <&sndcodec>;
  87. sndcpu: simple-audio-card,cpu {
  88. sound-dai = <&rcar_sound>;
  89. };
  90. sndcodec: simple-audio-card,codec {
  91. sound-dai = <&sgtl5000>;
  92. };
  93. };
  94. };
  95. &avb {
  96. pinctrl-0 = <&avb_pins>;
  97. pinctrl-names = "default";
  98. phy-handle = <&phy3>;
  99. phy-mode = "gmii";
  100. renesas,no-ether-link;
  101. status = "okay";
  102. phy3: ethernet-phy@3 {
  103. /*
  104. * On some older versions of the platform (before R4.0) the phy address
  105. * may be 1 or 3. The address is fixed to 3 for R4.0 onwards.
  106. */
  107. compatible = "ethernet-phy-id0022.1622",
  108. "ethernet-phy-ieee802.3-c22";
  109. reg = <3>;
  110. micrel,led-mode = <1>;
  111. };
  112. };
  113. &can0 {
  114. pinctrl-0 = <&can0_pins>;
  115. pinctrl-names = "default";
  116. status = "okay";
  117. };
  118. &du {
  119. pinctrl-0 = <&du0_pins>;
  120. pinctrl-names = "default";
  121. status = "okay";
  122. ports {
  123. port@0 {
  124. endpoint {
  125. remote-endpoint = <&lcd_in>;
  126. };
  127. };
  128. };
  129. };
  130. &hscif1 {
  131. pinctrl-0 = <&hscif1_pins>;
  132. pinctrl-names = "default";
  133. uart-has-rtscts;
  134. status = "okay";
  135. };
  136. &hsusb {
  137. status = "okay";
  138. pinctrl-0 = <&usb0_pins>;
  139. pinctrl-names = "default";
  140. };
  141. &i2c5 {
  142. pinctrl-0 = <&i2c5_pins>;
  143. pinctrl-names = "default";
  144. status = "okay";
  145. clock-frequency = <400000>;
  146. sgtl5000: codec@a {
  147. compatible = "fsl,sgtl5000";
  148. #sound-dai-cells = <0>;
  149. reg = <0x0a>;
  150. clocks = <&audio_clock>;
  151. VDDA-supply = <&reg_3p3v>;
  152. VDDIO-supply = <&reg_3p3v>;
  153. };
  154. stmpe811@44 {
  155. compatible = "st,stmpe811";
  156. reg = <0x44>;
  157. interrupt-parent = <&gpio4>;
  158. interrupts = <4 IRQ_TYPE_LEVEL_LOW>;
  159. /* 3.25 MHz ADC clock speed */
  160. st,adc-freq = <1>;
  161. /* ADC conversion time: 80 clocks */
  162. st,sample-time = <4>;
  163. /* 12-bit ADC */
  164. st,mod-12b = <1>;
  165. /* internal ADC reference */
  166. st,ref-sel = <0>;
  167. stmpe_touchscreen {
  168. compatible = "st,stmpe-ts";
  169. /* 8 sample average control */
  170. st,ave-ctrl = <3>;
  171. /* 7 length fractional part in z */
  172. st,fraction-z = <7>;
  173. /*
  174. * 50 mA typical 80 mA max touchscreen drivers
  175. * current limit value
  176. */
  177. st,i-drive = <1>;
  178. /* 1 ms panel driver settling time */
  179. st,settling = <3>;
  180. /* 5 ms touch detect interrupt delay */
  181. st,touch-det-delay = <5>;
  182. };
  183. };
  184. };
  185. &pci1 {
  186. status = "okay";
  187. pinctrl-0 = <&usb1_pins>;
  188. pinctrl-names = "default";
  189. };
  190. &pfc {
  191. avb_pins: avb {
  192. groups = "avb_mdio", "avb_gmii";
  193. function = "avb";
  194. };
  195. backlight_pins: backlight {
  196. groups = "tpu_to3_c";
  197. function = "tpu";
  198. };
  199. can0_pins: can0 {
  200. groups = "can0_data";
  201. function = "can0";
  202. };
  203. du0_pins: du0 {
  204. groups = "du0_rgb666", "du0_sync", "du0_disp", "du0_clk0_out";
  205. function = "du0";
  206. };
  207. hscif1_pins: hscif1 {
  208. groups = "hscif1_data", "hscif1_ctrl";
  209. function = "hscif1";
  210. };
  211. i2c5_pins: i2c5 {
  212. groups = "i2c5_b";
  213. function = "i2c5";
  214. };
  215. scif4_pins: scif4 {
  216. groups = "scif4_data_b";
  217. function = "scif4";
  218. };
  219. sdhi0_pins: sd0 {
  220. groups = "sdhi0_data4", "sdhi0_ctrl";
  221. function = "sdhi0";
  222. power-source = <3300>;
  223. };
  224. sound_pins: sound {
  225. groups = "ssi34_ctrl", "ssi3_data", "ssi4_data";
  226. function = "ssi";
  227. };
  228. usb0_pins: usb0 {
  229. groups = "usb0";
  230. function = "usb0";
  231. };
  232. usb1_pins: usb1 {
  233. groups = "usb1";
  234. function = "usb1";
  235. };
  236. };
  237. &rcar_sound {
  238. pinctrl-0 = <&sound_pins>;
  239. pinctrl-names = "default";
  240. status = "okay";
  241. /* Single DAI */
  242. #sound-dai-cells = <0>;
  243. rcar_sound,dai {
  244. dai0 {
  245. playback = <&ssi3>, <&src3>, <&dvc0>;
  246. capture = <&ssi4>, <&src4>, <&dvc1>;
  247. };
  248. };
  249. };
  250. &scif4 {
  251. pinctrl-0 = <&scif4_pins>;
  252. pinctrl-names = "default";
  253. status = "okay";
  254. };
  255. &sdhi0 {
  256. pinctrl-0 = <&sdhi0_pins>;
  257. pinctrl-names = "default";
  258. vmmc-supply = <&reg_3p3v>;
  259. vqmmc-supply = <&vccq_sdhi0>;
  260. cd-gpios = <&gpio6 6 GPIO_ACTIVE_LOW>;
  261. status = "okay";
  262. };
  263. &ssi4 {
  264. shared-pin;
  265. };
  266. &tpu {
  267. pinctrl-0 = <&backlight_pins>;
  268. pinctrl-names = "default";
  269. status = "okay";
  270. };
  271. &usbphy {
  272. status = "okay";
  273. };