Maria Yu | 598eb70 | 2017-12-28 21:09:38 +0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2018, The Linux Foundation. All rights reserved. |
| 3 | * |
| 4 | * This program is free software; you can redistribute it and/or modify |
| 5 | * it under the terms of the GNU General Public License version 2 and |
| 6 | * only version 2 as published by the Free Software Foundation. |
| 7 | * |
| 8 | * This program is distributed in the hope that it will be useful, |
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 11 | * GNU General Public License for more details. |
| 12 | */ |
| 13 | |
| 14 | #include "msm8953-qrd.dtsi" |
Lei Chen | cc97eb7 | 2018-01-27 11:59:40 +0800 | [diff] [blame] | 15 | #include "msm8953-mdss-panels.dtsi" |
Vijay kumar Tumati | 408b096 | 2018-03-16 17:28:31 +0530 | [diff] [blame] | 16 | #include "msm8953-camera-sensor-qrd.dtsi" |
Maria Yu | 598eb70 | 2017-12-28 21:09:38 +0800 | [diff] [blame] | 17 | |
Liangliang Lu | 070ea8e | 2018-02-09 11:14:44 +0800 | [diff] [blame] | 18 | &qusb_phy { |
| 19 | qcom,qusb-phy-init-seq = <0x78 0x80 |
| 20 | 0xb3 0x84 |
| 21 | 0x83 0x88 |
| 22 | 0xc7 0x8c |
| 23 | 0x14 0x9c |
| 24 | 0x30 0x08 |
| 25 | 0x79 0x0c |
| 26 | 0x21 0x10 |
| 27 | 0x00 0x90 |
| 28 | 0x9f 0x1c |
| 29 | 0x00 0x18>; |
| 30 | }; |
| 31 | |
Maria Yu | 598eb70 | 2017-12-28 21:09:38 +0800 | [diff] [blame] | 32 | &i2c_3 { |
| 33 | status = "disabled"; |
| 34 | }; |
| 35 | |
Soumya Managoli | 91ec950 | 2018-01-18 16:53:47 +0530 | [diff] [blame] | 36 | &int_codec { |
| 37 | status = "okay"; |
| 38 | qcom,model = "msm8953-sku4-snd-card"; |
| 39 | qcom,msm-micbias1-ext-cap; |
Meng Wang | 1e9123d | 2018-03-06 10:21:33 +0800 | [diff] [blame] | 40 | qcom,msm-micbias2-ext-cap; |
Soumya Managoli | 91ec950 | 2018-01-18 16:53:47 +0530 | [diff] [blame] | 41 | qcom,msm-mbhc-hphl-swh = <1>; |
| 42 | qcom,msm-mbhc-gnd-swh = <0>; |
Meng Wang | 1e9123d | 2018-03-06 10:21:33 +0800 | [diff] [blame] | 43 | qcom,msm-hs-micbias-type = "external"; |
Soumya Managoli | 91ec950 | 2018-01-18 16:53:47 +0530 | [diff] [blame] | 44 | }; |
| 45 | |
| 46 | &wsa881x_i2c_f { |
| 47 | status = "okay"; |
| 48 | }; |
| 49 | |
| 50 | &wsa881x_i2c_45 { |
| 51 | status = "okay"; |
| 52 | }; |
| 53 | |
Lei Chen | cc97eb7 | 2018-01-27 11:59:40 +0800 | [diff] [blame] | 54 | &tlmm { |
| 55 | pmx_mdss { |
| 56 | mdss_dsi_active: mdss_dsi_active { |
| 57 | mux { |
| 58 | pins = "gpio61"; |
| 59 | }; |
| 60 | config { |
| 61 | pins = "gpio61"; |
| 62 | }; |
| 63 | }; |
| 64 | mdss_dsi_suspend: mdss_dsi_suspend { |
| 65 | mux { |
| 66 | pins = "gpio61"; |
| 67 | }; |
| 68 | config { |
| 69 | pins = "gpio61"; |
| 70 | }; |
| 71 | }; |
| 72 | }; |
| 73 | }; |
| 74 | |
| 75 | &dsi_panel_pwr_supply { |
| 76 | qcom,panel-supply-entry@2 { |
| 77 | reg = <2>; |
| 78 | qcom,supply-name = "lab"; |
| 79 | qcom,supply-min-voltage = <4600000>; |
| 80 | qcom,supply-max-voltage = <6000000>; |
| 81 | qcom,supply-enable-load = <100000>; |
| 82 | qcom,supply-disable-load = <100>; |
| 83 | }; |
| 84 | |
| 85 | qcom,panel-supply-entry@3 { |
| 86 | reg = <3>; |
| 87 | qcom,supply-name = "ibb"; |
| 88 | qcom,supply-min-voltage = <4600000>; |
| 89 | qcom,supply-max-voltage = <6000000>; |
| 90 | qcom,supply-enable-load = <100000>; |
| 91 | qcom,supply-disable-load = <100>; |
| 92 | qcom,supply-post-on-sleep = <10>; |
| 93 | }; |
| 94 | }; |
| 95 | |
| 96 | &mdss_mdp { |
| 97 | qcom,mdss-pref-prim-intf = "dsi"; |
| 98 | }; |
| 99 | |
| 100 | &mdss_dsi { |
| 101 | hw-config = "single_dsi"; |
| 102 | }; |
| 103 | |
| 104 | &mdss_dsi0 { |
| 105 | lab-supply = <&lcdb_ldo_vreg>; |
| 106 | ibb-supply = <&lcdb_ncp_vreg>; |
| 107 | /delete-property/ vdd-supply; |
| 108 | |
| 109 | qcom,dsi-pref-prim-pan = <&dsi_hx8399c_truly_vid>; |
| 110 | qcom,platform-bklight-en-gpio = <&pm8953_gpios 4 0>; |
| 111 | pinctrl-names = "mdss_default", "mdss_sleep"; |
| 112 | pinctrl-0 = <&mdss_dsi_active &mdss_te_active>; |
| 113 | pinctrl-1 = <&mdss_dsi_suspend &mdss_te_suspend>; |
| 114 | qcom,platform-te-gpio = <&tlmm 24 0>; |
| 115 | qcom,platform-reset-gpio = <&tlmm 61 0>; |
| 116 | }; |
| 117 | |
| 118 | &mdss_dsi1 { |
| 119 | status = "disabled"; |
| 120 | }; |
| 121 | |
| 122 | &dsi_hx8399c_truly_vid { |
| 123 | qcom,mdss-dsi-bl-pmic-control-type = "bl_ctrl_pwm"; |
| 124 | qcom,mdss-dsi-bl-pmic-pwm-frequency = <100>; |
| 125 | qcom,mdss-dsi-bl-pmic-bank-select = <0>; |
| 126 | qcom,mdss-dsi-pwm-gpio = <&pm8953_gpios 8 0>; |
| 127 | qcom,panel-supply-entries = <&dsi_panel_pwr_supply>; |
| 128 | }; |
Fenglin Wu | 65fb52d | 2018-02-02 09:11:55 +0800 | [diff] [blame] | 129 | |
| 130 | &soc { |
| 131 | gpio_keys { |
| 132 | compatible = "gpio-keys"; |
| 133 | label = "gpio-keys"; |
| 134 | pinctrl-names = "default", "sleep"; |
| 135 | pinctrl-0 = <&gpio_key_active>; |
| 136 | pinctrl-1 = <&gpio_key_suspend>; |
| 137 | |
| 138 | vol_up { |
| 139 | label = "volume_up"; |
| 140 | gpios = <&tlmm 85 GPIO_ACTIVE_LOW>; |
| 141 | linux,input-type = <1>; |
| 142 | linux,code = <115>; |
| 143 | gpio-key,wakeup; |
| 144 | debounce-interval = <15>; |
| 145 | linux,can-disable; |
| 146 | }; |
| 147 | }; |
| 148 | }; |
Ziqi Chen | faceae2 | 2018-03-07 10:08:51 +0800 | [diff] [blame] | 149 | |
| 150 | &sdhc_2 { |
| 151 | cd-gpios = <&tlmm 133 0x0>; |
| 152 | }; |
Teng Fei Fan | bff8b94 | 2018-04-10 08:55:45 +0800 | [diff] [blame] | 153 | |
| 154 | &pmi632_vadc { |
| 155 | chan@4a { |
| 156 | qcom,scale-function = <22>; |
| 157 | }; |
| 158 | }; |
| 159 | |
| 160 | &soc { |
| 161 | gpio_keys { |
| 162 | camera_focus { |
| 163 | label = "camera_focus"; |
| 164 | gpios = <&tlmm 87 0x1>; |
| 165 | linux,input-type = <1>; |
| 166 | linux,code = <0x210>; |
| 167 | debounce-interval = <15>; |
| 168 | }; |
| 169 | |
| 170 | camera_snapshot { |
| 171 | label = "camera_snapshot"; |
| 172 | gpios = <&tlmm 86 0x1>; |
| 173 | linux,input-type = <1>; |
| 174 | linux,code = <0x2fe>; |
| 175 | debounce-interval = <15>; |
| 176 | }; |
| 177 | }; |
| 178 | }; |
| 179 | |
Ashay Jaiswal | cc0c423 | 2018-05-21 15:37:53 +0530 | [diff] [blame] | 180 | &i2c_2 { |
| 181 | #include "smb1355.dtsi" |
| 182 | }; |
| 183 | |
| 184 | &pmi632_gpios { |
| 185 | smb_en { |
| 186 | smb_en_default: smb_en_default { |
| 187 | pins = "gpio2"; |
| 188 | function = "func1"; |
| 189 | output-enable; |
| 190 | }; |
| 191 | }; |
Anirudh Ghayal | ca13a0c | 2018-05-28 11:44:26 +0530 | [diff] [blame] | 192 | |
| 193 | pmi632_sense { |
| 194 | /* GPIO 7 and 8 are external-sense pins for PMI632 */ |
| 195 | pmi632_sense_default: pmi632_sense_default { |
| 196 | pins = "gpio7", "gpio8"; |
| 197 | bias-high-impedance; /* disable the GPIO */ |
| 198 | bias-disable; /* no-pull */ |
| 199 | }; |
| 200 | }; |
Ashay Jaiswal | 76150b4 | 2018-06-26 14:37:12 +0530 | [diff] [blame] | 201 | |
| 202 | pmi632_ctm { |
| 203 | /* Disable GPIO1 for h/w base mitigation */ |
| 204 | pmi632_ctm_default: pmi632_ctm_default { |
| 205 | pins = "gpio1"; |
| 206 | bias-high-impedance; /* disable the GPIO */ |
| 207 | bias-disable; /* no-pull */ |
| 208 | }; |
| 209 | }; |
Ashay Jaiswal | cc0c423 | 2018-05-21 15:37:53 +0530 | [diff] [blame] | 210 | }; |
| 211 | |
| 212 | &tlmm { |
| 213 | smb_int_default: smb_int_default { |
| 214 | mux { |
| 215 | pins = "gpio59"; |
| 216 | function = "gpio"; |
| 217 | }; |
| 218 | config { |
| 219 | pins = "gpio59"; |
| 220 | drive-strength = <2>; |
| 221 | bias-pull-up; |
| 222 | input-enable; |
| 223 | }; |
| 224 | }; |
| 225 | }; |
| 226 | |
| 227 | &smb1355_0 { |
| 228 | pinctrl-names = "default"; |
| 229 | pinctrl-0 = <&smb_int_default |
Ashay Jaiswal | 15d3c8f | 2018-06-14 21:27:45 +0530 | [diff] [blame] | 230 | &smb_en_default &pmi632_sense_default &pmi632_ctm_default>; |
Ashay Jaiswal | cc0c423 | 2018-05-21 15:37:53 +0530 | [diff] [blame] | 231 | interrupt-parent = <&tlmm>; |
| 232 | interrupts = <59 IRQ_TYPE_LEVEL_LOW>; |
| 233 | smb1355_charger_0: qcom,smb1355-charger@1000 { |
| 234 | status ="ok"; |
| 235 | /delete-property/ io-channels; |
| 236 | /delete-property/ io-channels-names; |
| 237 | qcom,parallel-mode = <1>; |
Ashay Jaiswal | 15d3c8f | 2018-06-14 21:27:45 +0530 | [diff] [blame] | 238 | qcom,disable-ctm; |
| 239 | qcom,hw-die-temp-mitigation; |
Ashay Jaiswal | cc0c423 | 2018-05-21 15:37:53 +0530 | [diff] [blame] | 240 | }; |
| 241 | }; |
| 242 | |
| 243 | &smb1355_1 { |
| 244 | pinctrl-names = "default"; |
| 245 | pinctrl-0 = <&smb_int_default |
Ashay Jaiswal | 15d3c8f | 2018-06-14 21:27:45 +0530 | [diff] [blame] | 246 | &smb_en_default &pmi632_sense_default &pmi632_ctm_default>; |
Ashay Jaiswal | cc0c423 | 2018-05-21 15:37:53 +0530 | [diff] [blame] | 247 | interrupt-parent = <&tlmm>; |
| 248 | interrupts = <59 IRQ_TYPE_LEVEL_LOW>; |
| 249 | smb1355_charger_1: qcom,smb1355-charger@1000 { |
| 250 | status ="ok"; |
| 251 | /delete-property/ io-channels; |
| 252 | /delete-property/ io-channels-names; |
| 253 | qcom,parallel-mode = <1>; |
Ashay Jaiswal | 15d3c8f | 2018-06-14 21:27:45 +0530 | [diff] [blame] | 254 | qcom,disable-ctm; |
| 255 | qcom,hw-die-temp-mitigation; |
Ashay Jaiswal | cc0c423 | 2018-05-21 15:37:53 +0530 | [diff] [blame] | 256 | }; |
| 257 | }; |
Fenglin Wu | 7842ea3 | 2018-07-11 14:49:06 +0800 | [diff] [blame] | 258 | |
| 259 | &pmi632_charger { |
| 260 | qcom,thermal-mitigation = <4200000 3500000 3000000 2500000 |
| 261 | 2000000 1500000 1000000 500000>; |
| 262 | }; |