Maria Yu | 6451c37 | 2017-09-28 17:04:28 +0800 | [diff] [blame] | 1 | /* |
Tengfei Fan | 715a415 | 2019-04-12 11:41:47 +0800 | [diff] [blame] | 2 | * Copyright (c) 2015-2019, The Linux Foundation. All rights reserved. |
Maria Yu | 6451c37 | 2017-09-28 17:04:28 +0800 | [diff] [blame] | 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 | |
Srinivas Ramana | c2dd378 | 2018-02-23 18:21:53 +0530 | [diff] [blame] | 14 | #include <dt-bindings/gpio/gpio.h> |
| 15 | #include <dt-bindings/clock/msm-clocks-8953.h> |
Soumya Managoli | 91ec950 | 2018-01-18 16:53:47 +0530 | [diff] [blame] | 16 | #include "msm8953-audio-cdp.dtsi" |
Vijay kumar Tumati | 408b096 | 2018-03-16 17:28:31 +0530 | [diff] [blame] | 17 | #include "msm8953-camera-sensor-cdp.dtsi" |
Soumya Managoli | 91ec950 | 2018-01-18 16:53:47 +0530 | [diff] [blame] | 18 | |
Maria Yu | 6451c37 | 2017-09-28 17:04:28 +0800 | [diff] [blame] | 19 | &blsp1_uart0 { |
| 20 | status = "ok"; |
| 21 | pinctrl-names = "default"; |
| 22 | pinctrl-0 = <&uart_console_active>; |
| 23 | }; |
Sayali Lokhande | 3129993 | 2017-12-06 09:41:17 +0530 | [diff] [blame] | 24 | |
Rohit Rangwani | 7e9dc74 | 2018-01-18 17:26:19 +0530 | [diff] [blame] | 25 | &pm8953_gpios { |
| 26 | nfc_clk { |
| 27 | nfc_clk_default: nfc_clk_default { |
| 28 | pins = "gpio2"; |
| 29 | function = "normal"; |
| 30 | input-enable; |
| 31 | power-source = <1>; |
| 32 | }; |
| 33 | }; |
| 34 | }; |
| 35 | |
| 36 | &i2c_5 { /* BLSP2 QUP1 (NFC) */ |
Tengfei Fan | 715a415 | 2019-04-12 11:41:47 +0800 | [diff] [blame] | 37 | #address-cells = <1>; |
| 38 | #size-cells = <0>; |
| 39 | |
Rohit Rangwani | 7e9dc74 | 2018-01-18 17:26:19 +0530 | [diff] [blame] | 40 | status = "ok"; |
| 41 | nq@28 { |
| 42 | compatible = "qcom,nq-nci"; |
| 43 | reg = <0x28>; |
| 44 | qcom,nq-irq = <&tlmm 17 0x00>; |
| 45 | qcom,nq-ven = <&tlmm 16 0x00>; |
| 46 | qcom,nq-firm = <&tlmm 62 0x00>; |
| 47 | qcom,nq-clkreq = <&pm8953_gpios 2 0x00>; |
c_pbembr | f65da36 | 2018-03-28 18:50:16 +0530 | [diff] [blame] | 48 | qcom,nq-esepwr = <&tlmm 141 0x00>; |
Rohit Rangwani | 7e9dc74 | 2018-01-18 17:26:19 +0530 | [diff] [blame] | 49 | interrupt-parent = <&tlmm>; |
| 50 | qcom,clk-src = "BBCLK2"; |
| 51 | interrupts = <17 0>; |
| 52 | interrupt-names = "nfc_irq"; |
| 53 | pinctrl-names = "nfc_active", "nfc_suspend"; |
| 54 | pinctrl-0 = <&nfc_int_active &nfc_disable_active |
| 55 | &nfc_clk_default>; |
| 56 | pinctrl-1 = <&nfc_int_suspend &nfc_disable_suspend>; |
| 57 | clocks = <&clock_gcc clk_bb_clk2_pin>; |
| 58 | clock-names = "ref_clk"; |
| 59 | }; |
| 60 | }; |
| 61 | |
Sayali Lokhande | 3129993 | 2017-12-06 09:41:17 +0530 | [diff] [blame] | 62 | &sdhc_1 { |
| 63 | /* device core power supply */ |
| 64 | vdd-supply = <&pm8953_l8>; |
| 65 | qcom,vdd-voltage-level = <2900000 2900000>; |
| 66 | qcom,vdd-current-level = <200 570000>; |
| 67 | |
| 68 | /* device communication power supply */ |
| 69 | vdd-io-supply = <&pm8953_l5>; |
| 70 | qcom,vdd-io-always-on; |
| 71 | qcom,vdd-io-lpm-sup; |
| 72 | qcom,vdd-io-voltage-level = <1800000 1800000>; |
| 73 | qcom,vdd-io-current-level = <200 325000>; |
| 74 | |
| 75 | pinctrl-names = "active", "sleep"; |
| 76 | pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on &sdc1_rclk_on>; |
| 77 | pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off &sdc1_rclk_off>; |
| 78 | |
| 79 | qcom,clk-rates = <400000 20000000 25000000 50000000 100000000 192000000 |
| 80 | 384000000>; |
| 81 | qcom,nonremovable; |
| 82 | qcom,bus-speed-mode = "HS400_1p8v", "HS200_1p8v", "DDR_1p8v"; |
| 83 | |
| 84 | status = "ok"; |
| 85 | }; |
| 86 | |
| 87 | &sdhc_2 { |
| 88 | /* device core power supply */ |
| 89 | vdd-supply = <&pm8953_l11>; |
| 90 | qcom,vdd-voltage-level = <2950000 2950000>; |
| 91 | qcom,vdd-current-level = <15000 800000>; |
| 92 | |
| 93 | /* device communication power supply */ |
| 94 | vdd-io-supply = <&pm8953_l12>; |
| 95 | qcom,vdd-io-voltage-level = <1800000 2950000>; |
| 96 | qcom,vdd-io-current-level = <200 22000>; |
| 97 | |
| 98 | pinctrl-names = "active", "sleep"; |
| 99 | pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on &sdc2_cd_on>; |
| 100 | pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off>; |
| 101 | |
| 102 | #address-cells = <0>; |
| 103 | interrupt-parent = <&sdhc_2>; |
| 104 | interrupts = <0 1 2>; |
| 105 | #interrupt-cells = <1>; |
| 106 | interrupt-map-mask = <0xffffffff>; |
| 107 | interrupt-map = <0 &intc 0 125 0 |
| 108 | 1 &intc 0 221 0 |
| 109 | 2 &tlmm 133 0>; |
| 110 | interrupt-names = "hc_irq", "pwr_irq", "status_irq"; |
| 111 | cd-gpios = <&tlmm 133 0x1>; |
| 112 | |
| 113 | qcom,clk-rates = <400000 20000000 25000000 50000000 100000000 |
| 114 | 200000000>; |
| 115 | qcom,bus-speed-mode = "SDR12", "SDR25", "SDR50", "DDR50", "SDR104"; |
| 116 | |
| 117 | status = "ok"; |
| 118 | }; |
Sachin Bhayare | e25c1f0 | 2018-01-16 14:04:54 +0530 | [diff] [blame] | 119 | |
| 120 | #include "msm8953-mdss-panels.dtsi" |
| 121 | |
| 122 | &mdss_mdp { |
| 123 | qcom,mdss-pref-prim-intf = "dsi"; |
| 124 | }; |
| 125 | |
| 126 | &mdss_dsi { |
| 127 | hw-config = "single_dsi"; |
| 128 | }; |
| 129 | |
| 130 | &mdss_dsi0 { |
| 131 | qcom,dsi-pref-prim-pan = <&dsi_truly_1080_vid>; |
| 132 | pinctrl-names = "mdss_default", "mdss_sleep"; |
| 133 | pinctrl-0 = <&mdss_dsi_active &mdss_te_active>; |
| 134 | pinctrl-1 = <&mdss_dsi_suspend &mdss_te_suspend>; |
| 135 | |
| 136 | qcom,platform-te-gpio = <&tlmm 24 0>; |
| 137 | qcom,platform-reset-gpio = <&tlmm 61 0>; |
| 138 | qcom,platform-bklight-en-gpio = <&tlmm 59 0>; |
| 139 | }; |
| 140 | |
| 141 | &mdss_dsi1 { |
| 142 | status = "disabled"; |
| 143 | qcom,dsi-pref-prim-pan = <&dsi_adv7533_1080p>; |
| 144 | pinctrl-names = "mdss_default", "mdss_sleep"; |
| 145 | pinctrl-0 = <&mdss_dsi_active &mdss_te_active>; |
| 146 | pinctrl-1 = <&mdss_dsi_suspend &mdss_te_suspend>; |
| 147 | |
| 148 | qcom,pluggable; |
| 149 | qcom,platform-te-gpio = <&tlmm 24 0>; |
| 150 | qcom,platform-reset-gpio = <&tlmm 61 0>; |
| 151 | qcom,platform-bklight-en-gpio = <&tlmm 59 0>; |
| 152 | }; |
| 153 | |
| 154 | &dsi_truly_1080_vid { |
| 155 | qcom,panel-supply-entries = <&dsi_panel_pwr_supply>; |
| 156 | qcom,mdss-dsi-pan-enable-dynamic-fps; |
raghavendra ambadas | 161e9b4 | 2018-10-04 11:17:01 +0530 | [diff] [blame] | 157 | qcom,mdss-dsi-min-refresh-rate = <48>; |
| 158 | qcom,mdss-dsi-max-refresh-rate = <60>; |
Sachin Bhayare | e25c1f0 | 2018-01-16 14:04:54 +0530 | [diff] [blame] | 159 | qcom,mdss-dsi-pan-fps-update = "dfps_immediate_porch_mode_vfp"; |
| 160 | }; |
| 161 | |
Vishnuvardhan Prodduturi | 886d44e | 2018-01-25 18:29:43 +0530 | [diff] [blame] | 162 | &dsi_hx8399c_truly_vid { |
| 163 | qcom,panel-supply-entries = <&dsi_panel_pwr_supply>; |
| 164 | qcom,mdss-dsi-pan-enable-dynamic-fps; |
| 165 | qcom,mdss-dsi-pan-fps-update = "dfps_immediate_porch_mode_vfp"; |
| 166 | }; |
| 167 | |
Sachin Bhayare | e25c1f0 | 2018-01-16 14:04:54 +0530 | [diff] [blame] | 168 | &dsi_truly_1080_cmd { |
| 169 | qcom,panel-supply-entries = <&dsi_panel_pwr_supply>; |
| 170 | qcom,ulps-enabled; |
| 171 | qcom,partial-update-enabled; |
| 172 | qcom,panel-roi-alignment = <2 2 4 2 1080 2>; |
| 173 | }; |
| 174 | |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 175 | &soc { |
| 176 | gpio_keys { |
| 177 | compatible = "gpio-keys"; |
| 178 | input-name = "gpio-keys"; |
Shantanu Jain | a929527 | 2018-03-16 16:21:14 +0530 | [diff] [blame] | 179 | pinctrl-names = "default"; |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 180 | pinctrl-0 = <&gpio_key_active>; |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 181 | |
| 182 | camera_focus { |
| 183 | label = "camera_focus"; |
| 184 | gpios = <&tlmm 87 0x1>; |
| 185 | linux,input-type = <1>; |
| 186 | linux,code = <0x210>; |
| 187 | debounce-interval = <15>; |
Shantanu Jain | a929527 | 2018-03-16 16:21:14 +0530 | [diff] [blame] | 188 | linux,can-disable; |
| 189 | gpio-key,wakeup; |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 190 | }; |
| 191 | |
| 192 | camera_snapshot { |
| 193 | label = "camera_snapshot"; |
| 194 | gpios = <&tlmm 86 0x1>; |
| 195 | linux,input-type = <1>; |
| 196 | linux,code = <0x2fe>; |
| 197 | debounce-interval = <15>; |
Shantanu Jain | a929527 | 2018-03-16 16:21:14 +0530 | [diff] [blame] | 198 | linux,can-disable; |
| 199 | gpio-key,wakeup; |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 200 | }; |
| 201 | |
| 202 | vol_up { |
| 203 | label = "volume_up"; |
| 204 | gpios = <&tlmm 85 0x1>; |
| 205 | linux,input-type = <1>; |
| 206 | linux,code = <115>; |
| 207 | debounce-interval = <15>; |
Shantanu Jain | a929527 | 2018-03-16 16:21:14 +0530 | [diff] [blame] | 208 | linux,can-disable; |
| 209 | gpio-key,wakeup; |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 210 | }; |
| 211 | |
| 212 | home { |
| 213 | label = "home"; |
| 214 | gpios = <&tlmm 88 0x1>; |
| 215 | linux,input-type = <1>; |
| 216 | linux,code = <102>; |
| 217 | debounce-interval = <15>; |
Shantanu Jain | a929527 | 2018-03-16 16:21:14 +0530 | [diff] [blame] | 218 | linux,can-disable; |
| 219 | gpio-key,wakeup; |
Shantanu Jain | 6cb0cbb | 2018-02-15 18:20:03 +0530 | [diff] [blame] | 220 | }; |
| 221 | }; |
| 222 | }; |
| 223 | |
| 224 | &tlmm { |
| 225 | tlmm_gpio_key { |
| 226 | gpio_key_active: gpio_key_active { |
| 227 | mux { |
| 228 | pins = "gpio85", "gpio86", "gpio87", "gpio88"; |
| 229 | function = "gpio"; |
| 230 | }; |
| 231 | |
| 232 | config { |
| 233 | pins = "gpio85", "gpio86", "gpio87", "gpio88"; |
| 234 | }; |
| 235 | }; |
| 236 | |
| 237 | gpio_key_suspend: gpio_key_suspend { |
| 238 | mux { |
| 239 | pins = "gpio85", "gpio86", "gpio87", "gpio88"; |
| 240 | function = "gpio"; |
| 241 | }; |
| 242 | |
| 243 | config { |
| 244 | pins = "gpio85", "gpio86", "gpio87", "gpio88"; |
| 245 | }; |
| 246 | }; |
| 247 | }; |
| 248 | }; |
| 249 | |