From a516b4a60d24faf86552a2980ccb9e158d416931 Mon Sep 17 00:00:00 2001 From: Giovanni Ricca Date: Thu, 13 Oct 2022 20:12:34 +0200 Subject: [PATCH] arm64: dts: Import xiaomi-sm7325-common Change-Id: I10cc4aaa1b943e1eb84cc233b9188f7bb565742b --- .../dts/vendor/qcom/xiaomi-sm7325-common.dtsi | 456 ++++++++++ .../qcom/xiaomi-sm7325-pm7250b-common.dtsi | 813 ++++++++++++++++++ 2 files changed, 1269 insertions(+) create mode 100644 arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-common.dtsi create mode 100644 arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-pm7250b-common.dtsi diff --git a/arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-common.dtsi b/arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-common.dtsi new file mode 100644 index 000000000000..d2f5a31909f8 --- /dev/null +++ b/arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-common.dtsi @@ -0,0 +1,456 @@ +#include +#include +#include +#include +#include "yupik-pmic-overlay.dtsi" +#include "pm7325b.dtsi" +#include "yupik-thermal-overlay.dtsi" +#include "display/yupik-sde-display-idp.dtsi" + +&soc { + gpio_keys { + compatible = "gpio-keys"; + label = "gpio-keys"; + + pinctrl-names = "default"; + pinctrl-0 = <&key_vol_up_default>; + + vol_up { + label = "volume_up"; + gpios = <&pm7325_gpios 6 GPIO_ACTIVE_LOW>; + linux,input-type = <1>; + linux,code = ; + gpio-key,wakeup; + debounce-interval = <15>; + linux,can-disable; + }; + }; + + thermal_message: thermal-message { + board-sensor = "VIRTUAL-SENSOR"; + }; + + xiaomi_touch { + compatible = "xiaomi-touch"; + status = "ok"; + touch,name = "xiaomi-touch"; + }; +}; + +&qupv3_se9_i2c { + status = "ok"; + qcom,clk-freq-out = <1000000>; + #address-cells = <1>; + #size-cells = <0>; + nq@28 { + compatible = "qcom,sn-nci"; + reg = <0x28>; + qcom,sn-irq = <&tlmm 41 0x00>; + qcom,sn-ven = <&tlmm 38 0x00>; + qcom,sn-firm = <&tlmm 40 0x00>; + qcom,sn-clkreq = <&tlmm 39 0x00>; + interrupt-parent = <&tlmm>; + interrupts = <41 0>; + interrupt-names = "nfc_irq"; + pinctrl-names = "nfc_active", "nfc_suspend"; + pinctrl-0 = <&nfc_int_active &nfc_enable_active>; + pinctrl-1 = <&nfc_int_suspend &nfc_enable_suspend>; + }; +}; + +&ufsphy_mem { + compatible = "qcom,ufs-phy-qmp-v4-yupik"; + + vdda-phy-supply = <&L10C>; + vdda-pll-supply = <&L6B>; + vdda-phy-max-microamp = <97500>; + vdda-pll-max-microamp = <18400>; + + status = "ok"; +}; + +&ufshc_mem { + vdd-hba-supply = <&gcc_ufs_phy_gdsc>; + vdd-hba-fixed-regulator; + + vcc-supply = <&L7B>; + vcc-voltage-level = <2504000 2952000>; + vcc-low-voltage-sup; + vcc-max-microamp = <800000>; + + /* + * Yupik target supports both UFS2.2 & UFS3.1, here + * vccq2 is supplied via eLDO, and that is controlled via + * L9B which supports a max voltage of 1.2V, but eLDO would + * supply 1.8V. and same L9B acts as vccq voltage for UFS3.1 + * devices. + * Here L9B can max support for 1.2V but UFS GKI driver code + * votes for 1.8V, which is leading to failure from pmic + * regulator. + * + * Now since vccq and control of eLDO are common that is L9B + * we can use vccq vote as control of eLDO for vccq2. + * Hence vccq entries shall be used for both type of UFS + * devices only. And vccq entries should not be changed/removed + * for any design alteration. + */ + vccq-supply = <&L9B>; + vccq-max-microamp = <900000>; + vccq-min-microamp = <10000>; + + qcom,vddp-ref-clk-supply = <&L9B>; + qcom,vddp-ref-clk-max-microamp = <100>; + + status = "ok"; +}; + +&pmk8350_vadc { + pm7325b_ref_gnd { + reg = ; + label = "pm7325b_ref_gnd"; + qcom,pre-scaling = <1 1>; + }; + + pm7325b_vref_1p25 { + reg = ; + label = "pm7325b_vref_1p25"; + qcom,pre-scaling = <1 1>; + }; + + pm7325b_die_temp { + reg = ; + label = "pm7325b_die_temp"; + qcom,pre-scaling = <1 1>; + }; + + pm7325b_vph_pwr { + reg = ; + label = "pm7325b_vph_pwr"; + qcom,pre-scaling = <1 3>; + }; + + pm7325b_vbat_sns { + reg = ; + label = "pm7325b_vbat_sns"; + qcom,pre-scaling = <1 3>; + }; + + pm7325b_usb_conn_therm { + reg = ; + label = "pm7325b_usb_conn_therm"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + + pm7325b_chg_skin_therm { + reg = ; + label = "pm7325b_chg_skin_therm"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + + pm7325b_chg_temp { + reg = ; + label = "pm7325b_chg_temp"; + qcom,pre-scaling = <1 1>; + }; + + pm7325b_iin_fb { + reg = ; + label = "pm7325b_iin_fb"; + qcom,pre-scaling = <32 100>; + }; + + pm7325b_ichg_fb { + reg = ; + label = "pm7325b_ichg_fb"; + qcom,pre-scaling = <1000 305185>; + }; + + smb139x_1_smb_temp { + reg = ; + label = "smb139x_1_smb_temp"; + qcom,pre-scaling = <1 1>; + }; + + smb139x_2_smb_temp { + reg = ; + label = "smb139x_2_smb_temp"; + qcom,pre-scaling = <1 1>; + }; + + smb139x_1_iin_smb { + reg = ; + label = "smb139x_1_iin_smb"; + qcom,pre-scaling = <32 100>; + }; + + smb139x_2_iin_smb { + reg = ; + label = "smb139x_2_iin_smb"; + qcom,pre-scaling = <32 100>; + }; + + smb139x_1_ichg_smb { + reg = ; + label = "smb139x_1_ichg_smb"; + qcom,pre-scaling = <16 100>; + }; + + smb139x_1_ichg_smb_pt { + reg = ; + label = "smb139x_1_ichg_smb_pt"; + qcom,pre-scaling = <32 100>; + }; + + smb139x_2_ichg_smb { + reg = ; + label = "smb139x_2_ichg_smb"; + qcom,pre-scaling = <16 100>; + }; + + smb139x_2_ichg_smb_pt { + reg = ; + label = "smb139x_2_ichg_smb_pt"; + qcom,pre-scaling = <32 100>; + }; + +}; + +&pmk8350_adc_tm { + io-channels = <&pmk8350_vadc PM7325_ADC7_AMUX_THM1_100K_PU>, + <&pmk8350_vadc PM7325_ADC7_AMUX_THM2_100K_PU>, + <&pmk8350_vadc PM7325_ADC7_AMUX_THM3_100K_PU>, + <&pmk8350_vadc PM7325_ADC7_AMUX_THM4_100K_PU>, + <&pmk8350_vadc PMK8350_ADC7_AMUX_THM1_100K_PU>, + <&pmk8350_vadc PM7325B_ADC7_GPIO2_100K_PU>; + + pm7325b_chg_skin_therm { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; +}; + +&thermal_zones { + charger_therm0 { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-governor = "user_space"; + thermal-sensors = <&pmk8350_adc_tm PM7325B_ADC7_GPIO2_100K_PU>; + wake-capable-sensor; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; +}; + +&apps_rsc { + rpmh-regulator-ldod1 { + compatible = "qcom,rpmh-vrm-regulator"; + qcom,resource-name = "ldod1"; + qcom,regulator-type = "pmic5-ldo"; + qcom,supported-modes = + ; + qcom,mode-threshold-currents = <0 30000>; + L1D: + pm8350b_l1: regulator-pm8350b-l1 { + regulator-name = "pm8350b_l1"; + qcom,set = ; + regulator-min-microvolt = <1100000>; + regulator-max-microvolt = <1300000>; + qcom,init-voltage = <1200000>; + qcom,init-mode = ; + }; + }; +}; + +&pm8350c_l12 { + qcom,init-voltage = <1800000>; +}; + +&pm7325b_wled { + qcom,string-cfg = <3>; + qcom,leds-per-string = <8>; + qcom,fs-current-limit = <22500>; + qcom,slew-ramp-time = <256>; + + qcom,exp-dimming-map = < + 0x1A 0x1B 0x1C 0x1D 0x1E 0x1E 0x1F 0x20 + 0x21 0x22 0x23 0x24 0x25 0x26 0x27 0x28 + 0x29 0x2A 0x2C 0x2D 0x2E 0x30 0x31 0x32 + 0x34 0x35 0x37 0x38 0x3A 0x3B 0x3D 0x3F + 0x41 0x42 0x44 0x46 0x48 0x4A 0x4C 0x4F + 0x51 0x53 0x55 0x58 0x5A 0x5D 0x60 0x62 + 0x65 0x68 0x6B 0x6E 0x71 0x74 0x77 0x7B + 0x7E 0x82 0x86 0x89 0x8D 0x91 0x95 0x9A + 0x9E 0xA2 0xA7 0xAC 0xB1 0xB6 0xBB 0xC0 + 0xC5 0xCB 0xD1 0xD7 0xDD 0xE3 0xE9 0xF0 + 0xF7 0xFE 0x105 0x10C 0x114 0x11C 0x124 0x12C + 0x135 0x13D 0x146 0x150 0x159 0x163 0x16D 0x177 + 0x182 0x18D 0x198 0x1A4 0x1B0 0x1BC 0x1C8 0x1D5 + 0x1E3 0x1F0 0x1FE 0x20D 0x21C 0x22B 0x23B 0x24B + 0x25C 0x26D 0x27E 0x290 0x2A3 0x2B6 0x2CA 0x2DE + 0x2F3 0x308 0x31E 0x335 0x34C 0x364 0x37C 0x396 + 0x3B0 0x3CA 0x3E6 0x402 0x41F 0x43D 0x45C 0x47B + 0x49C 0x4BD 0x4E0 0x503 0x527 0x54D 0x573 0x59B + 0x5C3 0x5ED 0x618 0x644 0x672 0x6A0 0x6D0 0x702 + 0x735 0x769 0x79F 0x7D6 0x80F 0x849 0x885 0x8C3 + 0x903 0x944 0x987 0x9CC 0xA13 0xA5C 0xAA8 0xAF5 + 0xB44 0xB96 0xBEA 0xC40 0xC99 0xCF5 0xD52 0xDB3 + 0xE16 0xE7D 0xEE6 0xF52 0xFC1 0x1033 0x10A8 0x1121 + 0x119D 0x121D 0x12A1 0x1328 0x13B3 0x1441 0x14D4 0x156B + 0x1607 0x16A6 0x174B 0x17F4 0x18A1 0x1954 0x1A0B 0x1AC8 + 0x1B8B 0x1C52 0x1D20 0x1DF3 0x1ECC 0x1FAB 0x2091 0x217D + 0x2270 0x236A 0x246B 0x2573 0x2682 0x2799 0x28B9 0x29E0 + 0x2B10 0x2C48 0x2D89 0x2ED3 0x3027 0x3184 0x32EB 0x345C + 0x35D8 0x375E 0x38F0 0x3A8D 0x3C35 0x3DEA 0x3FAB 0x4179 + 0x4353 0x453C 0x4732 0x4936 0x4B49 0x4D6B 0x4F9C 0x51DD + 0x542F 0x5692 0x5905 0x5B8B 0x5E23 0x60CD 0x638B 0x665D + 0x6944 0x6C3F 0x6F50 0x7277 0x75B5 0x790B 0x7C78 0x7FFF + >; +}; + +&spmi_debug_bus { + status = "ok"; +}; + +&spmi_glink_debug { + status = "ok"; +}; + +&pm8350c_switch0 { + qcom,led-mask = <9>; /* Channels 1 & 4 */ + qcom,symmetry-en; +}; + +&pm8350c_switch1 { + qcom,led-mask = <6>; /* Channels 2 & 3 */ + qcom,symmetry-en; +}; + +&pm8350c_switch2 { + qcom,led-mask = <15>; /* All Channels */ + qcom,symmetry-en; +}; + +&pm8350c_flash { + status = "ok"; +}; + +&battery_charger { + qcom,thermal-mitigation = <10000000 9500000 9000000 8500000 8000000 + 7500000 7000000 6500000 6000000 5500000 + 5000000 4500000 4000000 3500000 3000000 + 2500000 2000000 1500000 1000000 500000>; +}; + +&pm7325b_tz { + io-channels = <&pmk8350_vadc PM7325B_ADC7_DIE_TEMP>; + io-channel-names = "thermal"; +}; + + +&sdhc_1 { + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc1_on>; + pinctrl-1 = <&sdc1_off>; + + vdd-supply = <&L7B>; + qcom,vdd-voltage-level = <2952000 2952000>; + qcom,vdd-current-level = <0 570000>; + + vdd-io-supply = <&L19B>; + qcom,vdd-io-always-on; + qcom,vdd-io-lpm-sup; + qcom,vdd-io-voltage-level = <1800000 1800000>; + qcom,vdd-io-current-level = <0 325000>; + + status = "ok"; +}; + +&sdhc_2 { + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc2_on>; + pinctrl-1 = <&sdc2_off>; + + vdd-supply = <&L9C>; + qcom,vdd-voltage-level = <2960000 2960000>; + qcom,vdd-current-level = <0 800000>; + + vdd-io-supply = <&L6C>; + qcom,vdd-io-voltage-level = <1800000 2960000>; + qcom,vdd-io-current-level = <0 22000>; + + cd-gpios = <&tlmm 91 GPIO_ACTIVE_HIGH>; + + status = "ok"; +}; + +&qupv3_se13_i2c { + status = "disabled"; +}; + +&qupv3_se13_spi { + /* + status = "ok"; + qcom,spi-touch-active = "focaltech,fts_ts"; + + focaltech@0 { + compatible = "focaltech,fts_ts"; + reg = <0x0>; + spi-max-frequency = <6000000>; + interrupt-parent = <&tlmm>; + interrupts = <81 0x2008>; + focaltech,reset-gpio = <&tlmm 105 0x00>; + focaltech,irq-gpio = <&tlmm 81 0x2008>; + focaltech,display-coords = <0 0 1080 2340>; + focaltech,max-touch-number = <5>; + focaltech,ic-type = <0x3658D488>; + + vdd-supply = <&L3C>; + + pinctrl-names = "pmx_ts_active", "pmx_ts_suspend","pmx_ts_release"; + pinctrl-0 = <&ts_active>; + pinctrl-1 = <&ts_int_suspend &ts_reset_suspend>; + pinctrl-2 = <&ts_release>; + panel = <&dsi_r66451_amoled_144hz_cmd_cphy &dsi_r66451_amoled_120hz_cmd_cphy + &dsi_r66451_amoled_90hz_cmd_cphy &dsi_r66451_amoled_60hz_cmd_cphy>; + };*/ + +}; + +&pmk8350 { + pon_hlos@1300 { + interrupts = <0x0 0x13 0x7 IRQ_TYPE_EDGE_BOTH>, + <0x0 0x13 0x6 IRQ_TYPE_EDGE_BOTH>, + <0x0 0x13 0x0 IRQ_TYPE_EDGE_BOTH>, + <0x0 0x13 0x2 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "kpdpwr", "resin", "kpdpwr-bark", + "kpdpwr-resin-bark"; + qcom,pon-dbc-delay = <15625>; + qcom,kpdpwr-sw-debounce; + qcom,pon_1 { + qcom,pon-type = ; + qcom,pull-up; + qcom,use-bark = <1>; + qcom,support-reset = <1>; + linux,code = ; + qcom,s1-timer = <6720>; + qcom,s2-timer = <2000>; + qcom,s2-type = ; + }; + }; +}; + +&usb2_phy0 { + qcom,param-override-seq = <0x0f 0x70 + 0x2c 0x74>; +}; diff --git a/arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-pm7250b-common.dtsi b/arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-pm7250b-common.dtsi new file mode 100644 index 000000000000..0657c764b048 --- /dev/null +++ b/arch/arm64/boot/dts/vendor/qcom/xiaomi-sm7325-pm7250b-common.dtsi @@ -0,0 +1,813 @@ +#include +#include +#include +#include "yupik-pmic-overlay.dtsi" +#include "pm7250b.dtsi" +#include "yupik-pm7250b-thermal-overlay.dtsi" +#include "display/yupik-sde-display-idp-pm7250b.dtsi" + +/ { + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2e>; + qcom,pmic-id-size = <9>; +}; + +&soc { + gpio_keys { + compatible = "gpio-keys"; + label = "gpio-keys"; + + pinctrl-names = "default"; + pinctrl-0 = <&key_vol_up_default>; + + vol_up { + label = "volume_up"; + gpios = <&pm7325_gpios 6 GPIO_ACTIVE_LOW>; + linux,input-type = <1>; + linux,code = ; + gpio-key,wakeup; + debounce-interval = <15>; + linux,can-disable; + }; + }; + xiaomi_touch { + compatible = "xiaomi-touch"; + status = "ok"; + touch,name = "xiaomi-touch"; + }; + fingerprint_goodix { + compatible = "goodix,fingerprint"; + l11c_vdd-supply = <&L3C>; + goodix,gpio-reset = <&tlmm 43 0x0>; + goodix,gpio-irq = <&tlmm 34 0x0>; + status = "ok"; + }; + + thermal_message: thermal-message { + board-sensor = "VIRTUAL-SENSOR"; + }; +}; + +&L3C { + regulator-boot-on; + regulator-always-on; + regulator-min-microvolt = <3200000>; + regulator-max-microvolt = <3200000>; + qcom,init-voltage = <3200000>; +}; + +&spmi_debug_bus { + qcom,pm8350b-debug@3 { + status = "disabled"; + }; + + qcom,pm7250b-debug@8 { + compatible = "qcom,spmi-pmic"; + reg = <8 SPMI_USID>; + #address-cells = <2>; + #size-cells = <0>; + qcom,can-sleep; + }; + + qcom,pm7250b-debug@9 { + compatible = "qcom,spmi-pmic"; + reg = <9 SPMI_USID>; + #address-cells = <2>; + #size-cells = <0>; + qcom,can-sleep; + }; +}; + +&spmi_glink_debug { + spmi@0 { + qcom,pm8350b-debug@3 { + status = "disabled"; + }; + + qcom,pm7250b-debug@8 { + compatible = "qcom,spmi-pmic"; + reg = <8 SPMI_USID>; + qcom,can-sleep; + }; + }; +}; + +&qupv3_se3_i2c { + status = "ok"; + /* TOP Speaker */ + tfa98xx@34 { + compatible = "nxp,tfa98xx"; + reset-gpio = <&tlmm 2 0>; + irq-gpio = <&tlmm 102 0>; + spk-sw-gpio = <&tlmm 101 0>; + interrupt-parent = <&tlmm>; + interrupts = <102 0>; + interrupt-names = "smartpa_irq"; + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&smartpa_top_int_active &smartpa_enable_top_active/* &spk_sw_active*/>; + pinctrl-1 = <&smartpa_top_int_suspend &smartpa_enable_top_suspend/* &spk_sw_inactive*/>; + reg = <0x34>; + status = "ok"; + }; + /* Botton Speaker */ + tfa98xx@35 { + compatible = "nxp,tfa98xx"; + reset-gpio = <&tlmm 6 0>; + irq-gpio = <&tlmm 45 0>; + //spk-sw-gpio = <&tlmm 110 0>; + interrupt-parent = <&tlmm>; + interrupts = <45 0>; + interrupt-names = "smartpa_irq"; + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&smartpa_bot_int_active>; + pinctrl-1 = <&smartpa_bot_int_suspend>; + reg = <0x35>; + status = "ok"; + }; +}; + +&qupv3_se9_i2c { + status = "ok"; + awinic_haptic@58 { + compatible = "awinic,awinic_haptic"; + reg = <0x5A>; + aw8622x_i2c_addr = < 0x58 >; + reset-gpio = <&tlmm 35 0>; + irq-gpio = <&tlmm 18 0>; + pinctrl-names = "awinic_reset_reset","awinic_reset_active","awinic_interrupt_active"; + pinctrl-0 = <&awinic_gpio_reset>; + pinctrl-1 = <&awinic_gpio_reset_output_high>; + pinctrl-2 = <&awinic_gpio_int>; + /*---------------------aw8624_dts_info---------------------*/ + aw8624_vib_f0_pre = < 2050 >; + aw8624_vib_f0_cali_percen = < 7 >; + aw8624_vib_cont_drv_lev = < 106 >; + aw8624_vib_cont_drv_lvl_ov = < 155 >; + aw8624_vib_cont_td = < 0xF06C >; + aw8624_vib_cont_zc_thr = < 0x08F8 >; + aw8624_vib_cont_num_brk = < 3 >; + aw8624_vib_f0_coeff = < 260 >; /*Don't modify it*/ + aw8624_vib_duration_time = < 15 60 0 0 0 >; + aw8624_vib_brake_ram_config = < 1 1 90 60 20 3 1 3 1 1 90 60 30 5 1 3 0 0 50 40 25 0 5 3 >; + aw8624_vib_brake_cont_config = < 1 1 90 42 20 5 2 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 >; + aw8624_vib_f0_trace_parameter = < 9 5 1 15 >; + aw8624_vib_bemf_config = < 0 8 3 0xf8 >; + aw8624_vib_sw_brake = < 0x2c >; + aw8624_vib_wavseq = < 0 1 1 2 0 0 0 0 0 0 0 0 0 0 0 0 >; /*wavseq1-seq8 0x07-0x0E*/ + aw8624_vib_wavloop = < 0 6 1 15 0 0 0 0 0 0>;/*loop1-mainloog 0x0f-0x13*/ + aw8624_vib_td_brake = < 42720 42720 42720 >; /*level0 level1 level2*/ + aw8624_vib_tset = < 0x11 >; + aw8624_vib_func_parameter1 = < 1 >; + aw8624_vib_gain_flag = < 1 >; + aw8624_vib_r_spare = < 0x68 >; + aw8624_vib_bstdbg = < 0x30 0xeb 0xd4 0 0 0 >; + /*---------------------aw8622x_dts_info---------------------*/ + aw8622x_vib_mode = < 0 >; /* mode: RAM mode->0; CONT mode->1 */ + aw8622x_vib_f0_pre = < 2050 >; + aw8622x_vib_f0_cali_percen = < 7 >; + aw8622x_vib_cont_drv1_lvl = < 0x7F >; + aw8622x_vib_cont_drv2_lvl = < 0x36 >; + aw8622x_vib_cont_brk_time = < 0x06 >; + aw8622x_vib_cont_tset = < 0x06 >; + aw8622x_vib_cont_bemf_set = < 0x02 >; + aw8622x_vib_cont_drv_width = < 0x6A >; + aw8622x_vib_cont_wait_num = < 0x06 >; + aw8622x_vib_cont_brk_gain = < 0x08 >; + aw8622x_vib_cont_drv1_time = < 0x04 >; + aw8622x_vib_cont_drv2_time = < 0x14 >; + aw8622x_vib_cont_track_margin = < 0x12 >; + aw8622x_vib_sine_array = < 0x05 0xB2 0xFF 0xEF >; /* SIN_H SIN_L COS_H COS_L*/ + aw8622x_vib_d2s_gain = < 0x05 >; + aw8622x_vib_prctmode = < 0x2D 0x3E 0x3F >; + /*---------------------common_dts_info---------------------*/ + vib_effect_id_boundary = < 10 >; + vib_effect_max = < 193 >; + vib_rtp_time = < 20 20 20 20 40 20 20 20 20 20 + 20 20 20 20 20 20 20 20 20 20 + 20 24058 11520 14770 40341 22060 16745 15166 10590 17260 + 16923 16000 9920 14420 12000 18000 7860 19400 12600 31992 + 18581 30093 39836 19500 8530 9692 2000 16820 18782 14223 + 1034 1161 2096 874 1606 795 1788 859 1260 1668 + 2254 1852 5126 1931 1204 890 1803 1822 1325 2607 + 1015 890 208 676 679 850 357 380 1140 457 + 1176 1400 328 1500 100 150 100 341 100 249 + 704 100 1000 479 100 1 1089 1 2103 23181 + 1 620 100 466 178 1 100 785 124 140 + 414 97 39 462 165 152 295 1 64 4088 + 965 931 308 3584 4583 4289 100 70 1 1656 + 89 56 76 56 51 681 1 36 1 1 + 83 129 216 87 128 215 227 534 312 90 + 299 1109 686 395 10500 5648 6708 618 749 701 + 814 2610 200 200 300 200 200 300 200 200 + 300 516 286 200 200 200 400 1200 200 400 + 200 200 350 200 400 250 300 200 250 200 + 300 600 23200 1 1 1 1 1 1 1 >; + status = "okay"; + wf_0 { + //CLICK + qcom,effect-id = <0>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_1 { + //DOUBLE CLICK + qcom,effect-id = <1>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [7e 3e]; + qcom,wf-brake-pattern = [03 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_2 { + //TICK + qcom,effect-id = <2>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [7e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_3 { + //THUD + qcom,effect-id = <3>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_4 { + //POP + qcom,effect-id = <4>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <28000>; + }; + wf_5 { + //HEAVY CLICK + qcom,effect-id = <5>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [7e 7e 7e]; + qcom,wf-brake-pattern = [03 03 01 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_6 { + //id 6 + qcom,effect-id = <6>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_7 { + //id 7 + qcom,effect-id = <7>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_8 { + //id 8 + qcom,effect-id = <8>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + wf_9 { + //id 9 + qcom,effect-id = <9>; + qcom,wf-vmax-mv = <3600>; + qcom,wf-pattern = [3e 3e]; + qcom,wf-brake-pattern = [02 01 00 00]; + qcom,wf-play-rate-us = <20000>; + }; + }; +}; +&tlmm { + /* AW86224_RESET_N */ + awinic_gpio_reset: awinic_gpio_reset { + mux { + pins = "gpio35"; + function = "gpio"; + }; + + config { + pins = "gpio35"; + drive-strength = <2>; + bias-disable; + output-low; + }; + }; + /* AW8624_RESET_N, state device active*/ + awinic_gpio_reset_output_high: awinic_gpio_reset_output_high { + mux { + pins = "gpio35"; + function = "gpio"; + }; + + config { + pins = "gpio35"; + drive-strength = <2>; + bias-disable; + output-high; + }; + }; + /* AW86224_INTERRUPT_N */ + awinic_gpio_int: awinic_gpio_int { + mux { + pins = "gpio18"; + function = "gpio"; + }; + + config { + pins = "gpio18"; + drive-strength = <2>; + bias-pull-up; + input-enable; + }; + }; +}; + +&pm8350c_gpios { + pdlc_gpio_default: pdlc_gpio_default { + pins = "gpio8"; + function = "normal"; + input-disable; + output-low; + power-source = <1>; + }; + + pdlc_gpio_active: pdlc_gpio_active { + pins = "gpio8"; + function = "normal"; + input-disable; + output-high; + power-source = <1>; + }; + +}; + +&pm8350c_gpios { + awinicl_gpio_reset: awinicl_gpio_reset { + pins = "gpio6"; + function = "normal"; + input-disable; + output-low; + power-source = <1>; + }; + + awinicl_gpio_reset_output_high: awinicl_gpio_reset_output_high { + pins = "gpio6"; + function = "normal"; + input-disable; + output-high; + power-source = <1>; + }; +}; + +&qupv3_se4_i2c { + status = "ok"; + qcom,clk-freq-out = <1000000>; + #address-cells = <1>; + #size-cells = <0>; + nq@28 { + compatible = "qcom,sn-nci"; + reg = <0x28>; + qcom,sn-irq = <&tlmm 41 0x00>; + qcom,sn-ven = <&tlmm 38 0x00>; + qcom,sn-firm = <&tlmm 40 0x00>; + qcom,sn-clkreq = <&tlmm 39 0x00>; + qcom,sn-vdd-1p8-supply = <&L18B>; + qcom,sn-vdd-1p8-voltage = <1800000 1800000>; + qcom,sn-vdd-1p8-current = <157000>; + interrupt-parent = <&tlmm>; + interrupts = <41 0>; + interrupt-names = "nfc_irq"; + pinctrl-names = "nfc_active", "nfc_suspend"; + pinctrl-0 = <&nfc_int_active &nfc_enable_active>; + pinctrl-1 = <&nfc_int_suspend &nfc_enable_suspend>; + }; +}; + +&ufsphy_mem { + compatible = "qcom,ufs-phy-qmp-v4-yupik"; + + vdda-phy-supply = <&L10C>; + vdda-pll-supply = <&L6B>; + vdda-phy-max-microamp = <97500>; + vdda-pll-max-microamp = <18400>; + + status = "ok"; +}; + +&ufshc_mem { + vdd-hba-supply = <&gcc_ufs_phy_gdsc>; + vdd-hba-fixed-regulator; + + vcc-supply = <&L7B>; + vcc-voltage-level = <2504000 2952000>; + vcc-low-voltage-sup; + vcc-max-microamp = <800000>; + + /* + * Yupik target supports both UFS2.2 & UFS3.1, here + * vccq2 is supplied via eLDO, and that is controlled via + * L9B which supports a max voltage of 1.2V, but eLDO would + * supply 1.8V. and same L9B acts as vccq voltage for UFS3.1 + * devices. + * Here L9B can max support for 1.2V but UFS GKI driver code + * votes for 1.8V, which is leading to failure from pmic + * regulator. + * + * Now since vccq and control of eLDO are common that is L9B + * we can use vccq vote as control of eLDO for vccq2. + * Hence vccq entries shall be used for both type of UFS + * devices only. And vccq entries should not be changed/removed + * for any design alteration. + */ + vccq-supply = <&L9B>; + vccq-max-microamp = <900000>; + vccq-min-microamp = <10000>; + + qcom,vddp-ref-clk-supply = <&L9B>; + qcom,vddp-ref-clk-max-microamp = <100>; + + status = "ok"; +}; + +&pm7250b_2 { + /* Slave ID - 8 */ + reg = <8 SPMI_USID>; +}; + +&pm7250b_3 { + /* Slave ID - 9 */ + reg = <9 SPMI_USID>; +}; + +&pmk8350_sdam_23 { + adc_scaling: scaling@bf { + reg = <0xbf 0x1>; + bits = <0 2>; + }; +}; +&pm7250b_gpios { + charger_skin_therm { + charger_skin_therm_default: charger_skin_therm_default { + pins = "gpio1"; + bias-high-impedance; + }; + }; + + led_r_therm { + led_r_therm_default: led_r_therm_default { + pins = "gpio11"; + bias-high-impedance; + }; + }; + + led_l_therm { + led_l_therm_default: led_l_therm_default { + pins = "gpio12"; + bias-high-impedance; + }; + }; + + pa_5g_therm { + pa_5g_therm_default: pa_5g_therm_default { + pins = "gpio5"; + bias-high-impedance; + }; + }; +}; + +&pm7250b_vadc { + interrupts = <0x8 0x31 0x0 IRQ_TYPE_EDGE_RISING>; + + pinctrl-names = "default"; + pinctrl-0 = < + &charger_skin_therm_default + &led_r_therm_default + &led_l_therm_default + &pa_5g_therm_default>; + + smb1390_therm@e { + qcom,scale-fn-type = ; + }; + + charger_skin_therm { + reg = ; + label = "charger_skin_therm"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + + conn_therm { + reg = ; + label = "conn_therm"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + + led_r_therm { + reg = ; + label = "led_r_therm"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + + modem1_pa0 { + reg = ; + label = "modem1_pa0"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + +}; + +&pm7250b_adc_tm { + interrupts = <0x8 0x35 0x0 IRQ_TYPE_EDGE_RISING>; + io-channels = <&pm7250b_vadc ADC5_AMUX_THM4_100K_PU>, + <&pm7250b_vadc ADC5_AMUX_THM3_100K_PU>, + <&pm7250b_vadc ADC5_GPIO1_100K_PU>, + <&pm7250b_vadc ADC5_GPIO3_100K_PU>; + + /* Channel nodes */ + charger_skin_therm { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; + + conn_therm { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; + + led_r_therm { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; + + modem1_pa0 { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; +}; + +&thermal_zones { + charger_therm0 { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-governor = "user_space"; + thermal-sensors = <&pm7250b_adc_tm ADC5_AMUX_THM4_100K_PU>; + wake-capable-sensor; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; + + conn_therm { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-governor = "user_space"; + thermal-sensors = <&pm7250b_adc_tm ADC5_AMUX_THM3_100K_PU>; + wake-capable-sensor; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; + + led_r_therm { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-governor = "user_space"; + thermal-sensors = <&pm7250b_adc_tm ADC5_GPIO1_100K_PU>; + wake-capable-sensor; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; + + modem1_pa0 { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-governor = "user_space"; + thermal-sensors = <&pm7250b_adc_tm ADC5_GPIO3_100K_PU>; + wake-capable-sensor; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; +}; + +&pm7250b_tz { + interrupts = <0x8 0x24 0x0 IRQ_TYPE_EDGE_BOTH>; +}; + +&pm7250b_bcl { + interrupts = <0x8 0x1d 0x0 IRQ_TYPE_NONE>, + <0x8 0x1d 0x1 IRQ_TYPE_NONE>, + <0x8 0x1d 0x2 IRQ_TYPE_NONE>; +}; + +&pm7250b_clkdiv { + clocks = <&rpmhcc RPMH_CXO_CLK>; +}; + +&pm7250b_charger { + status = "disabled"; +}; + +&pm7250b_qg { + status = "disabled"; +}; + +&pm7250b_pdphy { + status = "disabled"; +}; + +&spmi_debug_bus { + status = "ok"; +}; + +&spmi_glink_debug { + status = "ok"; +}; + +&pm8350c_pwm_2 { + status = "ok"; +}; + +&pm8350c_switch0 { + qcom,led-mask = <9>; /* Channels 1 & 4 */ + qcom,symmetry-en; +}; + +&pm8350c_switch1 { + qcom,led-mask = <6>; /* Channels 2 & 3 */ + qcom,symmetry-en; +}; + +&pm8350c_switch2 { + qcom,led-mask = <15>; /* All Channels */ + qcom,symmetry-en; +}; + +&pm8350c_flash { + status = "ok"; +}; + +&battery_charger { + qcom,thermal-mitigation = <3000000 1500000 1000000 500000>; +}; + +&sdhc_1 { + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc1_on>; + pinctrl-1 = <&sdc1_off>; + + vdd-supply = <&L7B>; + qcom,vdd-voltage-level = <2952000 2952000>; + qcom,vdd-current-level = <0 570000>; + + vdd-io-supply = <&L19B>; + qcom,vdd-io-always-on; + qcom,vdd-io-lpm-sup; + qcom,vdd-io-voltage-level = <1800000 1800000>; + qcom,vdd-io-current-level = <0 325000>; + + status = "ok"; +}; + +&sdhc_2 { + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc2_on>; + pinctrl-1 = <&sdc2_off>; + + vdd-supply = <&L9C>; + qcom,vdd-voltage-level = <2960000 2960000>; + qcom,vdd-current-level = <0 800000>; + + vdd-io-supply = <&L6C>; + qcom,vdd-io-voltage-level = <1800000 2960000>; + qcom,vdd-io-current-level = <0 22000>; + + cd-gpios = <&tlmm 91 GPIO_ACTIVE_LOW>; + + status = "ok"; +}; + +&qupv3_se13_i2c { + status = "disabled"; +}; + +&qupv3_se13_spi { + status = "ok"; + qcom,rt; + pinctrl-1 = <&qupv3_se13_spi_sleep &qupv3_se13_spi_sleep_cs>; + xiaomi_l9_touch@0 { + compatible = "xiaomi,l9-spi"; + reg = <0>; + spi-max-frequency = <5000000>; + interrupt-parent = <&tlmm>; + interrupts = <81 0x2802>; + goodix,irq-gpio = <&tlmm 81 0x2802>; + goodix,reset-gpio = <&tlmm 105 0x00>; + goodix,irq-flags = <2>; + goodix,panel-max-x = <10800>; + goodix,panel-max-y = <24000>; + goodix,panel-max-w = <255>; + goodix,panel-max-p = <4096>; + goodix,firmware-name = "goodix_firmware_l9.bin"; + goodix,config-name = "goodix_cfg_group_l9.bin"; + + goodix,avdd-name = "avdd"; + goodix,iovdd-name = "vdd"; + avdd-supply = <&L7C>; + vdd-supply = <&L2C>; + focaltech,avdd-name = "avdd"; + focaltech,iovdd-name = "iovdd"; + iovdd-supply = <&L2C>; + focaltech,reset-gpio = <&tlmm 105 0x00>; + focaltech,irq-gpio = <&tlmm 81 0x2808>; + focaltech,max-touch-number = <10>; + focaltech,display-coords = <0 0 10800 24000>; + }; +}; + +&tlmm { + qupv3_se13_spi_sleep: qupv3_se13_spi_sleep { + mux { + pins = "gpio52", "gpio53", + "gpio54"; + function = "gpio"; + }; + + config { + pins = "gpio52", "gpio53", + "gpio54"; + drive-strength = <6>; + bias-disable; + }; + }; + + qupv3_se13_spi_sleep_cs: qupv3_se13_spi_sleep_cs { + mux { + pins = "gpio55"; + function = "gpio"; + }; + + config { + pins = "gpio55"; + drive-strength = <6>; + bias-disable; + output-high; + }; + }; +}; + +&pmk8350 { + pon_hlos@1300 { + interrupts = <0x0 0x13 0x7 IRQ_TYPE_EDGE_BOTH>, + <0x0 0x13 0x6 IRQ_TYPE_EDGE_BOTH>, + <0x0 0x13 0x0 IRQ_TYPE_EDGE_BOTH>, + <0x0 0x13 0x2 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "kpdpwr", "resin", "kpdpwr-bark", + "kpdpwr-resin-bark"; + qcom,pon_1 { + qcom,pon-type = ; + qcom,pull-up; + qcom,use-bark = <1>; + qcom,support-reset = <1>; + linux,code = ; + qcom,s1-timer = <6720>; + qcom,s2-timer = <2000>; + qcom,s2-type = ; + }; + }; +};