dra72-evm-common.dtsi 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593
  1. // SPDX-License-Identifier: GPL-2.0-only
  2. /*
  3. * Copyright (C) 2014-2016 Texas Instruments Incorporated - https://www.ti.com/
  4. */
  5. /dts-v1/;
  6. #include "dra72x.dtsi"
  7. #include "dra7-ipu-dsp-common.dtsi"
  8. #include <dt-bindings/gpio/gpio.h>
  9. #include <dt-bindings/clock/ti-dra7-atl.h>
  10. / {
  11. compatible = "ti,dra72-evm", "ti,dra722", "ti,dra72", "ti,dra7";
  12. aliases {
  13. display0 = &hdmi0;
  14. };
  15. chosen {
  16. stdout-path = &uart1;
  17. };
  18. evm_12v0: fixedregulator-evm12v0 {
  19. /* main supply */
  20. compatible = "regulator-fixed";
  21. regulator-name = "evm_12v0";
  22. regulator-min-microvolt = <12000000>;
  23. regulator-max-microvolt = <12000000>;
  24. regulator-always-on;
  25. regulator-boot-on;
  26. };
  27. evm_5v0: fixedregulator-evm5v0 {
  28. /* Output 1 of TPS43351QDAPRQ1 on dra72-evm */
  29. /* Output 1 of LM5140QRWGTQ1 on dra71-evm */
  30. compatible = "regulator-fixed";
  31. regulator-name = "evm_5v0";
  32. regulator-min-microvolt = <5000000>;
  33. regulator-max-microvolt = <5000000>;
  34. vin-supply = <&evm_12v0>;
  35. regulator-always-on;
  36. regulator-boot-on;
  37. };
  38. evm_3v6: fixedregulator-evm_3v6 {
  39. compatible = "regulator-fixed";
  40. regulator-name = "evm_3v6";
  41. regulator-min-microvolt = <3600000>;
  42. regulator-max-microvolt = <3600000>;
  43. vin-supply = <&evm_5v0>;
  44. regulator-always-on;
  45. regulator-boot-on;
  46. };
  47. vsys_3v3: fixedregulator-vsys3v3 {
  48. /* Output 2 of TPS43351QDAPRQ1 on dra72-evm */
  49. /* Output 2 of LM5140QRWGTQ1 on dra71-evm */
  50. compatible = "regulator-fixed";
  51. regulator-name = "vsys_3v3";
  52. regulator-min-microvolt = <3300000>;
  53. regulator-max-microvolt = <3300000>;
  54. vin-supply = <&evm_12v0>;
  55. regulator-always-on;
  56. regulator-boot-on;
  57. };
  58. evm_3v3_sw: fixedregulator-evm_3v3 {
  59. /* TPS22965DSG */
  60. compatible = "regulator-fixed";
  61. regulator-name = "evm_3v3";
  62. regulator-min-microvolt = <3300000>;
  63. regulator-max-microvolt = <3300000>;
  64. vin-supply = <&vsys_3v3>;
  65. regulator-always-on;
  66. regulator-boot-on;
  67. };
  68. aic_dvdd: fixedregulator-aic_dvdd {
  69. /* TPS77018DBVT */
  70. compatible = "regulator-fixed";
  71. regulator-name = "aic_dvdd";
  72. vin-supply = <&evm_3v3_sw>;
  73. regulator-min-microvolt = <1800000>;
  74. regulator-max-microvolt = <1800000>;
  75. };
  76. evm_3v3_sd: fixedregulator-sd {
  77. compatible = "regulator-fixed";
  78. regulator-name = "evm_3v3_sd";
  79. regulator-min-microvolt = <3300000>;
  80. regulator-max-microvolt = <3300000>;
  81. vin-supply = <&evm_3v3_sw>;
  82. enable-active-high;
  83. gpio = <&pcf_gpio_21 5 GPIO_ACTIVE_HIGH>;
  84. };
  85. extcon_usb1: extcon_usb1 {
  86. compatible = "linux,extcon-usb-gpio";
  87. id-gpio = <&pcf_gpio_21 1 GPIO_ACTIVE_HIGH>;
  88. };
  89. extcon_usb2: extcon_usb2 {
  90. compatible = "linux,extcon-usb-gpio";
  91. id-gpio = <&pcf_gpio_21 2 GPIO_ACTIVE_HIGH>;
  92. };
  93. hdmi0: connector {
  94. compatible = "hdmi-connector";
  95. label = "hdmi";
  96. type = "a";
  97. port {
  98. hdmi_connector_in: endpoint {
  99. remote-endpoint = <&tpd12s015_out>;
  100. };
  101. };
  102. };
  103. tpd12s015: encoder {
  104. compatible = "ti,tpd12s015";
  105. gpios = <&pcf_hdmi 4 GPIO_ACTIVE_HIGH>, /* P4, CT CP HPD */
  106. <&pcf_hdmi 5 GPIO_ACTIVE_HIGH>, /* P5, LS OE */
  107. <&gpio7 12 GPIO_ACTIVE_HIGH>; /* gpio7_12/sp1_cs2, HPD */
  108. ports {
  109. #address-cells = <1>;
  110. #size-cells = <0>;
  111. port@0 {
  112. reg = <0>;
  113. tpd12s015_in: endpoint {
  114. remote-endpoint = <&hdmi_out>;
  115. };
  116. };
  117. port@1 {
  118. reg = <1>;
  119. tpd12s015_out: endpoint {
  120. remote-endpoint = <&hdmi_connector_in>;
  121. };
  122. };
  123. };
  124. };
  125. sound0: sound0 {
  126. compatible = "simple-audio-card";
  127. simple-audio-card,name = "DRA7xx-EVM";
  128. simple-audio-card,widgets =
  129. "Headphone", "Headphone Jack",
  130. "Line", "Line Out",
  131. "Microphone", "Mic Jack",
  132. "Line", "Line In";
  133. simple-audio-card,routing =
  134. "Headphone Jack", "HPLOUT",
  135. "Headphone Jack", "HPROUT",
  136. "Line Out", "LLOUT",
  137. "Line Out", "RLOUT",
  138. "MIC3L", "Mic Jack",
  139. "MIC3R", "Mic Jack",
  140. "Mic Jack", "Mic Bias",
  141. "LINE1L", "Line In",
  142. "LINE1R", "Line In";
  143. simple-audio-card,format = "dsp_b";
  144. simple-audio-card,bitclock-master = <&sound0_master>;
  145. simple-audio-card,frame-master = <&sound0_master>;
  146. simple-audio-card,bitclock-inversion;
  147. sound0_master: simple-audio-card,cpu {
  148. sound-dai = <&mcasp3>;
  149. system-clock-frequency = <5644800>;
  150. };
  151. simple-audio-card,codec {
  152. sound-dai = <&tlv320aic3106>;
  153. clocks = <&atl_clkin2_ck>;
  154. };
  155. };
  156. vmmcwl_fixed: fixedregulator-mmcwl {
  157. compatible = "regulator-fixed";
  158. regulator-name = "vmmcwl_fixed";
  159. regulator-min-microvolt = <1800000>;
  160. regulator-max-microvolt = <1800000>;
  161. gpio = <&gpio5 8 GPIO_ACTIVE_HIGH>;
  162. enable-active-high;
  163. };
  164. clk_ov5640_fixed: clock {
  165. compatible = "fixed-clock";
  166. #clock-cells = <0>;
  167. clock-frequency = <24000000>;
  168. };
  169. };
  170. &dra7_pmx_core {
  171. dcan1_pins_default: dcan1_pins_default {
  172. pinctrl-single,pins = <
  173. DRA7XX_CORE_IOPAD(0x37d0, PIN_OUTPUT_PULLUP | MUX_MODE0) /* dcan1_tx */
  174. DRA7XX_CORE_IOPAD(0x3818, PULL_UP | MUX_MODE1) /* wakeup0.dcan1_rx */
  175. >;
  176. };
  177. dcan1_pins_sleep: dcan1_pins_sleep {
  178. pinctrl-single,pins = <
  179. DRA7XX_CORE_IOPAD(0x37d0, MUX_MODE15 | PULL_UP) /* dcan1_tx.off */
  180. DRA7XX_CORE_IOPAD(0x3818, MUX_MODE15 | PULL_UP) /* wakeup0.off */
  181. >;
  182. };
  183. };
  184. &i2c1 {
  185. status = "okay";
  186. clock-frequency = <400000>;
  187. pcf_lcd: gpio@20 {
  188. compatible = "nxp,pcf8575";
  189. reg = <0x20>;
  190. gpio-controller;
  191. #gpio-cells = <2>;
  192. interrupt-controller;
  193. #interrupt-cells = <2>;
  194. };
  195. pcf_gpio_21: gpio@21 {
  196. compatible = "nxp,pcf8575";
  197. reg = <0x21>;
  198. lines-initial-states = <0x1408>;
  199. gpio-controller;
  200. #gpio-cells = <2>;
  201. interrupt-controller;
  202. #interrupt-cells = <2>;
  203. };
  204. tlv320aic3106: tlv320aic3106@19 {
  205. #sound-dai-cells = <0>;
  206. compatible = "ti,tlv320aic3106";
  207. reg = <0x19>;
  208. adc-settle-ms = <40>;
  209. ai3x-micbias-vg = <1>; /* 2.0V */
  210. status = "okay";
  211. /* Regulators */
  212. AVDD-supply = <&evm_3v3_sw>;
  213. IOVDD-supply = <&evm_3v3_sw>;
  214. DRVDD-supply = <&evm_3v3_sw>;
  215. DVDD-supply = <&aic_dvdd>;
  216. };
  217. };
  218. &i2c5 {
  219. status = "okay";
  220. clock-frequency = <400000>;
  221. pcf_hdmi: pcf8575@26 {
  222. compatible = "nxp,pcf8575";
  223. reg = <0x26>;
  224. gpio-controller;
  225. #gpio-cells = <2>;
  226. /*
  227. * initial state is used here to keep the mdio interface
  228. * selected on RU89 through SEL_VIN4_MUX_S0, VIN2_S1 and
  229. * VIN2_S0 driven high otherwise Ethernet stops working
  230. * VIN6_SEL_S0 is low, thus selecting McASP3 over VIN6
  231. */
  232. lines-initial-states = <0x0f2b>;
  233. hdmi-audio-hog {
  234. /* vin6_sel_s0: high: VIN6, low: audio */
  235. gpio-hog;
  236. gpios = <1 GPIO_ACTIVE_HIGH>;
  237. output-low;
  238. line-name = "vin6_sel_s0";
  239. };
  240. };
  241. ov5640@3c {
  242. compatible = "ovti,ov5640";
  243. reg = <0x3c>;
  244. clocks = <&clk_ov5640_fixed>;
  245. clock-names = "xclk";
  246. port {
  247. csi2_cam0: endpoint {
  248. remote-endpoint = <&csi2_phy0>;
  249. clock-lanes = <0>;
  250. data-lanes = <1 2>;
  251. };
  252. };
  253. };
  254. };
  255. &uart1 {
  256. status = "okay";
  257. interrupts-extended = <&crossbar_mpu GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>,
  258. <&dra7_pmx_core 0x3e0>;
  259. };
  260. &elm {
  261. status = "okay";
  262. };
  263. &gpmc {
  264. /*
  265. * For the existing IOdelay configuration via U-Boot we don't
  266. * support NAND on dra72-evm. Keep it disabled. Enabling it
  267. * requires a different configuration by U-Boot.
  268. */
  269. status = "disabled";
  270. ranges = <0 0 0x08000000 0x01000000>; /* minimum GPMC partition = 16MB */
  271. nand@0,0 {
  272. /* To use NAND, DIP switch SW5 must be set like so:
  273. * SW5.1 (NAND_SELn) = ON (LOW)
  274. * SW5.9 (GPMC_WPN) = OFF (HIGH)
  275. */
  276. compatible = "ti,omap2-nand";
  277. reg = <0 0 4>; /* device IO registers */
  278. interrupt-parent = <&gpmc>;
  279. interrupts = <0 IRQ_TYPE_NONE>, /* fifoevent */
  280. <1 IRQ_TYPE_NONE>; /* termcount */
  281. rb-gpios = <&gpmc 0 GPIO_ACTIVE_HIGH>; /* gpmc_wait0 pin */
  282. ti,nand-xfer-type = "prefetch-dma";
  283. ti,nand-ecc-opt = "bch8";
  284. ti,elm-id = <&elm>;
  285. nand-bus-width = <16>;
  286. gpmc,device-width = <2>;
  287. gpmc,sync-clk-ps = <0>;
  288. gpmc,cs-on-ns = <0>;
  289. gpmc,cs-rd-off-ns = <80>;
  290. gpmc,cs-wr-off-ns = <80>;
  291. gpmc,adv-on-ns = <0>;
  292. gpmc,adv-rd-off-ns = <60>;
  293. gpmc,adv-wr-off-ns = <60>;
  294. gpmc,we-on-ns = <10>;
  295. gpmc,we-off-ns = <50>;
  296. gpmc,oe-on-ns = <4>;
  297. gpmc,oe-off-ns = <40>;
  298. gpmc,access-ns = <40>;
  299. gpmc,wr-access-ns = <80>;
  300. gpmc,rd-cycle-ns = <80>;
  301. gpmc,wr-cycle-ns = <80>;
  302. gpmc,bus-turnaround-ns = <0>;
  303. gpmc,cycle2cycle-delay-ns = <0>;
  304. gpmc,clk-activation-ns = <0>;
  305. gpmc,wr-data-mux-bus-ns = <0>;
  306. /* MTD partition table */
  307. /* All SPL-* partitions are sized to minimal length
  308. * which can be independently programmable. For
  309. * NAND flash this is equal to size of erase-block */
  310. #address-cells = <1>;
  311. #size-cells = <1>;
  312. partition@0 {
  313. label = "NAND.SPL";
  314. reg = <0x00000000 0x000020000>;
  315. };
  316. partition@1 {
  317. label = "NAND.SPL.backup1";
  318. reg = <0x00020000 0x00020000>;
  319. };
  320. partition@2 {
  321. label = "NAND.SPL.backup2";
  322. reg = <0x00040000 0x00020000>;
  323. };
  324. partition@3 {
  325. label = "NAND.SPL.backup3";
  326. reg = <0x00060000 0x00020000>;
  327. };
  328. partition@4 {
  329. label = "NAND.u-boot-spl-os";
  330. reg = <0x00080000 0x00040000>;
  331. };
  332. partition@5 {
  333. label = "NAND.u-boot";
  334. reg = <0x000c0000 0x00100000>;
  335. };
  336. partition@6 {
  337. label = "NAND.u-boot-env";
  338. reg = <0x001c0000 0x00020000>;
  339. };
  340. partition@7 {
  341. label = "NAND.u-boot-env.backup1";
  342. reg = <0x001e0000 0x00020000>;
  343. };
  344. partition@8 {
  345. label = "NAND.kernel";
  346. reg = <0x00200000 0x00800000>;
  347. };
  348. partition@9 {
  349. label = "NAND.file-system";
  350. reg = <0x00a00000 0x0f600000>;
  351. };
  352. };
  353. };
  354. &omap_dwc3_1 {
  355. extcon = <&extcon_usb1>;
  356. };
  357. &omap_dwc3_2 {
  358. extcon = <&extcon_usb2>;
  359. };
  360. &usb1 {
  361. dr_mode = "otg";
  362. extcon = <&extcon_usb1>;
  363. };
  364. &usb2 {
  365. dr_mode = "host";
  366. extcon = <&extcon_usb2>;
  367. };
  368. &mmc1 {
  369. status = "okay";
  370. pinctrl-names = "default";
  371. pinctrl-0 = <&mmc1_pins_default>;
  372. vmmc-supply = <&evm_3v3_sd>;
  373. bus-width = <4>;
  374. /*
  375. * SDCD signal is not being used here - using the fact that GPIO mode
  376. * is a viable alternative
  377. */
  378. cd-gpios = <&gpio6 27 GPIO_ACTIVE_LOW>;
  379. max-frequency = <192000000>;
  380. };
  381. &mmc2 {
  382. /* SW5-3 in ON position */
  383. status = "okay";
  384. pinctrl-names = "default";
  385. pinctrl-0 = <&mmc2_pins_default>;
  386. bus-width = <8>;
  387. non-removable;
  388. max-frequency = <192000000>;
  389. };
  390. &mmc4 {
  391. status = "okay";
  392. vmmc-supply = <&evm_3v6>;
  393. vqmmc-supply = <&vmmcwl_fixed>;
  394. bus-width = <4>;
  395. cap-power-off-card;
  396. keep-power-in-suspend;
  397. non-removable;
  398. pinctrl-names = "default", "hs", "sdr12", "sdr25";
  399. pinctrl-0 = <&mmc4_pins_default>;
  400. pinctrl-1 = <&mmc4_pins_default>;
  401. pinctrl-2 = <&mmc4_pins_default>;
  402. pinctrl-3 = <&mmc4_pins_default>;
  403. #address-cells = <1>;
  404. #size-cells = <0>;
  405. wifi@2 {
  406. compatible = "ti,wl1835";
  407. reg = <2>;
  408. interrupt-parent = <&gpio5>;
  409. interrupts = <7 IRQ_TYPE_EDGE_RISING>;
  410. };
  411. };
  412. &dcan1 {
  413. status = "okay";
  414. pinctrl-names = "default", "sleep", "active";
  415. pinctrl-0 = <&dcan1_pins_sleep>;
  416. pinctrl-1 = <&dcan1_pins_sleep>;
  417. pinctrl-2 = <&dcan1_pins_default>;
  418. };
  419. &qspi {
  420. status = "okay";
  421. spi-max-frequency = <76800000>;
  422. flash@0 {
  423. compatible = "s25fl256s1";
  424. spi-max-frequency = <76800000>;
  425. reg = <0>;
  426. spi-tx-bus-width = <1>;
  427. spi-rx-bus-width = <4>;
  428. #address-cells = <1>;
  429. #size-cells = <1>;
  430. /* MTD partition table.
  431. * The ROM checks the first four physical blocks
  432. * for a valid file to boot and the flash here is
  433. * 64KiB block size.
  434. */
  435. partition@0 {
  436. label = "QSPI.SPL";
  437. reg = <0x00000000 0x000010000>;
  438. };
  439. partition@1 {
  440. label = "QSPI.SPL.backup1";
  441. reg = <0x00010000 0x00010000>;
  442. };
  443. partition@2 {
  444. label = "QSPI.SPL.backup2";
  445. reg = <0x00020000 0x00010000>;
  446. };
  447. partition@3 {
  448. label = "QSPI.SPL.backup3";
  449. reg = <0x00030000 0x00010000>;
  450. };
  451. partition@4 {
  452. label = "QSPI.u-boot";
  453. reg = <0x00040000 0x00100000>;
  454. };
  455. partition@5 {
  456. label = "QSPI.u-boot-spl-os";
  457. reg = <0x00140000 0x00080000>;
  458. };
  459. partition@6 {
  460. label = "QSPI.u-boot-env";
  461. reg = <0x001c0000 0x00010000>;
  462. };
  463. partition@7 {
  464. label = "QSPI.u-boot-env.backup1";
  465. reg = <0x001d0000 0x0010000>;
  466. };
  467. partition@8 {
  468. label = "QSPI.kernel";
  469. reg = <0x001e0000 0x0800000>;
  470. };
  471. partition@9 {
  472. label = "QSPI.file-system";
  473. reg = <0x009e0000 0x01620000>;
  474. };
  475. };
  476. };
  477. &dss {
  478. status = "okay";
  479. };
  480. &hdmi {
  481. status = "okay";
  482. port {
  483. hdmi_out: endpoint {
  484. remote-endpoint = <&tpd12s015_in>;
  485. };
  486. };
  487. };
  488. &atl {
  489. assigned-clocks = <&abe_dpll_sys_clk_mux>,
  490. <&atl_clkctrl DRA7_ATL_ATL_CLKCTRL 26>,
  491. <&dpll_abe_ck>,
  492. <&dpll_abe_m2x2_ck>,
  493. <&atl_clkin2_ck>;
  494. assigned-clock-parents = <&sys_clkin2>, <&dpll_abe_m2_ck>;
  495. assigned-clock-rates = <0>, <0>, <180633600>, <361267200>, <5644800>;
  496. status = "okay";
  497. atl2 {
  498. bws = <DRA7_ATL_WS_MCASP2_FSX>;
  499. aws = <DRA7_ATL_WS_MCASP3_FSX>;
  500. };
  501. };
  502. &mcasp3 {
  503. #sound-dai-cells = <0>;
  504. assigned-clocks = <&l4per2_clkctrl DRA7_L4PER2_MCASP3_CLKCTRL 24>;
  505. assigned-clock-parents = <&atl_clkin2_ck>;
  506. status = "okay";
  507. op-mode = <0>; /* MCASP_IIS_MODE */
  508. tdm-slots = <2>;
  509. /* 4 serializer */
  510. serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
  511. 1 2 0 0
  512. >;
  513. tx-num-evt = <32>;
  514. rx-num-evt = <32>;
  515. };
  516. &pcie1_rc {
  517. status = "okay";
  518. };
  519. &csi2_0 {
  520. csi2_phy0: endpoint {
  521. remote-endpoint = <&csi2_cam0>;
  522. clock-lanes = <0>;
  523. data-lanes = <1 2>;
  524. };
  525. };