blob: e3d390f852102182ba01acf96f0e85020afcf941 [file] [log] [blame]
Chetan C R820790f2020-01-29 16:53:58 +05301/* Copyright (c) 2017-2018, 2020, The Linux Foundation. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 */
12
13#include "msm8909-qrd.dtsi"
14#include "msm8905.dtsi"
15#include "msm8905-256mb-memory.dtsi"
16#include "msm8905-camera-sensor-sku3.dtsi"
17
18&soc {
19 sound {
20 compatible = "qcom,msm8x16-audio-codec";
21 qcom,model = "msm8909-sku3-snd-card";
22 qcom,msm-snd-card-id = <0>;
23 qcom,msm-codec-type = "internal";
24 qcom,msm-ext-pa = "primary";
25 qcom,msm-mclk-freq = <9600000>;
26 qcom,msm-mbhc-hphl-swh = <1>;
27 qcom,msm-mbhc-gnd-swh = <0>;
28 qcom,msm-hs-micbias-type = "internal";
29 qcom,msm-micbias1-ext-cap;
30 qcom,msm-micbias2-ext-cap;
31 qcom,audio-routing =
32 "RX_BIAS", "MCLK",
33 "SPK_RX_BIAS", "MCLK",
34 "INT_LDO_H", "MCLK",
35 "MIC BIAS Internal1", "Handset Mic",
36 "MIC BIAS Internal2", "Headset Mic",
37 "AMIC1", "MIC BIAS Internal1",
38 "AMIC2", "MIC BIAS Internal2";
39 pinctrl-names = "cdc_lines_act",
40 "cdc_lines_sus";
41 pinctrl-0 = <&cdc_pdm_lines_act>;
42 pinctrl-1 = <&cdc_pdm_lines_sus>;
43 asoc-platform = <&pcm0>, <&pcm1>, <&voip>, <&voice>,
44 <&loopback>, <&compress>, <&hostless>,
45 <&afe>, <&lsm>, <&routing>, <&lpa>,
46 <&voice_svc>;
47 asoc-platform-names = "msm-pcm-dsp.0", "msm-pcm-dsp.1",
48 "msm-voip-dsp", "msm-pcm-voice",
49 "msm-pcm-loopback", "msm-compress-dsp",
50 "msm-pcm-hostless", "msm-pcm-afe",
51 "msm-lsm-client", "msm-pcm-routing",
52 "msm-pcm-lpa", "msm-voice-svc";
53 asoc-cpu = <&dai_pri_auxpcm>, <&dai_hdmi>,
54 <&dai_mi2s0>, <&dai_mi2s1>,
55 <&dai_mi2s2>, <&dai_mi2s3>,
56 <&sb_0_rx>, <&sb_0_tx>,
57 <&sb_1_rx>, <&sb_1_tx>,
58 <&sb_3_rx>, <&sb_3_tx>,
59 <&sb_4_rx>, <&sb_4_tx>,
60 <&bt_sco_rx>, <&bt_sco_tx>, <&bt_a2dp_rx>,
61 <&int_fm_rx>, <&int_fm_tx>,
62 <&afe_pcm_rx>, <&afe_pcm_tx>,
63 <&afe_proxy_rx>, <&afe_proxy_tx>,
64 <&incall_record_rx>, <&incall_record_tx>,
65 <&incall_music_rx>, <&incall_music_2_rx>;
66 asoc-cpu-names = "msm-dai-q6-auxpcm.1", "msm-dai-q6-hdmi.8",
67 "msm-dai-q6-mi2s.0", "msm-dai-q6-mi2s.1",
68 "msm-dai-q6-mi2s.2", "msm-dai-q6-mi2s.3",
69 "msm-dai-q6-dev.16384", "msm-dai-q6-dev.16385",
70 "msm-dai-q6-dev.16386", "msm-dai-q6-dev.16387",
71 "msm-dai-q6-dev.16390", "msm-dai-q6-dev.16391",
72 "msm-dai-q6-dev.16392", "msm-dai-q6-dev.16393",
73 "msm-dai-q6-dev.12288", "msm-dai-q6-dev.12289",
74 "msm-dai-q6-dev.12290",
75 "msm-dai-q6-dev.12292", "msm-dai-q6-dev.12293",
76 "msm-dai-q6-dev.224", "msm-dai-q6-dev.225",
77 "msm-dai-q6-dev.241", "msm-dai-q6-dev.240",
78 "msm-dai-q6-dev.32771", "msm-dai-q6-dev.32772",
79 "msm-dai-q6-dev.32773", "msm-dai-q6-dev.32770";
80 asoc-codec = <&stub_codec>, <&pm8909_conga_dig>;
81 asoc-codec-names = "msm-stub-codec.1", "tombak_codec";
82 };
83
84 spi@78b9000 { /* BLSP1 QUP5 */
85 status = "okay";
86 qcom,mdss_spi_client {
87 reg = <0>;
88 compatible = "qcom,mdss-spi-client";
89 label = "MDSS SPI QUP5 CLIENT";
90 spi-max-frequency = <50000000>;
91 };
92 };
93
94 i2c@78b9000 {/* BLSP1 QUP5 */
95 status = "disabled";
96 };
97
98 mdss_spi: qcom,mdss_spi {
99 compatible = "qcom,mdss-spi-display";
100 label = "mdss spi panel";
101
102 qcom,mdss-fb-map = <&mdss_fb0>;
103 qcom,mdss-mdp = <&mdss_mdp>;
104 vdd-supply = <&pm8909_l17>;
105 vddio-supply = <&pm8909_l6>;
106
107 qcom,panel-supply-entries {
108 #address-cells = <1>;
109 #size-cells = <0>;
110
111 qcom,panel-supply-entry@0 {
112 reg = <0>;
113 qcom,supply-name = "vdd";
114 qcom,supply-min-voltage = <2850000>;
115 qcom,supply-max-voltage = <2850000>;
116 qcom,supply-enable-load = <100000>;
117 qcom,supply-disable-load = <100>;
118 };
119
120 qcom,panel-supply-entry@1 {
121 reg = <1>;
122 qcom,supply-name = "vddio";
123 qcom,supply-min-voltage = <1800000>;
124 qcom,supply-max-voltage = <1800000>;
125 qcom,supply-enable-load = <100000>;
126 qcom,supply-disable-load = <100>;
127 };
128 };
129 };
130
131 matrix_keypad: matrix_keypad@0 {
132 compatible = "gpio-matrix-keypad";
133 input-name = "matrix_keypad";
134 debounce-delay-ms = <5>;
135 col-scan-delay-us = <2>;
136 pinctrl-names = "tlmm_gpio_key_active","tlmm_gpio_key_suspend";
137 pinctrl-0 = <&gpio_key_active>;
138 pinctrl-1 = <&gpio_key_suspend>;
139
140 row-gpios = <&msm_gpio 97 0
141 &msm_gpio 96 0
142 &msm_gpio 95 0
143 &msm_gpio 94 0>;
144
145 col-gpios = <&msm_gpio 52 0
146 &msm_gpio 56 0
147 &msm_gpio 7 0
148 &msm_gpio 99 0
149 &msm_gpio 6 0>;
150 linux,keymap = <0x000000e7 /* (0,0) KEY_DIAL */
151 0x00010004 /* (1,0) KEY_3 */
152 0x00020007 /* (2,0) KEY_6 */
153 0x0003000a /* (3,0) KEY_9 */
154 0x0004020b /* (4,0) KEY_NUMERIC_POUND */
155
156 0x01000069 /* (0,1) KEY_LEFT */
157 0x01010003 /* (1,1) KEY_2 */
158 0x01020006 /* (2,1) KEY_5 */
159 0x01030009 /* (3,1) KEY_8 */
160 0x0104000b /* (4,1) KEY_0 */
161
162 0x0200008b /* (0,2) KEY_MENU */
163 0x02010002 /* (1,2) KEY_1 */
164 0x02020005 /* (2,2) KEY_4 */
165 0x02030008 /* (3,2) KEY_7 */
166 0x0204020a /* (4,2) KEY_NUMERIC_STAR */
167
168 0x03000160 /* (0,3) KEY_OK */
169 0x0301006a /* (1,3) KEY_RIGHT */
170 0x0302009e /* (3,3) KEY_BACK */
171 0x03030067 /* (3,3) KEY_UP */
172 0x0304006c>; /* (3,4) KEY_DOWN */
173
174 };
175};
176
177#include "spi-panel-st7789v2-qvga-cmd.dtsi"
178
179&mdss_mdp {
180 qcom,mdss-pref-prim-intf = "spi";
181};
182
183&spi_st7789v2_qvga_cmd {
184 qcom,mdss-spi-bl-pmic-control-type = "bl_ctrl_pwm";
185 qcom,mdss-spi-bl-pmic-pwm-frequency = <100>;
186 qcom,mdss-spi-bl-pmic-bank-select = <0>;
187 qcom,mdss-spi-pwm-gpio = <&pm8909_mpps 2 0>;
188 qcom,cont-splash-enabled;
189};
190
191&msm_gpio {
192 pmx_mdss_te {
193 mdss_te_active: mdss_te_active {
194 mux {
195 pins = "gpio24";
196 };
197 config {
198 pins = "gpio24";
199 };
200 };
201 mdss_te_suspend: mdss_te_suspend {
202 mux {
203 pins = "gpio24";
204 };
205 config {
206 pins = "gpio24";
207 };
208 };
209 };
210};
211
212&mdss_spi {
213 qcom,spi-pref-prim-pan = <&spi_st7789v2_qvga_cmd>;
214 pinctrl-names = "mdss_default", "mdss_sleep";
215 pinctrl-0 = <&mdss_te_active>;
216 pinctrl-1 = <&mdss_te_suspend>;
217
218 qcom,platform-te-gpio = <&msm_gpio 24 0>;
219 qcom,platform-reset-gpio = <&msm_gpio 25 0>;
220 qcom,platform-spi-dc-gpio = <&msm_gpio 110 0>;
Manjunatha Madanaf6d25d52020-02-20 11:49:30 +0530221
222 vdd-supply = <&pm8909_l17>;
223 vddio-supply = <&pm8909_l6>;
Chetan C R820790f2020-01-29 16:53:58 +0530224};
225
226&qnand_1 {
227 status = "ok";
228};
229
230&pm8909_chg {
231 qcom,vddmax-mv = <4350>;
232 qcom,vddsafe-mv = <4380>;
233 qcom,vinmin-mv = <4470>;
234 qcom,batt-hot-percentage = <35>;
235 qcom,batt-cold-percentage = <70>;
236 qcom,tchg-mins = <360>;
237 qcom,chgr-led-support;
238 qcom,disable-vbatdet-based-recharge;
239 status = "okay";
240};
241
242/ {
243 qrd_batterydata: qcom,battery-data {
244 /* This need to be updated according to new battery */
245 qcom,rpull-up-kohm = <100>;
246 qcom,vref-batt-therm = <1800000>;
247
248 /* This need tobe updated according to new battery */
249 #include "batterydata-qrd-skua-4v35-2000mah.dtsi"
250 };
251};
252
253&pm8909_bms {
254 status = "okay";
255 qcom,force-bms-active-on-charger;
256 qcom,battery-data = <&qrd_batterydata>;
257};
258
259&pm8909_vib {
260 status = "okay";
261 qcom,vib-timeout-ms = <15000>;
262 qcom,vib-vtg-level-mV = <3100>;
263};
264
265&sdc2_cd_on {
266 /delete-property/ bias-pull-up;
267 bias-pull-down;
268};
269
270&sdc2_cd_off {
271 /delete-property/ bias-disable;
272 bias-pull-down;
273};
274
275&sdhc_2 {
276 qcom,nonhotplug;
277 interrupts = <0 1>;
278 interrupt-map = <0 &intc 0 125 0
279 1 &intc 0 221 0>;
280 interrupt-names = "hc_irq", "pwr_irq";
281 /delete-property/ cd-gpios;
282 pinctrl-names = "active", "sleep";
283 pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on>;
284 pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off>;
285};