qcom-apq8060-dragonboard.dts 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011
  1. // SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
  2. #include <dt-bindings/input/input.h>
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include <dt-bindings/leds/common.h>
  5. #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
  6. #include <dt-bindings/pinctrl/qcom,pmic-mpp.h>
  7. #include "qcom-msm8660.dtsi"
  8. / {
  9. model = "Qualcomm APQ8060 Dragonboard";
  10. compatible = "qcom,apq8060-dragonboard", "qcom,msm8660";
  11. aliases {
  12. serial0 = &gsbi12_serial;
  13. };
  14. chosen {
  15. stdout-path = "serial0:115200n8";
  16. };
  17. regulators {
  18. compatible = "simple-bus";
  19. /* Main power of the board: 3.7V */
  20. vph: regulator-fixed {
  21. compatible = "regulator-fixed";
  22. regulator-min-microvolt = <3700000>;
  23. regulator-max-microvolt = <3700000>;
  24. regulator-name = "VPH";
  25. regulator-type = "voltage";
  26. regulator-always-on;
  27. regulator-boot-on;
  28. };
  29. /* GPIO controlled ethernet power regulator */
  30. dragon_veth: xc622a331mrg {
  31. compatible = "regulator-fixed";
  32. regulator-name = "XC6222A331MR-G";
  33. regulator-min-microvolt = <3300000>;
  34. regulator-max-microvolt = <3300000>;
  35. vin-supply = <&vph>;
  36. gpio = <&pm8058_gpio 40 GPIO_ACTIVE_HIGH>;
  37. enable-active-high;
  38. pinctrl-names = "default";
  39. pinctrl-0 = <&dragon_veth_gpios>;
  40. regulator-always-on;
  41. };
  42. /* VDDvario fixed regulator */
  43. dragon_vario: nds332p {
  44. compatible = "regulator-fixed";
  45. regulator-name = "NDS332P";
  46. regulator-min-microvolt = <1800000>;
  47. regulator-max-microvolt = <1800000>;
  48. vin-supply = <&pm8058_s3>;
  49. };
  50. /* This is a levelshifter for SDCC5 */
  51. dragon_vio_txb: txb0104rgyr {
  52. compatible = "regulator-fixed";
  53. regulator-name = "Dragon SDCC levelshifter";
  54. vin-supply = <&pm8058_l14>;
  55. regulator-always-on;
  56. };
  57. };
  58. /*
  59. * Capella CM3605 light and proximity sensor mounted directly
  60. * on the sensor board.
  61. */
  62. cm3605 {
  63. compatible = "capella,cm3605";
  64. vdd-supply = <&pm8058_l14>; // 2.85V
  65. aset-gpios = <&pm8058_gpio 35 GPIO_ACTIVE_LOW>;
  66. capella,aset-resistance-ohms = <100000>;
  67. /* Trig on both edges - getting close or far away */
  68. interrupts-extended = <&pm8058_gpio 34 IRQ_TYPE_EDGE_BOTH>;
  69. /* MPP05 analog input to the XOADC */
  70. io-channels = <&xoadc 0x00 0x05>;
  71. io-channel-names = "aout";
  72. pinctrl-names = "default";
  73. pinctrl-0 = <&dragon_cm3605_gpios>, <&dragon_cm3605_mpps>;
  74. };
  75. soc {
  76. pinctrl@800000 {
  77. /* eMMC pins, all 8 data lines connected */
  78. dragon_sdcc1_pins: sdcc1 {
  79. mux {
  80. pins = "gpio159", "gpio160", "gpio161",
  81. "gpio162", "gpio163", "gpio164",
  82. "gpio165", "gpio166", "gpio167",
  83. "gpio168";
  84. function = "sdc1";
  85. };
  86. clk {
  87. pins = "gpio167"; /* SDC1 CLK */
  88. drive-strength = <16>;
  89. bias-disable;
  90. };
  91. cmd {
  92. pins = "gpio168"; /* SDC1 CMD */
  93. drive-strength = <10>;
  94. bias-pull-up;
  95. };
  96. data {
  97. /* SDC1 D0 to D7 */
  98. pins = "gpio159", "gpio160", "gpio161", "gpio162",
  99. "gpio163", "gpio164", "gpio165", "gpio166";
  100. drive-strength = <10>;
  101. bias-pull-up;
  102. };
  103. };
  104. /*
  105. * The SDCC3 pins are hardcoded (non-muxable) but need some pin
  106. * configuration.
  107. */
  108. dragon_sdcc3_pins: sdcc3 {
  109. clk {
  110. pins = "sdc3_clk";
  111. drive-strength = <8>;
  112. bias-disable;
  113. };
  114. cmd {
  115. pins = "sdc3_cmd";
  116. drive-strength = <8>;
  117. bias-pull-up;
  118. };
  119. data {
  120. pins = "sdc3_data";
  121. drive-strength = <8>;
  122. bias-pull-up;
  123. };
  124. };
  125. /* Second SD card slot pins */
  126. dragon_sdcc5_pins: sdcc5 {
  127. mux {
  128. pins = "gpio95", "gpio96", "gpio97",
  129. "gpio98", "gpio99", "gpio100";
  130. function = "sdc5";
  131. };
  132. clk {
  133. pins = "gpio97"; /* SDC5 CLK */
  134. drive-strength = <16>;
  135. bias-disable;
  136. };
  137. cmd {
  138. pins = "gpio95"; /* SDC5 CMD */
  139. drive-strength = <10>;
  140. bias-pull-up;
  141. };
  142. data {
  143. /* SDC5 D0 to D3 */
  144. pins = "gpio96", "gpio98", "gpio99", "gpio100";
  145. drive-strength = <10>;
  146. bias-pull-up;
  147. };
  148. };
  149. dragon_gsbi3_i2c_pins: gsbi3_i2c {
  150. mux {
  151. pins = "gpio43", "gpio44";
  152. function = "gsbi3";
  153. };
  154. pinconf {
  155. pins = "gpio43", "gpio44";
  156. drive-strength = <8>;
  157. /* These have external pull-up 2.2kOhm to 1.8V */
  158. bias-disable;
  159. };
  160. };
  161. dragon_gsbi8_i2c_pins: gsbi8_i2c {
  162. mux {
  163. pins = "gpio64", "gpio65";
  164. function = "gsbi8";
  165. };
  166. pinconf {
  167. pins = "gpio64", "gpio65";
  168. drive-strength = <16>;
  169. /* These have external pull-up 2.2kOhm to 1.8V */
  170. bias-disable;
  171. };
  172. };
  173. dragon_gsbi12_i2c_pins: gsbi12_i2c {
  174. mux {
  175. pins = "gpio115", "gpio116";
  176. function = "gsbi12";
  177. };
  178. pinconf {
  179. pins = "gpio115", "gpio116";
  180. drive-strength = <16>;
  181. /* These have external pull-up 4.7kOhm to 1.8V */
  182. bias-disable;
  183. };
  184. };
  185. /* Primary serial port uart 0 pins */
  186. dragon_gsbi12_serial_pins: gsbi12_serial {
  187. mux {
  188. pins = "gpio117", "gpio118";
  189. function = "gsbi12";
  190. };
  191. tx {
  192. pins = "gpio117";
  193. drive-strength = <8>;
  194. bias-disable;
  195. };
  196. rx {
  197. pins = "gpio118";
  198. drive-strength = <2>;
  199. bias-pull-up;
  200. };
  201. };
  202. dragon_ebi2_pins: ebi2 {
  203. /*
  204. * Pins used by EBI2 on the Dragonboard, actually only
  205. * CS2 is used by a real peripheral. CS0 is just
  206. * routed to a test point.
  207. */
  208. mux0 {
  209. pins =
  210. /* "gpio39", CS1A_N this is not good to mux */
  211. "gpio40", /* CS2A_N */
  212. "gpio134"; /* CS0_N testpoint TP29 */
  213. function = "ebi2cs";
  214. };
  215. mux1 {
  216. pins =
  217. /* EBI2_ADDR_7 downto EBI2_ADDR_0 address bus */
  218. "gpio123", "gpio124", "gpio125", "gpio126",
  219. "gpio127", "gpio128", "gpio129", "gpio130",
  220. /* EBI2_DATA_15 downto EBI2_DATA_0 data bus */
  221. "gpio135", "gpio136", "gpio137", "gpio138",
  222. "gpio139", "gpio140", "gpio141", "gpio142",
  223. "gpio143", "gpio144", "gpio145", "gpio146",
  224. "gpio147", "gpio148", "gpio149", "gpio150",
  225. "gpio151", /* EBI2_OE_N */
  226. "gpio153", /* EBI2_ADV */
  227. "gpio157"; /* EBI2_WE_N */
  228. function = "ebi2";
  229. };
  230. };
  231. /* Interrupt line for the KXSD9 accelerometer */
  232. dragon_kxsd9_gpios: kxsd9 {
  233. irq {
  234. pins = "gpio57"; /* IRQ line */
  235. bias-pull-up;
  236. };
  237. };
  238. dragon_tma340_gpios: tma340 {
  239. reset {
  240. /* RESET line, TS_ATTN, WAKE_CTP */
  241. pins = "gpio58";
  242. function = "gpio";
  243. drive-strength = <6>;
  244. bias-disable;
  245. };
  246. irq {
  247. pins = "gpio61"; /* IRQ line */
  248. function = "gpio";
  249. drive-strength = <2>;
  250. bias-pull-up;
  251. };
  252. };
  253. };
  254. qcom,ssbi@500000 {
  255. pmic@0 {
  256. keypad@148 {
  257. linux,keymap = <
  258. MATRIX_KEY(0, 0, KEY_MENU)
  259. MATRIX_KEY(0, 2, KEY_1)
  260. MATRIX_KEY(0, 3, KEY_4)
  261. MATRIX_KEY(0, 4, KEY_7)
  262. MATRIX_KEY(1, 0, KEY_UP)
  263. MATRIX_KEY(1, 1, KEY_LEFT)
  264. MATRIX_KEY(1, 2, KEY_DOWN)
  265. MATRIX_KEY(1, 3, KEY_5)
  266. MATRIX_KEY(1, 3, KEY_8)
  267. MATRIX_KEY(2, 0, KEY_HOME)
  268. MATRIX_KEY(2, 1, KEY_REPLY)
  269. MATRIX_KEY(2, 2, KEY_2)
  270. MATRIX_KEY(2, 3, KEY_6)
  271. MATRIX_KEY(3, 0, KEY_VOLUMEUP)
  272. MATRIX_KEY(3, 1, KEY_RIGHT)
  273. MATRIX_KEY(3, 2, KEY_3)
  274. MATRIX_KEY(3, 3, KEY_9)
  275. MATRIX_KEY(3, 4, KEY_SWITCHVIDEOMODE)
  276. MATRIX_KEY(4, 0, KEY_VOLUMEDOWN)
  277. MATRIX_KEY(4, 1, KEY_BACK)
  278. MATRIX_KEY(4, 2, KEY_CAMERA)
  279. MATRIX_KEY(4, 3, KEY_KBDILLUMTOGGLE)
  280. >;
  281. keypad,num-rows = <6>;
  282. keypad,num-columns = <5>;
  283. };
  284. gpio@150 {
  285. dragon_ethernet_gpios: ethernet-state {
  286. pinconf {
  287. pins = "gpio7";
  288. function = "normal";
  289. input-enable;
  290. bias-disable;
  291. power-source = <PM8058_GPIO_S3>;
  292. };
  293. };
  294. dragon_bmp085_gpios: bmp085-state {
  295. pinconf {
  296. pins = "gpio16";
  297. function = "normal";
  298. input-enable;
  299. bias-disable;
  300. power-source = <PM8058_GPIO_S3>;
  301. };
  302. };
  303. dragon_mpu3050_gpios: mpu3050-state {
  304. pinconf {
  305. pins = "gpio17";
  306. function = "normal";
  307. input-enable;
  308. bias-disable;
  309. power-source = <PM8058_GPIO_S3>;
  310. };
  311. };
  312. dragon_sdcc3_gpios: sdcc3-state {
  313. pinconf {
  314. pins = "gpio22";
  315. function = "normal";
  316. input-enable;
  317. bias-disable;
  318. power-source = <PM8058_GPIO_S3>;
  319. };
  320. };
  321. dragon_sdcc5_gpios: sdcc5-state {
  322. pinconf {
  323. pins = "gpio26";
  324. function = "normal";
  325. input-enable;
  326. bias-pull-up;
  327. qcom,pull-up-strength = <PMIC_GPIO_PULL_UP_30>;
  328. power-source = <PM8058_GPIO_S3>;
  329. };
  330. };
  331. dragon_ak8975_gpios: ak8975-state {
  332. pinconf {
  333. pins = "gpio33";
  334. function = "normal";
  335. input-enable;
  336. bias-disable;
  337. power-source = <PM8058_GPIO_S3>;
  338. };
  339. };
  340. dragon_cm3605_gpios: cm3605-state {
  341. /* Pin 34 connected to the proxy IRQ */
  342. gpio34-pins {
  343. pins = "gpio34";
  344. function = "normal";
  345. input-enable;
  346. bias-disable;
  347. power-source = <PM8058_GPIO_S3>;
  348. };
  349. /* Pin 35 connected to ASET */
  350. gpio35-pins {
  351. pins = "gpio35";
  352. function = "normal";
  353. output-high;
  354. bias-disable;
  355. power-source = <PM8058_GPIO_S3>;
  356. };
  357. };
  358. dragon_veth_gpios: veth-state {
  359. pinconf {
  360. pins = "gpio40";
  361. function = "normal";
  362. bias-disable;
  363. drive-push-pull;
  364. };
  365. };
  366. };
  367. mpps@50 {
  368. dragon_cm3605_mpps: cm3605-mpps-state {
  369. mpp5 {
  370. pins = "mpp5";
  371. function = "analog";
  372. input-enable;
  373. bias-high-impedance;
  374. /* Let's use channel 5 */
  375. qcom,amux-route = <PMIC_MPP_AMUX_ROUTE_CH5>;
  376. power-source = <PM8058_GPIO_S3>;
  377. };
  378. };
  379. };
  380. xoadc@197 {
  381. /* Reference voltage 2.2 V */
  382. xoadc-ref-supply = <&pm8058_l18>;
  383. /* Board-specific channels */
  384. mpp5@5 {
  385. /* Connected to AOUT of ALS sensor */
  386. reg = <0x00 0x05>;
  387. };
  388. mpp6@6 {
  389. /* Connected to test point TP43 */
  390. reg = <0x00 0x06>;
  391. };
  392. mpp7@7 {
  393. /* Connected to battery thermistor */
  394. reg = <0x00 0x07>;
  395. };
  396. mpp8@8 {
  397. /* Connected to battery ID detector */
  398. reg = <0x00 0x08>;
  399. };
  400. mpp9@9 {
  401. /* Connected to XO thermistor */
  402. reg = <0x00 0x09>;
  403. };
  404. };
  405. led@48 {
  406. /*
  407. * The keypad LED @0x48 is routed to
  408. * the sensor board where it is
  409. * connected to an infrared LED
  410. * SFH4650 (60mW, @850nm) next to the
  411. * ambient light and proximity sensor
  412. * Capella Microsystems CM3605.
  413. */
  414. compatible = "qcom,pm8058-keypad-led";
  415. reg = <0x48>;
  416. label = "pm8058:infrared:proximitysensor";
  417. default-state = "off";
  418. linux,default-trigger = "cm3605";
  419. };
  420. led@131 {
  421. compatible = "qcom,pm8058-led";
  422. reg = <0x131>;
  423. label = "pm8058:red";
  424. color = <LED_COLOR_ID_RED>;
  425. default-state = "off";
  426. };
  427. led@132 {
  428. /*
  429. * This is actually green too on my
  430. * board, but documented as yellow.
  431. */
  432. compatible = "qcom,pm8058-led";
  433. reg = <0x132>;
  434. label = "pm8058:yellow";
  435. color = <LED_COLOR_ID_YELLOW>;
  436. default-state = "off";
  437. linux,default-trigger = "mmc0";
  438. };
  439. led@133 {
  440. compatible = "qcom,pm8058-led";
  441. reg = <0x133>;
  442. label = "pm8058:green";
  443. function = LED_FUNCTION_HEARTBEAT;
  444. color = <LED_COLOR_ID_GREEN>;
  445. default-state = "on";
  446. linux,default-trigger = "heartbeat";
  447. };
  448. };
  449. };
  450. gsbi@16200000 {
  451. qcom,mode = <GSBI_PROT_I2C>;
  452. status = "okay";
  453. gsbi3_i2c: i2c@16280000 {
  454. pinctrl-names = "default";
  455. pinctrl-0 = <&dragon_gsbi3_i2c_pins>;
  456. status = "okay";
  457. touchscreen@24 {
  458. compatible = "cypress,cy8ctma340";
  459. reg = <0x24>;
  460. /* Certainly we can do at least 400 kHz */
  461. clock-frequency = <400000>;
  462. /* IRQ on GPIO61 called /CTP_INT */
  463. interrupt-parent = <&tlmm>;
  464. interrupts = <61 IRQ_TYPE_EDGE_FALLING>;
  465. /*
  466. * The I2C bus is using a PCA9306 level translator from L16A
  467. * to L2B so these two voltages are needed and L16A is
  468. * kind of the IO voltage, however L16Aisn't really fed to
  469. * the TMA340, which relies entirely on L2B (PM8901 L2).
  470. */
  471. vcpin-supply = <&pm8058_l16>;
  472. vdd-supply = <&pm8901_l2>;
  473. /* GPIO58, called WAKE_CTP */
  474. reset-gpios = <&tlmm 58 GPIO_ACTIVE_LOW>;
  475. touchscreen-size-x = <480>;
  476. touchscreen-size-y = <800>;
  477. active-interval-ms = <0>;
  478. touch-timeout-ms = <255>;
  479. lowpower-interval-ms = <10>;
  480. bootloader-key = /bits/ 8 <0x00 0x01 0x02 0x03 0x04 0x05 0x06 0x07>;
  481. pinctrl-names = "default";
  482. pinctrl-0 = <&dragon_tma340_gpios>;
  483. };
  484. };
  485. };
  486. gsbi@19800000 {
  487. status = "okay";
  488. qcom,mode = <GSBI_PROT_I2C>;
  489. i2c@19880000 {
  490. status = "okay";
  491. pinctrl-names = "default";
  492. pinctrl-0 = <&dragon_gsbi8_i2c_pins>;
  493. eeprom@52 {
  494. /* A 16KiB Platform ID EEPROM on the CPU carrier board */
  495. compatible = "atmel,24c128";
  496. reg = <0x52>;
  497. vcc-supply = <&pm8058_s3>;
  498. pagesize = <64>;
  499. };
  500. wm8903: wm8903@1a {
  501. /* This Woolfson Micro device has an unrouted interrupt line */
  502. compatible = "wlf,wm8903";
  503. reg = <0x1a>;
  504. AVDD-supply = <&pm8058_l16>;
  505. CPVDD-supply = <&pm8058_l16>;
  506. DBVDD-supply = <&pm8058_s3>;
  507. DCVDD-supply = <&pm8058_l0>;
  508. gpio-controller;
  509. #gpio-cells = <2>;
  510. micdet-cfg = <0>;
  511. micdet-delay = <100>;
  512. gpio-cfg = <0xffffffff 0xffffffff 0 0xffffffff 0xffffffff>;
  513. };
  514. };
  515. };
  516. gsbi@19c00000 {
  517. status = "okay";
  518. qcom,mode = <GSBI_PROT_I2C_UART>;
  519. serial@19c40000 {
  520. status = "okay";
  521. pinctrl-names = "default";
  522. pinctrl-0 = <&dragon_gsbi12_serial_pins>;
  523. };
  524. i2c@19c80000 {
  525. status = "okay";
  526. pinctrl-names = "default";
  527. pinctrl-0 = <&dragon_gsbi12_i2c_pins>;
  528. ak8975@c {
  529. compatible = "asahi-kasei,ak8975";
  530. reg = <0x0c>;
  531. interrupt-parent = <&pm8058_gpio>;
  532. interrupts = <33 IRQ_TYPE_EDGE_RISING>;
  533. pinctrl-names = "default";
  534. pinctrl-0 = <&dragon_ak8975_gpios>;
  535. vid-supply = <&pm8058_lvs0>; // 1.8V
  536. vdd-supply = <&pm8058_l14>; // 2.85V
  537. };
  538. bmp085@77 {
  539. compatible = "bosch,bmp085";
  540. reg = <0x77>;
  541. interrupt-parent = <&pm8058_gpio>;
  542. interrupts = <16 IRQ_TYPE_EDGE_RISING>;
  543. reset-gpios = <&tlmm 86 GPIO_ACTIVE_LOW>;
  544. pinctrl-names = "default";
  545. pinctrl-0 = <&dragon_bmp085_gpios>;
  546. vddd-supply = <&pm8058_lvs0>; // 1.8V
  547. vdda-supply = <&pm8058_l14>; // 2.85V
  548. };
  549. mpu3050@68 {
  550. compatible = "invensense,mpu3050";
  551. reg = <0x68>;
  552. /*
  553. * GPIO17 is pulled high by a 10k
  554. * resistor to VLOGIC so needs to be
  555. * active low/falling edge.
  556. */
  557. interrupts-extended = <&pm8058_gpio 17 IRQ_TYPE_EDGE_FALLING>;
  558. pinctrl-names = "default";
  559. pinctrl-0 = <&dragon_mpu3050_gpios>;
  560. vlogic-supply = <&pm8058_lvs0>; // 1.8V
  561. vdd-supply = <&pm8058_l14>; // 2.85V
  562. /*
  563. * The MPU-3050 acts as a hub for the
  564. * accelerometer.
  565. */
  566. i2c-gate {
  567. #address-cells = <1>;
  568. #size-cells = <0>;
  569. kxsd9@18 {
  570. compatible = "kionix,kxsd9";
  571. reg = <0x18>;
  572. interrupt-parent = <&tlmm>;
  573. interrupts = <57 IRQ_TYPE_EDGE_FALLING>;
  574. pinctrl-names = "default";
  575. pinctrl-0 = <&dragon_kxsd9_gpios>;
  576. iovdd-supply = <&pm8058_lvs0>; // 1.8V
  577. vdd-supply = <&pm8058_l14>; // 2.85V
  578. };
  579. };
  580. };
  581. };
  582. };
  583. external-bus@1a100000 {
  584. /* The EBI2 will instantiate first, then populate its children */
  585. status = "okay";
  586. pinctrl-names = "default";
  587. pinctrl-0 = <&dragon_ebi2_pins>;
  588. /*
  589. * An on-board SMSC LAN9221 chip for "debug ethernet",
  590. * which is actually just an ordinary ethernet on the
  591. * EBI2. This has a 25MHz chrystal next to it, so no
  592. * clocking is needed.
  593. */
  594. ethernet@2,0 {
  595. compatible = "smsc,lan9221", "smsc,lan9115";
  596. reg = <2 0x0 0x100>;
  597. /*
  598. * The second interrupt is the PME interrupt
  599. * for network wakeup, connected to the TLMM.
  600. */
  601. interrupts-extended = <&pm8058_gpio 7 IRQ_TYPE_EDGE_FALLING>,
  602. <&tlmm 29 IRQ_TYPE_EDGE_RISING>;
  603. reset-gpios = <&tlmm 30 GPIO_ACTIVE_LOW>;
  604. vdd33a-supply = <&dragon_veth>;
  605. vddvario-supply = <&dragon_vario>;
  606. pinctrl-names = "default";
  607. pinctrl-0 = <&dragon_ethernet_gpios>;
  608. phy-mode = "mii";
  609. reg-io-width = <2>;
  610. smsc,force-external-phy;
  611. smsc,irq-push-pull;
  612. /*
  613. * SLOW chipselect config
  614. * Delay 9 cycles (140ns@64MHz) between SMSC
  615. * LAN9221 Ethernet controller reads and writes
  616. * on CS2.
  617. */
  618. qcom,xmem-recovery-cycles = <0>;
  619. qcom,xmem-write-hold-cycles = <3>;
  620. qcom,xmem-write-delta-cycles = <31>;
  621. qcom,xmem-read-delta-cycles = <28>;
  622. qcom,xmem-write-wait-cycles = <9>;
  623. qcom,xmem-read-wait-cycles = <9>;
  624. };
  625. };
  626. rpm@104000 {
  627. /*
  628. * Set up of the PMIC RPM regulators for this board
  629. * PM8901 supplies "preliminary regulators" whatever
  630. * that means
  631. */
  632. pm8901-regulators {
  633. vdd_l0-supply = <&pm8901_s4>;
  634. vdd_l1-supply = <&vph>;
  635. vdd_l2-supply = <&vph>;
  636. vdd_l3-supply = <&vph>;
  637. vdd_l4-supply = <&vph>;
  638. vdd_l5-supply = <&vph>;
  639. vdd_l6-supply = <&vph>;
  640. /* vdd_s0-supply, vdd_s1-supply: SAW regulators */
  641. vdd_s2-supply = <&vph>;
  642. vdd_s3-supply = <&vph>;
  643. vdd_s4-supply = <&vph>;
  644. lvs0_in-supply = <&pm8058_s3>;
  645. lvs1_in-supply = <&pm8901_s4>;
  646. lvs2_in-supply = <&pm8058_l0>;
  647. lvs3_in-supply = <&pm8058_s2>;
  648. mvs_in-supply = <&pm8058_s3>;
  649. l0 {
  650. regulator-min-microvolt = <1200000>;
  651. regulator-max-microvolt = <1200000>;
  652. bias-pull-down;
  653. };
  654. l1 {
  655. regulator-min-microvolt = <3300000>;
  656. regulator-max-microvolt = <3300000>;
  657. bias-pull-down;
  658. };
  659. l2 {
  660. /* TMA340 requires strictly 3.3V */
  661. regulator-min-microvolt = <3300000>;
  662. regulator-max-microvolt = <3300000>;
  663. bias-pull-down;
  664. };
  665. l3 {
  666. regulator-min-microvolt = <3300000>;
  667. regulator-max-microvolt = <3300000>;
  668. bias-pull-down;
  669. };
  670. l4 {
  671. regulator-min-microvolt = <2600000>;
  672. regulator-max-microvolt = <2600000>;
  673. bias-pull-down;
  674. };
  675. l5 {
  676. regulator-min-microvolt = <2850000>;
  677. regulator-max-microvolt = <2850000>;
  678. bias-pull-down;
  679. };
  680. l6 {
  681. regulator-min-microvolt = <2200000>;
  682. regulator-max-microvolt = <2200000>;
  683. bias-pull-down;
  684. };
  685. /* s0 and s1 are SAW regulators controlled over SPM */
  686. s2 {
  687. regulator-min-microvolt = <1300000>;
  688. regulator-max-microvolt = <1300000>;
  689. qcom,switch-mode-frequency = <1600000>;
  690. bias-pull-down;
  691. };
  692. s3 {
  693. regulator-min-microvolt = <1100000>;
  694. regulator-max-microvolt = <1100000>;
  695. qcom,switch-mode-frequency = <1600000>;
  696. bias-pull-down;
  697. };
  698. s4 {
  699. regulator-min-microvolt = <1225000>;
  700. regulator-max-microvolt = <1225000>;
  701. qcom,switch-mode-frequency = <1600000>;
  702. bias-pull-down;
  703. };
  704. /* LVS0 thru 3 and mvs are just switches */
  705. lvs0 {
  706. regulator-always-on;
  707. };
  708. lvs1 { };
  709. lvs2 { };
  710. lvs3 { };
  711. mvs { };
  712. };
  713. pm8058-regulators {
  714. vdd_l0_l1_lvs-supply = <&pm8058_s3>;
  715. vdd_l2_l11_l12-supply = <&vph>;
  716. vdd_l3_l4_l5-supply = <&vph>;
  717. vdd_l6_l7-supply = <&vph>;
  718. vdd_l8-supply = <&vph>;
  719. vdd_l9-supply = <&vph>;
  720. vdd_l10-supply = <&vph>;
  721. vdd_l13_l16-supply = <&pm8058_s4>;
  722. vdd_l14_l15-supply = <&vph>;
  723. vdd_l17_l18-supply = <&vph>;
  724. vdd_l19_l20-supply = <&vph>;
  725. vdd_l21-supply = <&pm8058_s3>;
  726. vdd_l22-supply = <&pm8058_s3>;
  727. vdd_l23_l24_l25-supply = <&pm8058_s3>;
  728. vdd_s0-supply = <&vph>;
  729. vdd_s1-supply = <&vph>;
  730. vdd_s2-supply = <&vph>;
  731. vdd_s3-supply = <&vph>;
  732. vdd_s4-supply = <&vph>;
  733. vdd_ncp-supply = <&vph>;
  734. l0 {
  735. regulator-min-microvolt = <1200000>;
  736. regulator-max-microvolt = <1200000>;
  737. bias-pull-down;
  738. };
  739. l1 {
  740. regulator-min-microvolt = <1200000>;
  741. regulator-max-microvolt = <1200000>;
  742. bias-pull-down;
  743. };
  744. l2 {
  745. regulator-min-microvolt = <1800000>;
  746. regulator-max-microvolt = <2600000>;
  747. bias-pull-down;
  748. };
  749. l3 {
  750. regulator-min-microvolt = <1800000>;
  751. regulator-max-microvolt = <1800000>;
  752. bias-pull-down;
  753. };
  754. l4 {
  755. regulator-min-microvolt = <2850000>;
  756. regulator-max-microvolt = <2850000>;
  757. bias-pull-down;
  758. };
  759. l5 {
  760. regulator-min-microvolt = <2850000>;
  761. regulator-max-microvolt = <2850000>;
  762. bias-pull-down;
  763. };
  764. l6 {
  765. regulator-min-microvolt = <3000000>;
  766. regulator-max-microvolt = <3600000>;
  767. bias-pull-down;
  768. };
  769. l7 {
  770. regulator-min-microvolt = <1800000>;
  771. regulator-max-microvolt = <1800000>;
  772. bias-pull-down;
  773. };
  774. l8 {
  775. regulator-min-microvolt = <2900000>;
  776. regulator-max-microvolt = <3050000>;
  777. bias-pull-down;
  778. };
  779. l9 {
  780. regulator-min-microvolt = <1800000>;
  781. regulator-max-microvolt = <1800000>;
  782. bias-pull-down;
  783. };
  784. l10 {
  785. regulator-min-microvolt = <2600000>;
  786. regulator-max-microvolt = <2600000>;
  787. bias-pull-down;
  788. };
  789. l11 {
  790. regulator-min-microvolt = <1500000>;
  791. regulator-max-microvolt = <1500000>;
  792. bias-pull-down;
  793. };
  794. l12 {
  795. regulator-min-microvolt = <2900000>;
  796. regulator-max-microvolt = <2900000>;
  797. bias-pull-down;
  798. };
  799. l13 {
  800. regulator-min-microvolt = <2050000>;
  801. regulator-max-microvolt = <2050000>;
  802. bias-pull-down;
  803. };
  804. l14 {
  805. regulator-min-microvolt = <2850000>;
  806. regulator-max-microvolt = <2850000>;
  807. };
  808. l15 {
  809. regulator-min-microvolt = <2850000>;
  810. regulator-max-microvolt = <2850000>;
  811. bias-pull-down;
  812. };
  813. l16 {
  814. regulator-min-microvolt = <1800000>;
  815. regulator-max-microvolt = <1800000>;
  816. bias-pull-down;
  817. regulator-always-on;
  818. };
  819. l17 {
  820. // 1.5V according to schematic
  821. regulator-min-microvolt = <2600000>;
  822. regulator-max-microvolt = <2600000>;
  823. bias-pull-down;
  824. };
  825. l18 {
  826. regulator-min-microvolt = <2200000>;
  827. regulator-max-microvolt = <2200000>;
  828. bias-pull-down;
  829. };
  830. l19 {
  831. regulator-min-microvolt = <2500000>;
  832. regulator-max-microvolt = <2500000>;
  833. bias-pull-down;
  834. };
  835. l20 {
  836. regulator-min-microvolt = <1800000>;
  837. regulator-max-microvolt = <1800000>;
  838. bias-pull-down;
  839. };
  840. l21 {
  841. // 1.1 V according to schematic
  842. regulator-min-microvolt = <1200000>;
  843. regulator-max-microvolt = <1200000>;
  844. bias-pull-down;
  845. regulator-always-on;
  846. };
  847. l22 {
  848. // 1.2 V according to schematic
  849. regulator-min-microvolt = <1150000>;
  850. regulator-max-microvolt = <1150000>;
  851. bias-pull-down;
  852. };
  853. l23 {
  854. // Unused
  855. regulator-min-microvolt = <1200000>;
  856. regulator-max-microvolt = <1200000>;
  857. bias-pull-down;
  858. };
  859. l24 {
  860. // Unused
  861. regulator-min-microvolt = <1200000>;
  862. regulator-max-microvolt = <1200000>;
  863. bias-pull-down;
  864. };
  865. l25 {
  866. regulator-min-microvolt = <1200000>;
  867. regulator-max-microvolt = <1200000>;
  868. bias-pull-down;
  869. };
  870. s0 {
  871. // regulator-min-microvolt = <500000>;
  872. // regulator-max-microvolt = <1325000>;
  873. regulator-min-microvolt = <1100000>;
  874. regulator-max-microvolt = <1100000>;
  875. qcom,switch-mode-frequency = <1600000>;
  876. bias-pull-down;
  877. };
  878. s1 {
  879. // regulator-min-microvolt = <500000>;
  880. // regulator-max-microvolt = <1250000>;
  881. regulator-min-microvolt = <1100000>;
  882. regulator-max-microvolt = <1100000>;
  883. qcom,switch-mode-frequency = <1600000>;
  884. bias-pull-down;
  885. };
  886. s2 {
  887. // 1.3 V according to schematic
  888. regulator-min-microvolt = <1200000>;
  889. regulator-max-microvolt = <1400000>;
  890. qcom,switch-mode-frequency = <1600000>;
  891. bias-pull-down;
  892. };
  893. s3 {
  894. regulator-min-microvolt = <1800000>;
  895. regulator-max-microvolt = <1800000>;
  896. qcom,switch-mode-frequency = <1600000>;
  897. regulator-always-on;
  898. bias-pull-down;
  899. };
  900. s4 {
  901. regulator-min-microvolt = <2200000>;
  902. regulator-max-microvolt = <2200000>;
  903. qcom,switch-mode-frequency = <1600000>;
  904. regulator-always-on;
  905. bias-pull-down;
  906. };
  907. /* LVS0 and LVS1 are just switches */
  908. lvs0 {
  909. bias-pull-down;
  910. };
  911. lvs1 {
  912. bias-pull-down;
  913. };
  914. ncp {
  915. regulator-min-microvolt = <1800000>;
  916. regulator-max-microvolt = <1800000>;
  917. qcom,switch-mode-frequency = <1600000>;
  918. };
  919. };
  920. };
  921. amba {
  922. /* Internal 3.69 GiB eMMC */
  923. mmc@12400000 {
  924. status = "okay";
  925. pinctrl-names = "default";
  926. pinctrl-0 = <&dragon_sdcc1_pins>;
  927. vmmc-supply = <&pm8901_l5>;
  928. vqmmc-supply = <&pm8901_lvs0>;
  929. };
  930. /* External micro SD card, directly connected, pulled up to 2.85 V */
  931. mmc@12180000 {
  932. status = "okay";
  933. /* Enable SSBI GPIO 22 as input, use for card detect */
  934. pinctrl-names = "default";
  935. pinctrl-0 = <&dragon_sdcc3_pins>, <&dragon_sdcc3_gpios>;
  936. cd-gpios = <&pm8058_gpio 22 GPIO_ACTIVE_LOW>;
  937. wp-gpios = <&tlmm 110 GPIO_ACTIVE_HIGH>;
  938. vmmc-supply = <&pm8058_l14>;
  939. };
  940. /*
  941. * Second external micro SD card, using two TXB104RGYR levelshifters
  942. * to lift from 1.8 V to 2.85 V
  943. */
  944. mmc@12200000 {
  945. status = "okay";
  946. /* Enable SSBI GPIO 26 as input, use for card detect */
  947. pinctrl-names = "default";
  948. pinctrl-0 = <&dragon_sdcc5_pins>, <&dragon_sdcc5_gpios>;
  949. cd-gpios = <&pm8058_gpio 26 GPIO_ACTIVE_LOW>;
  950. wp-gpios = <&tlmm 106 GPIO_ACTIVE_HIGH>;
  951. vmmc-supply = <&pm8058_l14>;
  952. vqmmc-supply = <&dragon_vio_txb>;
  953. };
  954. };
  955. };
  956. };