qcom-msm8974-lge-nexus5-hammerhead.dts 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653
  1. // SPDX-License-Identifier: GPL-2.0
  2. #include "qcom-msm8974.dtsi"
  3. #include "qcom-pm8841.dtsi"
  4. #include "qcom-pm8941.dtsi"
  5. #include <dt-bindings/input/input.h>
  6. #include <dt-bindings/leds/common.h>
  7. #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
  8. / {
  9. model = "LGE MSM 8974 HAMMERHEAD";
  10. compatible = "lge,hammerhead", "qcom,msm8974";
  11. aliases {
  12. serial0 = &blsp1_uart1;
  13. serial1 = &blsp2_uart4;
  14. };
  15. chosen {
  16. stdout-path = "serial0:115200n8";
  17. };
  18. gpio-keys {
  19. compatible = "gpio-keys";
  20. pinctrl-names = "default";
  21. pinctrl-0 = <&gpio_keys_pin_a>;
  22. key-volume-up {
  23. label = "volume_up";
  24. gpios = <&pm8941_gpios 2 GPIO_ACTIVE_LOW>;
  25. linux,input-type = <1>;
  26. linux,code = <KEY_VOLUMEUP>;
  27. };
  28. key-volume-down {
  29. label = "volume_down";
  30. gpios = <&pm8941_gpios 3 GPIO_ACTIVE_LOW>;
  31. linux,input-type = <1>;
  32. linux,code = <KEY_VOLUMEDOWN>;
  33. };
  34. };
  35. vreg_wlan: wlan-regulator {
  36. compatible = "regulator-fixed";
  37. regulator-name = "wl-reg";
  38. regulator-min-microvolt = <3300000>;
  39. regulator-max-microvolt = <3300000>;
  40. gpio = <&tlmm 26 GPIO_ACTIVE_HIGH>;
  41. enable-active-high;
  42. pinctrl-names = "default";
  43. pinctrl-0 = <&wlan_regulator_pin>;
  44. };
  45. };
  46. &blsp1_i2c1 {
  47. status = "okay";
  48. clock-frequency = <100000>;
  49. charger: bq24192@6b {
  50. compatible = "ti,bq24192";
  51. reg = <0x6b>;
  52. interrupts-extended = <&spmi_bus 0 0xd5 0 IRQ_TYPE_EDGE_FALLING>;
  53. omit-battery-class;
  54. usb_otg_vbus: usb-otg-vbus { };
  55. };
  56. fuelgauge: max17048@36 {
  57. compatible = "maxim,max17048";
  58. reg = <0x36>;
  59. maxim,double-soc;
  60. maxim,rcomp = /bits/ 8 <0x4d>;
  61. interrupt-parent = <&tlmm>;
  62. interrupts = <9 IRQ_TYPE_LEVEL_LOW>;
  63. pinctrl-names = "default";
  64. pinctrl-0 = <&fuelgauge_pin>;
  65. maxim,alert-low-soc-level = <2>;
  66. };
  67. };
  68. &blsp1_i2c2 {
  69. status = "okay";
  70. clock-frequency = <355000>;
  71. synaptics@70 {
  72. compatible = "syna,rmi4-i2c";
  73. reg = <0x70>;
  74. interrupts-extended = <&tlmm 5 IRQ_TYPE_EDGE_FALLING>;
  75. vdd-supply = <&pm8941_l22>;
  76. vio-supply = <&pm8941_lvs3>;
  77. pinctrl-names = "default";
  78. pinctrl-0 = <&touch_pin>;
  79. #address-cells = <1>;
  80. #size-cells = <0>;
  81. rmi4-f01@1 {
  82. reg = <0x1>;
  83. syna,nosleep-mode = <1>;
  84. };
  85. rmi4-f12@12 {
  86. reg = <0x12>;
  87. syna,sensor-type = <1>;
  88. };
  89. };
  90. };
  91. &blsp1_i2c3 {
  92. status = "okay";
  93. clock-frequency = <100000>;
  94. avago_apds993@39 {
  95. compatible = "avago,apds9930";
  96. reg = <0x39>;
  97. interrupts-extended = <&tlmm 61 IRQ_TYPE_EDGE_FALLING>;
  98. vdd-supply = <&pm8941_l17>;
  99. vddio-supply = <&pm8941_lvs1>;
  100. led-max-microamp = <100000>;
  101. amstaos,proximity-diodes = <0>;
  102. };
  103. };
  104. &blsp2_i2c5 {
  105. status = "okay";
  106. clock-frequency = <355000>;
  107. led-controller@38 {
  108. compatible = "ti,lm3630a";
  109. status = "okay";
  110. reg = <0x38>;
  111. #address-cells = <1>;
  112. #size-cells = <0>;
  113. led@0 {
  114. reg = <0>;
  115. led-sources = <0 1>;
  116. label = "lcd-backlight";
  117. default-brightness = <200>;
  118. };
  119. };
  120. };
  121. &blsp2_i2c6 {
  122. status = "okay";
  123. clock-frequency = <100000>;
  124. mpu6515@68 {
  125. compatible = "invensense,mpu6515";
  126. reg = <0x68>;
  127. interrupts-extended = <&tlmm 73 IRQ_TYPE_EDGE_FALLING>;
  128. vddio-supply = <&pm8941_lvs1>;
  129. pinctrl-names = "default";
  130. pinctrl-0 = <&mpu6515_pin>;
  131. mount-matrix = "0", "-1", "0",
  132. "-1", "0", "0",
  133. "0", "0", "1";
  134. i2c-gate {
  135. #address-cells = <1>;
  136. #size-cells = <0>;
  137. ak8963@f {
  138. compatible = "asahi-kasei,ak8963";
  139. reg = <0x0f>;
  140. gpios = <&tlmm 67 GPIO_ACTIVE_HIGH>;
  141. vid-supply = <&pm8941_lvs1>;
  142. vdd-supply = <&pm8941_l17>;
  143. };
  144. bmp280@76 {
  145. compatible = "bosch,bmp280";
  146. reg = <0x76>;
  147. vdda-supply = <&pm8941_lvs1>;
  148. vddd-supply = <&pm8941_l17>;
  149. };
  150. };
  151. };
  152. };
  153. &blsp1_uart1 {
  154. status = "okay";
  155. };
  156. &blsp2_uart4 {
  157. status = "okay";
  158. bluetooth {
  159. compatible = "brcm,bcm43438-bt";
  160. max-speed = <3000000>;
  161. pinctrl-names = "default";
  162. pinctrl-0 = <&bt_pin>;
  163. host-wakeup-gpios = <&tlmm 42 GPIO_ACTIVE_HIGH>;
  164. device-wakeup-gpios = <&tlmm 62 GPIO_ACTIVE_HIGH>;
  165. shutdown-gpios = <&tlmm 41 GPIO_ACTIVE_HIGH>;
  166. };
  167. };
  168. &dsi0 {
  169. status = "okay";
  170. vdda-supply = <&pm8941_l2>;
  171. vdd-supply = <&pm8941_lvs3>;
  172. vddio-supply = <&pm8941_l12>;
  173. panel: panel@0 {
  174. reg = <0>;
  175. compatible = "lg,acx467akm-7";
  176. pinctrl-names = "default";
  177. pinctrl-0 = <&panel_pin>;
  178. port {
  179. panel_in: endpoint {
  180. remote-endpoint = <&dsi0_out>;
  181. };
  182. };
  183. };
  184. };
  185. &dsi0_out {
  186. remote-endpoint = <&panel_in>;
  187. data-lanes = <0 1 2 3>;
  188. };
  189. &dsi0_phy {
  190. status = "okay";
  191. vddio-supply = <&pm8941_l12>;
  192. };
  193. &mdss {
  194. status = "okay";
  195. };
  196. &otg {
  197. status = "okay";
  198. phys = <&usb_hs1_phy>;
  199. phy-select = <&tcsr 0xb000 0>;
  200. extcon = <&charger>, <&usb_id>;
  201. vbus-supply = <&usb_otg_vbus>;
  202. hnp-disable;
  203. srp-disable;
  204. adp-disable;
  205. ulpi {
  206. phy@a {
  207. status = "okay";
  208. v1p8-supply = <&pm8941_l6>;
  209. v3p3-supply = <&pm8941_l24>;
  210. qcom,init-seq = /bits/ 8 <0x1 0x64>;
  211. };
  212. };
  213. };
  214. &pm8941_gpios {
  215. gpio_keys_pin_a: gpio-keys-active-state {
  216. pins = "gpio2", "gpio3";
  217. function = "normal";
  218. bias-pull-up;
  219. power-source = <PM8941_GPIO_S3>;
  220. };
  221. fuelgauge_pin: fuelgauge-int-state {
  222. pins = "gpio9";
  223. function = "normal";
  224. bias-disable;
  225. input-enable;
  226. power-source = <PM8941_GPIO_S3>;
  227. };
  228. wlan_sleep_clk_pin: wl-sleep-clk-state {
  229. pins = "gpio16";
  230. function = "func2";
  231. output-high;
  232. power-source = <PM8941_GPIO_S3>;
  233. };
  234. wlan_regulator_pin: wl-reg-active-state {
  235. pins = "gpio17";
  236. function = "normal";
  237. bias-disable;
  238. power-source = <PM8941_GPIO_S3>;
  239. };
  240. otg {
  241. gpio-hog;
  242. gpios = <35 GPIO_ACTIVE_HIGH>;
  243. output-high;
  244. line-name = "otg-gpio";
  245. };
  246. };
  247. &pm8941_lpg {
  248. status = "okay";
  249. qcom,power-source = <1>;
  250. multi-led {
  251. color = <LED_COLOR_ID_RGB>;
  252. function = LED_FUNCTION_STATUS;
  253. #address-cells = <1>;
  254. #size-cells = <0>;
  255. led@7 {
  256. reg = <7>;
  257. color = <LED_COLOR_ID_RED>;
  258. };
  259. led@6 {
  260. reg = <6>;
  261. color = <LED_COLOR_ID_GREEN>;
  262. };
  263. led@5 {
  264. reg = <5>;
  265. color = <LED_COLOR_ID_BLUE>;
  266. };
  267. };
  268. };
  269. &rpm_requests {
  270. pm8841-regulators {
  271. compatible = "qcom,rpm-pm8841-regulators";
  272. pm8841_s1: s1 {
  273. regulator-min-microvolt = <675000>;
  274. regulator-max-microvolt = <1050000>;
  275. };
  276. pm8841_s2: s2 {
  277. regulator-min-microvolt = <500000>;
  278. regulator-max-microvolt = <1050000>;
  279. };
  280. pm8841_s3: s3 {
  281. regulator-min-microvolt = <1050000>;
  282. regulator-max-microvolt = <1050000>;
  283. };
  284. pm8841_s4: s4 {
  285. regulator-min-microvolt = <815000>;
  286. regulator-max-microvolt = <900000>;
  287. };
  288. };
  289. pm8941-regulators {
  290. compatible = "qcom,rpm-pm8941-regulators";
  291. vdd_l1_l3-supply = <&pm8941_s1>;
  292. vdd_l2_lvs1_2_3-supply = <&pm8941_s3>;
  293. vdd_l4_l11-supply = <&pm8941_s1>;
  294. vdd_l5_l7-supply = <&pm8941_s2>;
  295. vdd_l6_l12_l14_l15-supply = <&pm8941_s2>;
  296. vdd_l8_l16_l18_l19-supply = <&vreg_vph_pwr>;
  297. vdd_l9_l10_l17_l22-supply = <&vreg_boost>;
  298. vdd_l13_l20_l23_l24-supply = <&vreg_boost>;
  299. vdd_l21-supply = <&vreg_boost>;
  300. pm8941_s1: s1 {
  301. regulator-min-microvolt = <1300000>;
  302. regulator-max-microvolt = <1300000>;
  303. regulator-always-on;
  304. regulator-boot-on;
  305. };
  306. pm8941_s2: s2 {
  307. regulator-min-microvolt = <2150000>;
  308. regulator-max-microvolt = <2150000>;
  309. regulator-boot-on;
  310. };
  311. pm8941_s3: s3 {
  312. regulator-min-microvolt = <1800000>;
  313. regulator-max-microvolt = <1800000>;
  314. regulator-always-on;
  315. regulator-boot-on;
  316. };
  317. pm8941_l1: l1 {
  318. regulator-min-microvolt = <1225000>;
  319. regulator-max-microvolt = <1225000>;
  320. regulator-always-on;
  321. regulator-boot-on;
  322. };
  323. pm8941_l2: l2 {
  324. regulator-min-microvolt = <1200000>;
  325. regulator-max-microvolt = <1200000>;
  326. };
  327. pm8941_l3: l3 {
  328. regulator-min-microvolt = <1225000>;
  329. regulator-max-microvolt = <1225000>;
  330. };
  331. pm8941_l4: l4 {
  332. regulator-min-microvolt = <1225000>;
  333. regulator-max-microvolt = <1225000>;
  334. };
  335. pm8941_l5: l5 {
  336. regulator-min-microvolt = <1800000>;
  337. regulator-max-microvolt = <1800000>;
  338. };
  339. pm8941_l6: l6 {
  340. regulator-min-microvolt = <1800000>;
  341. regulator-max-microvolt = <1800000>;
  342. regulator-boot-on;
  343. };
  344. pm8941_l7: l7 {
  345. regulator-min-microvolt = <1800000>;
  346. regulator-max-microvolt = <1800000>;
  347. regulator-boot-on;
  348. };
  349. pm8941_l8: l8 {
  350. regulator-min-microvolt = <1800000>;
  351. regulator-max-microvolt = <1800000>;
  352. };
  353. pm8941_l9: l9 {
  354. regulator-min-microvolt = <1800000>;
  355. regulator-max-microvolt = <2950000>;
  356. };
  357. pm8941_l10: l10 {
  358. regulator-min-microvolt = <1800000>;
  359. regulator-max-microvolt = <2950000>;
  360. };
  361. pm8941_l11: l11 {
  362. regulator-min-microvolt = <1300000>;
  363. regulator-max-microvolt = <1300000>;
  364. };
  365. pm8941_l12: l12 {
  366. regulator-min-microvolt = <1800000>;
  367. regulator-max-microvolt = <1800000>;
  368. regulator-always-on;
  369. regulator-boot-on;
  370. };
  371. pm8941_l13: l13 {
  372. regulator-min-microvolt = <1800000>;
  373. regulator-max-microvolt = <2950000>;
  374. regulator-boot-on;
  375. };
  376. pm8941_l14: l14 {
  377. regulator-min-microvolt = <1800000>;
  378. regulator-max-microvolt = <1800000>;
  379. };
  380. pm8941_l15: l15 {
  381. regulator-min-microvolt = <2050000>;
  382. regulator-max-microvolt = <2050000>;
  383. };
  384. pm8941_l16: l16 {
  385. regulator-min-microvolt = <2700000>;
  386. regulator-max-microvolt = <2700000>;
  387. };
  388. pm8941_l17: l17 {
  389. regulator-min-microvolt = <2850000>;
  390. regulator-max-microvolt = <2850000>;
  391. };
  392. pm8941_l18: l18 {
  393. regulator-min-microvolt = <2850000>;
  394. regulator-max-microvolt = <2850000>;
  395. };
  396. pm8941_l19: l19 {
  397. regulator-min-microvolt = <3000000>;
  398. regulator-max-microvolt = <3300000>;
  399. };
  400. pm8941_l20: l20 {
  401. regulator-min-microvolt = <2950000>;
  402. regulator-max-microvolt = <2950000>;
  403. regulator-system-load = <200000>;
  404. regulator-allow-set-load;
  405. regulator-boot-on;
  406. };
  407. pm8941_l21: l21 {
  408. regulator-min-microvolt = <2950000>;
  409. regulator-max-microvolt = <2950000>;
  410. regulator-boot-on;
  411. };
  412. pm8941_l22: l22 {
  413. regulator-min-microvolt = <3000000>;
  414. regulator-max-microvolt = <3300000>;
  415. };
  416. pm8941_l23: l23 {
  417. regulator-min-microvolt = <3000000>;
  418. regulator-max-microvolt = <3000000>;
  419. };
  420. pm8941_l24: l24 {
  421. regulator-min-microvolt = <3075000>;
  422. regulator-max-microvolt = <3075000>;
  423. regulator-boot-on;
  424. };
  425. pm8941_lvs1: lvs1 {};
  426. pm8941_lvs3: lvs3 {};
  427. };
  428. };
  429. &sdhc_1 {
  430. status = "okay";
  431. vmmc-supply = <&pm8941_l20>;
  432. vqmmc-supply = <&pm8941_s3>;
  433. pinctrl-names = "default", "sleep";
  434. pinctrl-0 = <&sdc1_on>;
  435. pinctrl-1 = <&sdc1_off>;
  436. };
  437. &sdhc_2 {
  438. status = "okay";
  439. max-frequency = <100000000>;
  440. vmmc-supply = <&vreg_wlan>;
  441. vqmmc-supply = <&pm8941_s3>;
  442. non-removable;
  443. pinctrl-names = "default", "sleep";
  444. pinctrl-0 = <&sdc2_on>;
  445. pinctrl-1 = <&sdc2_off>;
  446. bcrmf@1 {
  447. compatible = "brcm,bcm4339-fmac", "brcm,bcm4329-fmac";
  448. reg = <1>;
  449. brcm,drive-strength = <10>;
  450. pinctrl-names = "default";
  451. pinctrl-0 = <&wlan_sleep_clk_pin>;
  452. };
  453. };
  454. &tlmm {
  455. sdc1_on: sdc1-on {
  456. clk {
  457. pins = "sdc1_clk";
  458. drive-strength = <16>;
  459. bias-disable;
  460. };
  461. cmd-data {
  462. pins = "sdc1_cmd", "sdc1_data";
  463. drive-strength = <10>;
  464. bias-pull-up;
  465. };
  466. };
  467. sdc2_on: sdc2-on {
  468. clk {
  469. pins = "sdc2_clk";
  470. drive-strength = <6>;
  471. bias-disable;
  472. };
  473. cmd-data {
  474. pins = "sdc2_cmd", "sdc2_data";
  475. drive-strength = <6>;
  476. bias-pull-up;
  477. };
  478. };
  479. mpu6515_pin: mpu6515 {
  480. pins = "gpio73";
  481. function = "gpio";
  482. bias-disable;
  483. input-enable;
  484. };
  485. touch_pin: touch {
  486. int {
  487. pins = "gpio5";
  488. function = "gpio";
  489. drive-strength = <2>;
  490. bias-disable;
  491. input-enable;
  492. };
  493. reset {
  494. pins = "gpio8";
  495. function = "gpio";
  496. drive-strength = <2>;
  497. bias-pull-up;
  498. };
  499. };
  500. panel_pin: panel {
  501. pins = "gpio12";
  502. function = "mdp_vsync";
  503. drive-strength = <2>;
  504. bias-disable;
  505. };
  506. bt_pin: bt {
  507. hostwake {
  508. pins = "gpio42";
  509. function = "gpio";
  510. };
  511. devwake {
  512. pins = "gpio62";
  513. function = "gpio";
  514. };
  515. shutdown {
  516. pins = "gpio41";
  517. function = "gpio";
  518. };
  519. };
  520. };