lpc4357-ea4357-devkit.dts 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623
  1. /*
  2. * Embedded Artist LPC4357 Developer's Kit
  3. *
  4. * Copyright 2015 Joachim Eastwood <[email protected]>
  5. *
  6. * This code is released using a dual license strategy: BSD/GPL
  7. * You can choose the licence that better fits your requirements.
  8. *
  9. * Released under the terms of 3-clause BSD License
  10. * Released under the terms of GNU General Public License Version 2.0
  11. *
  12. */
  13. /dts-v1/;
  14. #include "lpc18xx.dtsi"
  15. #include "lpc4357.dtsi"
  16. #include "dt-bindings/input/input.h"
  17. #include "dt-bindings/gpio/gpio.h"
  18. / {
  19. model = "Embedded Artists' LPC4357 Developer's Kit";
  20. compatible = "ea,lpc4357-developers-kit", "nxp,lpc4357", "nxp,lpc4350";
  21. aliases {
  22. serial0 = &uart0;
  23. serial1 = &uart1;
  24. serial2 = &uart2;
  25. serial3 = &uart3;
  26. };
  27. chosen {
  28. stdout-path = &uart0;
  29. };
  30. memory@28000000 {
  31. device_type = "memory";
  32. reg = <0x28000000 0x2000000>; /* 32 MB */
  33. };
  34. vcc: vcc_fixed {
  35. compatible = "regulator-fixed";
  36. regulator-name = "3v3-supply";
  37. regulator-min-microvolt = <3300000>;
  38. regulator-max-microvolt = <3300000>;
  39. };
  40. /* vmmc is controlled by sdmmc host internally */
  41. vmmc: vmmc_fixed {
  42. compatible = "regulator-fixed";
  43. regulator-name = "vmmc-supply";
  44. regulator-min-microvolt = <3300000>;
  45. regulator-max-microvolt = <3300000>;
  46. };
  47. gpio_joystick {
  48. compatible = "gpio-keys-polled";
  49. pinctrl-names = "default";
  50. pinctrl-0 = <&gpio_joystick_pins>;
  51. poll-interval = <100>;
  52. autorepeat;
  53. button0 {
  54. label = "joy_enter";
  55. linux,code = <KEY_ENTER>;
  56. gpios = <&gpio LPC_GPIO(4,8) GPIO_ACTIVE_LOW>;
  57. };
  58. button1 {
  59. label = "joy_left";
  60. linux,code = <KEY_LEFT>;
  61. gpios = <&gpio LPC_GPIO(4,9) GPIO_ACTIVE_LOW>;
  62. };
  63. button2 {
  64. label = "joy_up";
  65. linux,code = <KEY_UP>;
  66. gpios = <&gpio LPC_GPIO(4,10) GPIO_ACTIVE_LOW>;
  67. };
  68. button3 {
  69. label = "joy_right";
  70. linux,code = <KEY_RIGHT>;
  71. gpios = <&gpio LPC_GPIO(4,12) GPIO_ACTIVE_LOW>;
  72. };
  73. button4 {
  74. label = "joy_down";
  75. linux,code = <KEY_DOWN>;
  76. gpios = <&gpio LPC_GPIO(4,13) GPIO_ACTIVE_LOW>;
  77. };
  78. };
  79. leds_mmio {
  80. compatible = "gpio-leds";
  81. led1 {
  82. gpios = <&mmio_leds 15 GPIO_ACTIVE_HIGH>;
  83. linux,default-trigger = "heartbeat";
  84. };
  85. led2 {
  86. gpios = <&mmio_leds 14 GPIO_ACTIVE_HIGH>;
  87. };
  88. led3 {
  89. gpios = <&mmio_leds 13 GPIO_ACTIVE_HIGH>;
  90. };
  91. led4 {
  92. gpios = <&mmio_leds 12 GPIO_ACTIVE_HIGH>;
  93. };
  94. led5 {
  95. gpios = <&mmio_leds 11 GPIO_ACTIVE_HIGH>;
  96. };
  97. led6 {
  98. gpios = <&mmio_leds 10 GPIO_ACTIVE_HIGH>;
  99. };
  100. led7 {
  101. gpios = <&mmio_leds 9 GPIO_ACTIVE_HIGH>;
  102. };
  103. led8 {
  104. gpios = <&mmio_leds 8 GPIO_ACTIVE_HIGH>;
  105. };
  106. led9 {
  107. gpios = <&mmio_leds 7 GPIO_ACTIVE_HIGH>;
  108. };
  109. led10 {
  110. gpios = <&mmio_leds 6 GPIO_ACTIVE_HIGH>;
  111. };
  112. led11 {
  113. gpios = <&mmio_leds 5 GPIO_ACTIVE_HIGH>;
  114. };
  115. led12 {
  116. gpios = <&mmio_leds 4 GPIO_ACTIVE_HIGH>;
  117. };
  118. led13 {
  119. gpios = <&mmio_leds 3 GPIO_ACTIVE_HIGH>;
  120. };
  121. led14 {
  122. gpios = <&mmio_leds 2 GPIO_ACTIVE_HIGH>;
  123. };
  124. led15 {
  125. gpios = <&mmio_leds 1 GPIO_ACTIVE_HIGH>;
  126. };
  127. led16 {
  128. gpios = <&mmio_leds 0 GPIO_ACTIVE_HIGH>;
  129. };
  130. };
  131. };
  132. &pinctrl {
  133. emc_pins: emc-pins {
  134. emc_addr0_23_cfg {
  135. pins = "p2_9", "p2_10", "p2_11", "p2_12",
  136. "p2_13", "p1_0", "p1_1", "p1_2",
  137. "p2_8", "p2_7", "p2_6", "p2_2",
  138. "p2_1", "p2_0", "p6_8", "p6_7",
  139. "pd_16", "pd_15", "pe_0", "pe_1",
  140. "pe_2", "pe_3", "pe_4", "pa_4";
  141. function = "emc";
  142. slew-rate = <1>;
  143. bias-disable;
  144. input-enable;
  145. input-schmitt-disable;
  146. };
  147. emc_data0_31_cfg {
  148. pins = "p1_7", "p1_8", "p1_9", "p1_10",
  149. "p1_11", "p1_12", "p1_13", "p1_14",
  150. "p5_4", "p5_5", "p5_6", "p5_7",
  151. "p5_0", "p5_1", "p5_2", "p5_3",
  152. "pd_2", "pd_3", "pd_4", "pd_5",
  153. "pd_6", "pd_7", "pd_8", "pd_9",
  154. "pe_5", "pe_6", "pe_7", "pe_8",
  155. "pe_9", "pe_10", "pe_11", "pe_12";
  156. function = "emc";
  157. slew-rate = <1>;
  158. bias-disable;
  159. input-enable;
  160. input-schmitt-disable;
  161. };
  162. emc_we_oe_cfg {
  163. pins = "p1_6", "p1_3";
  164. function = "emc";
  165. slew-rate = <1>;
  166. bias-disable;
  167. input-enable;
  168. input-schmitt-disable;
  169. };
  170. emc_bls0_3_cfg {
  171. pins = "p1_4", "p6_6", "pd_13", "pd_10";
  172. function = "emc";
  173. slew-rate = <1>;
  174. bias-disable;
  175. input-enable;
  176. input-schmitt-disable;
  177. };
  178. emc_cs0_3_cfg {
  179. pins = "p1_5", "p6_3", "pd_12", "pd_11";
  180. function = "emc";
  181. slew-rate = <1>;
  182. bias-disable;
  183. input-enable;
  184. input-schmitt-disable;
  185. };
  186. emc_sdram_dqm0_3_cfg {
  187. pins = "p6_12", "p6_10", "pd_0", "pe_13";
  188. function = "emc";
  189. slew-rate = <1>;
  190. bias-disable;
  191. input-enable;
  192. input-schmitt-disable;
  193. };
  194. emc_sdram_ras_cas_cfg {
  195. pins = "p6_5", "p6_4";
  196. function = "emc";
  197. slew-rate = <1>;
  198. bias-disable;
  199. input-enable;
  200. input-schmitt-disable;
  201. };
  202. emc_sdram_dycs0_cfg {
  203. pins = "p6_9";
  204. function = "emc";
  205. slew-rate = <1>;
  206. bias-disable;
  207. input-enable;
  208. input-schmitt-disable;
  209. };
  210. emc_sdram_cke_cfg {
  211. pins = "p6_11";
  212. function = "emc";
  213. slew-rate = <1>;
  214. bias-disable;
  215. input-enable;
  216. input-schmitt-disable;
  217. };
  218. emc_sdram_clock_cfg {
  219. pins = "clk0", "clk1", "clk2", "clk3";
  220. function = "emc";
  221. slew-rate = <1>;
  222. bias-disable;
  223. input-enable;
  224. input-schmitt-disable;
  225. };
  226. };
  227. enet_rmii_pins: enet-rmii-pins {
  228. enet_rmii_rxd_cfg {
  229. pins = "p1_15", "p0_0";
  230. function = "enet";
  231. slew-rate = <1>;
  232. bias-disable;
  233. input-enable;
  234. input-schmitt-disable;
  235. };
  236. enet_rmii_txd_cfg {
  237. pins = "p1_18", "p1_20";
  238. function = "enet";
  239. slew-rate = <1>;
  240. bias-disable;
  241. input-enable;
  242. input-schmitt-disable;
  243. };
  244. enet_rmii_rx_dv_cfg {
  245. pins = "p1_16";
  246. function = "enet";
  247. bias-disable;
  248. input-enable;
  249. input-schmitt-disable;
  250. };
  251. enet_rmii_tx_en_cfg {
  252. pins = "p0_1";
  253. function = "enet";
  254. bias-disable;
  255. input-enable;
  256. input-schmitt-disable;
  257. };
  258. enet_ref_clk_cfg {
  259. pins = "p1_19";
  260. function = "enet";
  261. slew-rate = <1>;
  262. bias-disable;
  263. input-enable;
  264. input-schmitt-disable;
  265. };
  266. enet_mdio_cfg {
  267. pins = "p1_17";
  268. function = "enet";
  269. bias-disable;
  270. input-enable;
  271. input-schmitt-disable;
  272. };
  273. enet_mdc_cfg {
  274. pins = "pc_1";
  275. function = "enet";
  276. slew-rate = <1>;
  277. bias-disable;
  278. input-enable;
  279. input-schmitt-disable;
  280. };
  281. };
  282. gpio_joystick_pins: gpio-joystick-pins {
  283. gpio_joystick_cfg {
  284. pins = "p9_0", "p9_1", "pa_1", "pa_2", "pa_3";
  285. function = "gpio";
  286. input-enable;
  287. bias-disable;
  288. };
  289. };
  290. i2c0_pins: i2c0-pins {
  291. i2c0_pins_cfg {
  292. pins = "i2c0_scl", "i2c0_sda";
  293. function = "i2c0";
  294. input-enable;
  295. };
  296. };
  297. sdmmc_pins: sdmmc-pins {
  298. sdmmc_clk_cfg {
  299. pins = "pc_0";
  300. function = "sdmmc";
  301. slew-rate = <1>;
  302. bias-pull-down;
  303. };
  304. sdmmc_cmd_dat0_3_cfg {
  305. pins = "pc_4", "pc_5", "pc_6", "pc_7", "pc_10";
  306. function = "sdmmc";
  307. slew-rate = <1>;
  308. bias-disable;
  309. input-enable;
  310. input-schmitt-disable;
  311. };
  312. sdmmc_cd_cfg {
  313. pins = "pc_8";
  314. function = "sdmmc";
  315. bias-pull-down;
  316. input-enable;
  317. };
  318. sdmmc_pow_cfg {
  319. pins = "pc_9";
  320. function = "sdmmc";
  321. bias-pull-down;
  322. };
  323. };
  324. spifi_pins: spifi-pins {
  325. spifi_clk_cfg {
  326. pins = "p3_3";
  327. function = "spifi";
  328. slew-rate = <1>;
  329. bias-disable;
  330. input-enable;
  331. input-schmitt-disable;
  332. };
  333. spifi_mosi_miso_sio2_3_cfg {
  334. pins = "p3_7", "p3_6", "p3_5", "p3_4";
  335. function = "spifi";
  336. slew-rate = <0>;
  337. bias-disable;
  338. input-enable;
  339. input-schmitt-disable;
  340. };
  341. spifi_cs_cfg {
  342. pins = "p3_8";
  343. function = "spifi";
  344. bias-disable;
  345. };
  346. };
  347. ssp0_pins: ssp0-pins {
  348. ssp0_sck_miso_mosi {
  349. pins = "pf_0", "pf_2", "pf_3";
  350. function = "ssp0";
  351. slew-rate = <1>;
  352. bias-pull-down;
  353. input-enable;
  354. input-schmitt-disable;
  355. };
  356. ssp0_ssel {
  357. pins = "pf_1";
  358. function = "ssp0";
  359. bias-pull-up;
  360. };
  361. };
  362. uart0_pins: uart0-pins {
  363. uart0_rx_cfg {
  364. pins = "pf_11";
  365. function = "uart0";
  366. input-schmitt-disable;
  367. bias-disable;
  368. input-enable;
  369. };
  370. uart0_tx_cfg {
  371. pins = "pf_10";
  372. function = "uart0";
  373. bias-pull-down;
  374. };
  375. };
  376. uart3_pins: uart3-pins {
  377. uart3_rx_cfg {
  378. pins = "p2_4";
  379. function = "uart3";
  380. input-schmitt-disable;
  381. bias-disable;
  382. input-enable;
  383. };
  384. uart3_tx_cfg {
  385. pins = "p9_3";
  386. function = "uart3";
  387. bias-pull-down;
  388. };
  389. };
  390. usb0_pins: usb0-pins {
  391. usb0_pwr_enable {
  392. pins = "p2_3";
  393. function = "usb0";
  394. };
  395. usb0_pwr_fault {
  396. pins = "p8_0";
  397. function = "usb0";
  398. bias-disable;
  399. input-enable;
  400. };
  401. };
  402. };
  403. &adc0 {
  404. status = "okay";
  405. vref-supply = <&vcc>;
  406. };
  407. &i2c0 {
  408. status = "okay";
  409. pinctrl-names = "default";
  410. pinctrl-0 = <&i2c0_pins>;
  411. clock-frequency = <400000>;
  412. mma7455@1d {
  413. compatible = "fsl,mma7455";
  414. reg = <0x1d>;
  415. };
  416. lm75@48 {
  417. compatible = "nxp,lm75";
  418. reg = <0x48>;
  419. };
  420. eeprom@57 {
  421. compatible = "microchip,24c64", "atmel,24c64";
  422. reg = <0x57>;
  423. };
  424. };
  425. &dac {
  426. status = "okay";
  427. vref-supply = <&vcc>;
  428. };
  429. &emc {
  430. status = "okay";
  431. pinctrl-names = "default";
  432. pinctrl-0 = <&emc_pins>;
  433. cs0 {
  434. #address-cells = <2>;
  435. #size-cells = <1>;
  436. ranges;
  437. mpmc,cs = <0>;
  438. mpmc,memory-width = <16>;
  439. mpmc,byte-lane-low;
  440. mpmc,write-enable-delay = <0>;
  441. mpmc,output-enable-delay = <0>;
  442. mpmc,read-access-delay = <70>;
  443. mpmc,page-mode-read-delay = <70>;
  444. flash@0,0 {
  445. compatible = "sst,sst39vf320", "cfi-flash";
  446. reg = <0 0 0x400000>;
  447. bank-width = <2>;
  448. #address-cells = <1>;
  449. #size-cells = <1>;
  450. partition@0 {
  451. label = "bootloader";
  452. reg = <0x000000 0x040000>; /* 256 KiB */
  453. };
  454. partition@1 {
  455. label = "kernel";
  456. reg = <0x040000 0x2c0000>; /* 2.75 MiB */
  457. };
  458. partition@2 {
  459. label = "rootfs";
  460. reg = <0x300000 0x100000>; /* 1 MiB */
  461. };
  462. };
  463. };
  464. cs2 {
  465. #address-cells = <2>;
  466. #size-cells = <1>;
  467. ranges;
  468. mpmc,cs = <2>;
  469. mpmc,memory-width = <16>;
  470. mmio_leds: gpio@2,0 {
  471. compatible = "ti,7416374";
  472. reg = <2 0 0x2>;
  473. gpio-controller;
  474. #gpio-cells = <2>;
  475. };
  476. };
  477. };
  478. &enet_tx_clk {
  479. clock-frequency = <50000000>;
  480. };
  481. &mac {
  482. status = "okay";
  483. phy-mode = "rmii";
  484. pinctrl-names = "default";
  485. pinctrl-0 = <&enet_rmii_pins>;
  486. };
  487. &mmcsd {
  488. status = "okay";
  489. bus-width = <4>;
  490. vmmc-supply = <&vmmc>;
  491. pinctrl-names = "default";
  492. pinctrl-0 = <&sdmmc_pins>;
  493. };
  494. &spifi {
  495. status = "okay";
  496. pinctrl-names = "default";
  497. pinctrl-0 = <&spifi_pins>;
  498. flash {
  499. compatible = "jedec,spi-nor";
  500. spi-cpol;
  501. spi-cpha;
  502. spi-rx-bus-width = <4>;
  503. #address-cells = <1>;
  504. #size-cells = <1>;
  505. partition@0 {
  506. label = "data";
  507. reg = <0 0x200000>;
  508. };
  509. };
  510. };
  511. &ssp0 {
  512. status = "okay";
  513. pinctrl-names = "default";
  514. pinctrl-0 = <&ssp0_pins>;
  515. num-cs = <1>;
  516. };
  517. &uart0 {
  518. status = "okay";
  519. pinctrl-names = "default";
  520. pinctrl-0 = <&uart0_pins>;
  521. };
  522. &uart3 {
  523. status = "okay";
  524. pinctrl-names = "default";
  525. pinctrl-0 = <&uart3_pins>;
  526. };
  527. &usb0 {
  528. status = "okay";
  529. pinctrl-names = "default";
  530. pinctrl-0 = <&usb0_pins>;
  531. };