Advertisement
Guest User

Untitled

a guest
Oct 14th, 2019
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.27 KB | None | 0 0
  1. // SPDX-License-Identifier: GPL-2.0-only
  2.  
  3. /dts-v1/;
  4.  
  5. #include "msm8916.dtsi"
  6. #include "pm8916.dtsi"
  7. #include "msm8916-no-psci-sad-face.dtsi"
  8. #include <dt-bindings/gpio/gpio.h>
  9. #include <dt-bindings/input/input.h>
  10. #include <dt-bindings/interrupt-controller/irq.h>
  11.  
  12. / {
  13. model = "Motorola Moto G4 Play (harpia)";
  14. compatible = "motorola,harpia", "qcom,msm8916";
  15.  
  16. aliases {
  17. serial0 = &blsp1_uart1;
  18. };
  19.  
  20. chosen {
  21. stdout-path = "serial0";
  22. };
  23.  
  24. soc {
  25. sdhci@7824000 {
  26. status = "okay";
  27.  
  28. vmmc-supply = <&pm8916_l8>;
  29. vqmmc-supply = <&pm8916_l5>;
  30.  
  31. pinctrl-names = "default", "sleep";
  32. pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>;
  33. pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>;
  34. };
  35.  
  36. sdhci@7864000 {
  37. status = "okay";
  38.  
  39. vmmc-supply = <&pm8916_l11>;
  40. vqmmc-supply = <&pm8916_l12>;
  41.  
  42. pinctrl-names = "default", "sleep";
  43. pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on &sdc2_cd>;
  44. pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off &sdc2_cd>;
  45.  
  46. cd-gpios = <&msmgpio 118 GPIO_ACTIVE_LOW>;
  47. };
  48.  
  49. serial@78af000 {
  50. status = "okay";
  51. pinctrl-names = "default", "sleep";
  52. pinctrl-0 = <&blsp1_uart1_default>;
  53. pinctrl-1 = <&blsp1_uart1_sleep>;
  54. };
  55.  
  56. usb@78d9000 {
  57. status = "okay";
  58. extcon = <&usb_id>, <&usb_id>;
  59.  
  60. hnp-disable;
  61. srp-disable;
  62. adp-disable;
  63.  
  64. ulpi {
  65. phy {
  66. extcon = <&usb_id>;
  67. v1p8-supply = <&pm8916_l7>;
  68. v3p3-supply = <&pm8916_l13>;
  69. };
  70. };
  71. };
  72.  
  73. wcnss@a21b000 {
  74. status = "okay";
  75. };
  76.  
  77. gpio-keys {
  78. compatible = "gpio-keys";
  79.  
  80. pinctrl-names = "default";
  81. pinctrl-0 = <&gpio_keys_default>;
  82.  
  83. label = "GPIO Buttons";
  84.  
  85. volume-up {
  86. label = "Volume Up";
  87. gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>;
  88. linux,code = <KEY_VOLUMEUP>;
  89. debounce-interval = <15>;
  90. };
  91. };
  92.  
  93. mdss@1a00000 {
  94. dsi@1a98000 {
  95. #address-cells = <1>;
  96. #size-cells = <0>;
  97.  
  98. vdda-supply = <&pm8916_l2>;
  99. vddio-supply = <&pm8916_l6>;
  100. };
  101.  
  102. dsi-phy@1a98300 {
  103. vddio-supply = <&pm8916_l6>;
  104. qcom,dsi-phy-regulator-ldo-mode;
  105. };
  106. };
  107.  
  108. /*
  109. * Attempting to enable these devices causes a "synchronous
  110. * external abort". Suspected cause is that the debug power
  111. * domain is not enabled by default on this device.
  112. * Disable these devices for now to avoid the crash.
  113. *
  114. * See: https://lore.kernel.org/linux-arm-msm/20190618202623.GA53651@gerhold.net/
  115. */
  116. tpiu@820000 { status = "disabled"; };
  117. funnel@821000 { status = "disabled"; };
  118. replicator@824000 { status = "disabled"; };
  119. etf@825000 { status = "disabled"; };
  120. etr@826000 { status = "disabled"; };
  121. funnel@841000 { status = "disabled"; };
  122. debug@850000 { status = "disabled"; };
  123. debug@852000 { status = "disabled"; };
  124. debug@854000 { status = "disabled"; };
  125. debug@856000 { status = "disabled"; };
  126. etm@85c000 { status = "disabled"; };
  127. etm@85d000 { status = "disabled"; };
  128. etm@85e000 { status = "disabled"; };
  129. etm@85f000 { status = "disabled"; };
  130. };
  131.  
  132. usb_id: usb-id {
  133. compatible = "linux,extcon-usb-gpio";
  134. id-gpio = <&msmgpio 91 GPIO_ACTIVE_HIGH>;
  135. pinctrl-names = "default", "sleep";
  136. pinctrl-0 = <&usb_id_default>;
  137. pinctrl-1 = <&usb_id_sleep>;
  138. };
  139. };
  140.  
  141. &dsi0 {
  142. pinctrl-names = "default", "sleep";
  143. pinctrl-0 = <&pmx_mdss_default>;
  144. pinctrl-1 = <&pmx_mdss_sleep>;
  145.  
  146. panel@0 {
  147. compatible = "mdss,tianma_499_v2";
  148. reg = <0>;
  149.  
  150. reset-gpios = <&msmgpio 25 GPIO_ACTIVE_HIGH>;
  151.  
  152. ports {
  153. #address-cells = <1>;
  154. #size-cells = <0>;
  155.  
  156. port@0 {
  157. reg = <0>;
  158. panel_in: endpoint {
  159. remote-endpoint = <&dsi0_out>;
  160. };
  161. };
  162. };
  163. };
  164.  
  165. ports {
  166. port@1 {
  167. endpoint {
  168. remote-endpoint = <&panel_in>;
  169. data-lanes = <0 1 2 3>;
  170. };
  171. };
  172. };
  173. };
  174.  
  175. &spmi_bus {
  176. pm8916@0 {
  177. pon@800 {
  178. volume-down {
  179. compatible = "qcom,pm8941-resin";
  180. interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
  181. bias-pull-up;
  182. linux,code = <KEY_VOLUMEDOWN>;
  183. };
  184. };
  185. };
  186. };
  187.  
  188. &smd_rpm_regulators {
  189. vdd_l1_l2_l3-supply = <&pm8916_s3>;
  190. vdd_l4_l5_l6-supply = <&pm8916_s4>;
  191. vdd_l7-supply = <&pm8916_s4>;
  192.  
  193. s1 {
  194. regulator-min-microvolt = <500000>;
  195. regulator-max-microvolt = <1300000>;
  196. };
  197.  
  198. s3 {
  199. regulator-min-microvolt = <1200000>;
  200. regulator-max-microvolt = <1300000>;
  201. };
  202.  
  203. s4 {
  204. regulator-min-microvolt = <1800000>;
  205. regulator-max-microvolt = <2100000>;
  206. };
  207.  
  208. l1 {
  209. regulator-min-microvolt = <1225000>;
  210. regulator-max-microvolt = <1225000>;
  211. };
  212.  
  213. l2 {
  214. regulator-min-microvolt = <1200000>;
  215. regulator-max-microvolt = <1200000>;
  216. };
  217.  
  218. l3 {
  219. regulator-min-microvolt = <500000>;
  220. regulator-max-microvolt = <1287500>;
  221. };
  222.  
  223. l4 {
  224. regulator-min-microvolt = <2050000>;
  225. regulator-max-microvolt = <2050000>;
  226. };
  227.  
  228. l5 {
  229. regulator-min-microvolt = <1800000>;
  230. regulator-max-microvolt = <1800000>;
  231. };
  232.  
  233. l6 {
  234. regulator-min-microvolt = <1800000>;
  235. regulator-max-microvolt = <1800000>;
  236. };
  237.  
  238. l7 {
  239. regulator-min-microvolt = <1800000>;
  240. regulator-max-microvolt = <1800000>;
  241. };
  242.  
  243. l8 {
  244. regulator-min-microvolt = <2850000>;
  245. regulator-max-microvolt = <2900000>;
  246. };
  247.  
  248. l9 {
  249. regulator-min-microvolt = <3300000>;
  250. regulator-max-microvolt = <3300000>;
  251. };
  252.  
  253. l10 {
  254. regulator-min-microvolt = <2800000>;
  255. regulator-max-microvolt = <2800000>;
  256. };
  257.  
  258. l11 {
  259. regulator-min-microvolt = <1800000>;
  260. regulator-max-microvolt = <2950000>;
  261. regulator-allow-set-load;
  262. regulator-system-load = <200000>;
  263. };
  264.  
  265. l12 {
  266. regulator-min-microvolt = <1800000>;
  267. regulator-max-microvolt = <2950000>;
  268. };
  269.  
  270. l13 {
  271. regulator-min-microvolt = <3075000>;
  272. regulator-max-microvolt = <3075000>;
  273. };
  274.  
  275. l14 {
  276. regulator-min-microvolt = <1800000>;
  277. regulator-max-microvolt = <3300000>;
  278. };
  279.  
  280. l15 {
  281. regulator-min-microvolt = <1800000>;
  282. regulator-max-microvolt = <3300000>;
  283. };
  284.  
  285. l16 {
  286. regulator-min-microvolt = <1800000>;
  287. regulator-max-microvolt = <3300000>;
  288. };
  289.  
  290. l17 {
  291. regulator-min-microvolt = <2850000>;
  292. regulator-max-microvolt = <2850000>;
  293. };
  294.  
  295. l18 {
  296. regulator-min-microvolt = <2700000>;
  297. regulator-max-microvolt = <2700000>;
  298. };
  299. };
  300.  
  301. &msmgpio {
  302. /delete-node/ pmx_sdc2_cd_pin;
  303.  
  304. gpio_keys_default: gpio-keys-default {
  305. pinmux {
  306. function = "gpio";
  307. pins = "gpio107";
  308. };
  309. pinconf {
  310. pins = "gpio107";
  311. drive-strength = <2>;
  312. bias-pull-up;
  313. };
  314. };
  315.  
  316. pmx_mdss_default: pmx_mdss_default {
  317. pinmux {
  318. function = "gpio";
  319. pins = "gpio25";
  320. };
  321. pinconf {
  322. drive-strength = <8>;
  323. bias-disable;
  324. };
  325. };
  326.  
  327. pmx_mdss_sleep: pmx_mdss_sleep {
  328. pinmux {
  329. function = "gpio";
  330. pins = "gpio25";
  331. };
  332. pinconf {
  333. drive-strength = <2>;
  334. bias-pull-down;
  335. };
  336. };
  337.  
  338. sdc2_cd: pmx_sdc2_cd_pin {
  339. pinmux {
  340. function = "gpio";
  341. pins = "gpio118";
  342. };
  343. pinconf {
  344. pins = "gpio118";
  345. drive-strength = <2>;
  346. bias-disable;
  347. };
  348. };
  349.  
  350. usb-id {
  351. usb_id_default: id-default {
  352. pinmux {
  353. function = "gpio";
  354. pins = "gpio91";
  355. };
  356. pinconf {
  357. pins = "gpio91";
  358. drive-strength = <8>;
  359. bias-pull-up;
  360. };
  361. };
  362. usb_id_sleep: id-sleep {
  363. pinmux {
  364. function = "gpio";
  365. pins = "gpio91";
  366. };
  367. pinconf {
  368. pins = "gpio91";
  369. drive-strength = <8>;
  370. bias-disable;
  371. };
  372. };
  373. };
  374. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement