imx8mm-venice-gw73xx.dtsi 10.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443
  1. // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
  2. /*
  3. * Copyright 2020 Gateworks Corporation
  4. */
  5. #include <dt-bindings/gpio/gpio.h>
  6. #include <dt-bindings/leds/common.h>
  7. #include <dt-bindings/phy/phy-imx8-pcie.h>
  8. / {
  9. aliases {
  10. ethernet1 = &eth1;
  11. usb0 = &usbotg1;
  12. usb1 = &usbotg2;
  13. };
  14. led-controller {
  15. compatible = "gpio-leds";
  16. pinctrl-names = "default";
  17. pinctrl-0 = <&pinctrl_gpio_leds>;
  18. led-0 {
  19. function = LED_FUNCTION_STATUS;
  20. color = <LED_COLOR_ID_GREEN>;
  21. gpios = <&gpio5 5 GPIO_ACTIVE_HIGH>;
  22. default-state = "on";
  23. linux,default-trigger = "heartbeat";
  24. };
  25. led-1 {
  26. function = LED_FUNCTION_STATUS;
  27. color = <LED_COLOR_ID_RED>;
  28. gpios = <&gpio5 4 GPIO_ACTIVE_HIGH>;
  29. default-state = "off";
  30. };
  31. };
  32. pcie0_refclk: pcie0-refclk {
  33. compatible = "fixed-clock";
  34. #clock-cells = <0>;
  35. clock-frequency = <100000000>;
  36. };
  37. pps {
  38. compatible = "pps-gpio";
  39. pinctrl-names = "default";
  40. pinctrl-0 = <&pinctrl_pps>;
  41. gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
  42. status = "okay";
  43. };
  44. reg_1p8v: regulator-1p8v {
  45. compatible = "regulator-fixed";
  46. regulator-name = "1P8V";
  47. regulator-min-microvolt = <1800000>;
  48. regulator-max-microvolt = <1800000>;
  49. regulator-always-on;
  50. };
  51. reg_3p3v: regulator-3p3v {
  52. compatible = "regulator-fixed";
  53. regulator-name = "3P3V";
  54. regulator-min-microvolt = <3300000>;
  55. regulator-max-microvolt = <3300000>;
  56. regulator-always-on;
  57. };
  58. reg_usb_otg1_vbus: regulator-usb-otg1 {
  59. pinctrl-names = "default";
  60. pinctrl-0 = <&pinctrl_reg_usb1_en>;
  61. compatible = "regulator-fixed";
  62. regulator-name = "usb_otg1_vbus";
  63. gpio = <&gpio1 12 GPIO_ACTIVE_HIGH>;
  64. enable-active-high;
  65. regulator-min-microvolt = <5000000>;
  66. regulator-max-microvolt = <5000000>;
  67. };
  68. reg_usb_otg2_vbus: regulator-usb-otg2 {
  69. pinctrl-names = "default";
  70. pinctrl-0 = <&pinctrl_reg_usb2_en>;
  71. compatible = "regulator-fixed";
  72. regulator-name = "usb_otg2_vbus";
  73. gpio = <&gpio1 8 GPIO_ACTIVE_HIGH>;
  74. enable-active-high;
  75. regulator-min-microvolt = <5000000>;
  76. regulator-max-microvolt = <5000000>;
  77. };
  78. reg_wifi_en: regulator-wifi-en {
  79. pinctrl-names = "default";
  80. pinctrl-0 = <&pinctrl_reg_wl>;
  81. compatible = "regulator-fixed";
  82. regulator-name = "wl";
  83. gpio = <&gpio1 5 GPIO_ACTIVE_HIGH>;
  84. startup-delay-us = <100>;
  85. enable-active-high;
  86. regulator-min-microvolt = <3300000>;
  87. regulator-max-microvolt = <3300000>;
  88. };
  89. };
  90. /* off-board header */
  91. &ecspi2 {
  92. pinctrl-names = "default";
  93. pinctrl-0 = <&pinctrl_spi2>;
  94. cs-gpios = <&gpio5 13 GPIO_ACTIVE_LOW>;
  95. status = "okay";
  96. };
  97. &gpio1 {
  98. gpio-line-names = "rs485_term", "mipi_gpio4", "", "",
  99. "", "", "pci_usb_sel", "dio0",
  100. "", "dio1", "", "", "", "", "", "",
  101. "", "", "", "", "", "", "", "",
  102. "", "", "", "", "", "", "", "";
  103. };
  104. &gpio4 {
  105. gpio-line-names = "rs485_en", "mipi_gpio3", "rs485_hd", "mipi_gpio2",
  106. "mipi_gpio1", "", "", "pci_wdis#",
  107. "", "", "", "", "", "", "", "",
  108. "", "", "", "", "", "", "", "",
  109. "", "", "", "", "", "", "", "";
  110. };
  111. &i2c2 {
  112. clock-frequency = <400000>;
  113. pinctrl-names = "default";
  114. pinctrl-0 = <&pinctrl_i2c2>;
  115. status = "okay";
  116. accelerometer@19 {
  117. pinctrl-names = "default";
  118. pinctrl-0 = <&pinctrl_accel>;
  119. compatible = "st,lis2de12";
  120. reg = <0x19>;
  121. st,drdy-int-pin = <1>;
  122. interrupt-parent = <&gpio4>;
  123. interrupts = <5 IRQ_TYPE_LEVEL_LOW>;
  124. interrupt-names = "INT1";
  125. };
  126. };
  127. /* off-board header */
  128. &i2c3 {
  129. clock-frequency = <400000>;
  130. pinctrl-names = "default";
  131. pinctrl-0 = <&pinctrl_i2c3>;
  132. status = "okay";
  133. };
  134. &pcie_phy {
  135. fsl,refclk-pad-mode = <IMX8_PCIE_REFCLK_PAD_INPUT>;
  136. fsl,clkreq-unsupported;
  137. clocks = <&pcie0_refclk>;
  138. clock-names = "ref";
  139. status = "okay";
  140. };
  141. &pcie0 {
  142. pinctrl-names = "default";
  143. pinctrl-0 = <&pinctrl_pcie0>;
  144. reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
  145. clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
  146. <&pcie0_refclk>;
  147. clock-names = "pcie", "pcie_aux", "pcie_bus";
  148. assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
  149. <&clk IMX8MM_CLK_PCIE1_CTRL>;
  150. assigned-clock-rates = <10000000>, <250000000>;
  151. assigned-clock-parents = <&clk IMX8MM_SYS_PLL2_50M>,
  152. <&clk IMX8MM_SYS_PLL2_250M>;
  153. status = "okay";
  154. pcie@0,0 {
  155. reg = <0x0000 0 0 0 0>;
  156. #address-cells = <1>;
  157. #size-cells = <0>;
  158. pcie@1,0 {
  159. reg = <0x0000 0 0 0 0>;
  160. #address-cells = <1>;
  161. #size-cells = <0>;
  162. pcie@2,4 {
  163. reg = <0x2000 0 0 0 0>;
  164. #address-cells = <1>;
  165. #size-cells = <0>;
  166. eth1: pcie@6,0 {
  167. reg = <0x0000 0 0 0 0>;
  168. #address-cells = <1>;
  169. #size-cells = <0>;
  170. local-mac-address = [00 00 00 00 00 00];
  171. };
  172. };
  173. };
  174. };
  175. };
  176. /* off-board header */
  177. &sai3 {
  178. pinctrl-names = "default";
  179. pinctrl-0 = <&pinctrl_sai3>;
  180. assigned-clocks = <&clk IMX8MM_CLK_SAI3>;
  181. assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL1_OUT>;
  182. assigned-clock-rates = <24576000>;
  183. status = "okay";
  184. };
  185. /* GPS */
  186. &uart1 {
  187. pinctrl-names = "default";
  188. pinctrl-0 = <&pinctrl_uart1>;
  189. status = "okay";
  190. };
  191. /* bluetooth HCI */
  192. &uart3 {
  193. pinctrl-names = "default";
  194. pinctrl-0 = <&pinctrl_uart3>, <&pinctrl_bten>;
  195. cts-gpios = <&gpio5 8 GPIO_ACTIVE_LOW>;
  196. rts-gpios = <&gpio5 9 GPIO_ACTIVE_LOW>;
  197. status = "okay";
  198. bluetooth {
  199. compatible = "brcm,bcm4330-bt";
  200. shutdown-gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
  201. };
  202. };
  203. /* RS232 */
  204. &uart4 {
  205. pinctrl-names = "default";
  206. pinctrl-0 = <&pinctrl_uart4>;
  207. status = "okay";
  208. };
  209. &usbotg1 {
  210. dr_mode = "otg";
  211. over-current-active-low;
  212. vbus-supply = <&reg_usb_otg1_vbus>;
  213. status = "okay";
  214. };
  215. &usbotg2 {
  216. dr_mode = "host";
  217. disable-over-current;
  218. vbus-supply = <&reg_usb_otg2_vbus>;
  219. status = "okay";
  220. };
  221. /* SDIO WiFi */
  222. &usdhc1 {
  223. pinctrl-names = "default";
  224. pinctrl-0 = <&pinctrl_usdhc1>;
  225. bus-width = <4>;
  226. non-removable;
  227. vmmc-supply = <&reg_wifi_en>;
  228. status = "okay";
  229. };
  230. /* microSD */
  231. &usdhc2 {
  232. pinctrl-names = "default", "state_100mhz", "state_200mhz";
  233. pinctrl-0 = <&pinctrl_usdhc2>, <&pinctrl_usdhc2_gpio>;
  234. pinctrl-1 = <&pinctrl_usdhc2_100mhz>, <&pinctrl_usdhc2_gpio>;
  235. pinctrl-2 = <&pinctrl_usdhc2_200mhz>, <&pinctrl_usdhc2_gpio>;
  236. cd-gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
  237. bus-width = <4>;
  238. vmmc-supply = <&reg_3p3v>;
  239. status = "okay";
  240. };
  241. &iomuxc {
  242. pinctrl-names = "default";
  243. pinctrl-0 = <&pinctrl_hog>;
  244. pinctrl_hog: hoggrp {
  245. fsl,pins = <
  246. MX8MM_IOMUXC_SPDIF_TX_GPIO5_IO3 0x40000041 /* PLUG_TEST */
  247. MX8MM_IOMUXC_GPIO1_IO06_GPIO1_IO6 0x40000041 /* PCI_USBSEL */
  248. MX8MM_IOMUXC_SAI1_RXD5_GPIO4_IO7 0x40000041 /* PCIE_WDIS# */
  249. MX8MM_IOMUXC_GPIO1_IO07_GPIO1_IO7 0x40000041 /* DIO0 */
  250. MX8MM_IOMUXC_GPIO1_IO09_GPIO1_IO9 0x40000041 /* DIO1 */
  251. MX8MM_IOMUXC_GPIO1_IO00_GPIO1_IO0 0x40000104 /* RS485_TERM */
  252. MX8MM_IOMUXC_SAI1_RXFS_GPIO4_IO0 0x40000104 /* RS485 */
  253. MX8MM_IOMUXC_SAI1_RXD0_GPIO4_IO2 0x40000104 /* RS485_HALF */
  254. >;
  255. };
  256. pinctrl_accel: accelgrp {
  257. fsl,pins = <
  258. MX8MM_IOMUXC_SAI1_RXD3_GPIO4_IO5 0x159
  259. >;
  260. };
  261. pinctrl_bten: btengrp {
  262. fsl,pins = <
  263. MX8MM_IOMUXC_GPIO1_IO03_GPIO1_IO3 0x41
  264. >;
  265. };
  266. pinctrl_gpio_leds: gpioledgrp {
  267. fsl,pins = <
  268. MX8MM_IOMUXC_SPDIF_EXT_CLK_GPIO5_IO5 0x19
  269. MX8MM_IOMUXC_SPDIF_RX_GPIO5_IO4 0x19
  270. >;
  271. };
  272. pinctrl_i2c3: i2c3grp {
  273. fsl,pins = <
  274. MX8MM_IOMUXC_I2C3_SCL_I2C3_SCL 0x400001c3
  275. MX8MM_IOMUXC_I2C3_SDA_I2C3_SDA 0x400001c3
  276. >;
  277. };
  278. pinctrl_pcie0: pcie0grp {
  279. fsl,pins = <
  280. MX8MM_IOMUXC_SAI1_RXD4_GPIO4_IO6 0x41
  281. >;
  282. };
  283. pinctrl_pps: ppsgrp {
  284. fsl,pins = <
  285. MX8MM_IOMUXC_GPIO1_IO15_GPIO1_IO15 0x41
  286. >;
  287. };
  288. pinctrl_reg_wl: regwlgrp {
  289. fsl,pins = <
  290. MX8MM_IOMUXC_GPIO1_IO05_GPIO1_IO5 0x41
  291. >;
  292. };
  293. pinctrl_reg_usb1_en: regusb1grp {
  294. fsl,pins = <
  295. MX8MM_IOMUXC_GPIO1_IO12_GPIO1_IO12 0x41
  296. MX8MM_IOMUXC_GPIO1_IO13_USB1_OTG_OC 0x41
  297. >;
  298. };
  299. pinctrl_reg_usb2_en: regusb2grp {
  300. fsl,pins = <
  301. MX8MM_IOMUXC_GPIO1_IO08_GPIO1_IO8 0x41
  302. >;
  303. };
  304. pinctrl_sai3: sai3grp {
  305. fsl,pins = <
  306. MX8MM_IOMUXC_SAI3_TXFS_SAI3_TX_SYNC 0xd6
  307. MX8MM_IOMUXC_SAI3_TXC_SAI3_TX_BCLK 0xd6
  308. MX8MM_IOMUXC_SAI3_MCLK_SAI3_MCLK 0xd6
  309. MX8MM_IOMUXC_SAI3_TXD_SAI3_TX_DATA0 0xd6
  310. MX8MM_IOMUXC_SAI3_RXD_SAI3_RX_DATA0 0xd6
  311. >;
  312. };
  313. pinctrl_spi2: spi2grp {
  314. fsl,pins = <
  315. MX8MM_IOMUXC_ECSPI2_SCLK_ECSPI2_SCLK 0xd6
  316. MX8MM_IOMUXC_ECSPI2_MOSI_ECSPI2_MOSI 0xd6
  317. MX8MM_IOMUXC_ECSPI2_MISO_ECSPI2_MISO 0xd6
  318. MX8MM_IOMUXC_ECSPI2_SS0_GPIO5_IO13 0xd6
  319. >;
  320. };
  321. pinctrl_uart1: uart1grp {
  322. fsl,pins = <
  323. MX8MM_IOMUXC_UART1_RXD_UART1_DCE_RX 0x140
  324. MX8MM_IOMUXC_UART1_TXD_UART1_DCE_TX 0x140
  325. >;
  326. };
  327. pinctrl_uart3: uart3grp {
  328. fsl,pins = <
  329. MX8MM_IOMUXC_UART3_RXD_UART3_DCE_RX 0x140
  330. MX8MM_IOMUXC_UART3_TXD_UART3_DCE_TX 0x140
  331. MX8MM_IOMUXC_ECSPI1_MISO_GPIO5_IO8 0x140
  332. MX8MM_IOMUXC_ECSPI1_SS0_GPIO5_IO9 0x140
  333. >;
  334. };
  335. pinctrl_uart4: uart4grp {
  336. fsl,pins = <
  337. MX8MM_IOMUXC_UART4_RXD_UART4_DCE_RX 0x140
  338. MX8MM_IOMUXC_UART4_TXD_UART4_DCE_TX 0x140
  339. >;
  340. };
  341. pinctrl_usdhc1: usdhc1grp {
  342. fsl,pins = <
  343. MX8MM_IOMUXC_SD1_CLK_USDHC1_CLK 0x190
  344. MX8MM_IOMUXC_SD1_CMD_USDHC1_CMD 0x1d0
  345. MX8MM_IOMUXC_SD1_DATA0_USDHC1_DATA0 0x1d0
  346. MX8MM_IOMUXC_SD1_DATA1_USDHC1_DATA1 0x1d0
  347. MX8MM_IOMUXC_SD1_DATA2_USDHC1_DATA2 0x1d0
  348. MX8MM_IOMUXC_SD1_DATA3_USDHC1_DATA3 0x1d0
  349. >;
  350. };
  351. pinctrl_usdhc2: usdhc2grp {
  352. fsl,pins = <
  353. MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x190
  354. MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x1d0
  355. MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x1d0
  356. MX8MM_IOMUXC_SD2_DATA1_USDHC2_DATA1 0x1d0
  357. MX8MM_IOMUXC_SD2_DATA2_USDHC2_DATA2 0x1d0
  358. MX8MM_IOMUXC_SD2_DATA3_USDHC2_DATA3 0x1d0
  359. >;
  360. };
  361. pinctrl_usdhc2_100mhz: usdhc2-100mhzgrp {
  362. fsl,pins = <
  363. MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x194
  364. MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x1d4
  365. MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x1d4
  366. MX8MM_IOMUXC_SD2_DATA1_USDHC2_DATA1 0x1d4
  367. MX8MM_IOMUXC_SD2_DATA2_USDHC2_DATA2 0x1d4
  368. MX8MM_IOMUXC_SD2_DATA3_USDHC2_DATA3 0x1d4
  369. >;
  370. };
  371. pinctrl_usdhc2_200mhz: usdhc2-200mhzgrp {
  372. fsl,pins = <
  373. MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x196
  374. MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x1d6
  375. MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x1d6
  376. MX8MM_IOMUXC_SD2_DATA1_USDHC2_DATA1 0x1d6
  377. MX8MM_IOMUXC_SD2_DATA2_USDHC2_DATA2 0x1d6
  378. MX8MM_IOMUXC_SD2_DATA3_USDHC2_DATA3 0x1d6
  379. >;
  380. };
  381. pinctrl_usdhc2_gpio: usdhc2gpiogrp {
  382. fsl,pins = <
  383. MX8MM_IOMUXC_SD2_CD_B_GPIO2_IO12 0x1c4
  384. MX8MM_IOMUXC_SD2_RESET_B_USDHC2_RESET_B 0x1d0
  385. MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x1d0
  386. >;
  387. };
  388. };