diff --git a/qcom/diwali-atp-overlay.dts b/qcom/diwali-atp-overlay.dts index 66d88820..e9bd6322 100644 --- a/qcom/diwali-atp-overlay.dts +++ b/qcom/diwali-atp-overlay.dts @@ -8,4 +8,6 @@ compatible = "qcom,diwali-atp", "qcom,diwali", "qcom,atp"; qcom,msm-id = <506 0x10000>; qcom,board-id = <33 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-atp.dts b/qcom/diwali-atp.dts index 094ed8d7..996d3e2e 100644 --- a/qcom/diwali-atp.dts +++ b/qcom/diwali-atp.dts @@ -7,4 +7,6 @@ model = "Qualcomm Technologies, Inc. Diwali ATP"; compatible = "qcom,diwali-atp", "qcom,diwali", "qcom,atp"; qcom,board-id = <33 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-atp.dtsi b/qcom/diwali-atp.dtsi index 1a5acd05..a2fb4594 100644 --- a/qcom/diwali-atp.dtsi +++ b/qcom/diwali-atp.dtsi @@ -1,6 +1,7 @@ #include #include +#include "diwali-pm7250b.dtsi" #include "diwali-pmic-overlay.dtsi" &soc { diff --git a/qcom/diwali-hsp.dts b/qcom/diwali-hsp.dts index 71c85406..2284378d 100644 --- a/qcom/diwali-hsp.dts +++ b/qcom/diwali-hsp.dts @@ -6,4 +6,6 @@ model = "Qualcomm Technologies, Inc. Diwali HSP SoC"; compatible = "qcom,diwali"; qcom,board-id = <0 2>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-amoled-overlay.dts b/qcom/diwali-idp-amoled-overlay.dts index 0b0524a0..f5a34d12 100644 --- a/qcom/diwali-idp-amoled-overlay.dts +++ b/qcom/diwali-idp-amoled-overlay.dts @@ -8,4 +8,6 @@ compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,msm-id = <506 0x10000>; qcom,board-id = <34 3>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-amoled.dts b/qcom/diwali-idp-amoled.dts index 5366905c..8580db1b 100644 --- a/qcom/diwali-idp-amoled.dts +++ b/qcom/diwali-idp-amoled.dts @@ -7,4 +7,6 @@ model = "Qualcomm Technologies, Inc. Diwali IDP AMOLED"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,board-id = <34 3>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-amoled.dtsi b/qcom/diwali-idp-amoled.dtsi index 107fe5a7..4387108d 100644 --- a/qcom/diwali-idp-amoled.dtsi +++ b/qcom/diwali-idp-amoled.dtsi @@ -1,4 +1,5 @@ #include "diwali-idp.dtsi" +#include "diwali-idp-pm7250b.dtsi" &soc { }; diff --git a/qcom/diwali-idp-hsp-overlay.dts b/qcom/diwali-idp-hsp-overlay.dts index 7478f6e1..3de9b67e 100644 --- a/qcom/diwali-idp-hsp-overlay.dts +++ b/qcom/diwali-idp-hsp-overlay.dts @@ -8,4 +8,6 @@ compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,msm-id = <506 0x10000>; qcom,board-id = <34 2>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-hsp.dts b/qcom/diwali-idp-hsp.dts index 1c5686af..9044e4de 100644 --- a/qcom/diwali-idp-hsp.dts +++ b/qcom/diwali-idp-hsp.dts @@ -7,4 +7,6 @@ model = "Qualcomm Technologies, Inc. Diwali IDP + HSP"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,board-id = <34 2>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-hsp.dtsi b/qcom/diwali-idp-hsp.dtsi index 107fe5a7..4387108d 100644 --- a/qcom/diwali-idp-hsp.dtsi +++ b/qcom/diwali-idp-hsp.dtsi @@ -1,4 +1,5 @@ #include "diwali-idp.dtsi" +#include "diwali-idp-pm7250b.dtsi" &soc { }; diff --git a/qcom/diwali-idp-nopmi-overlay.dts b/qcom/diwali-idp-nopmi-overlay.dts index 5d6a7f35..a085f530 100644 --- a/qcom/diwali-idp-nopmi-overlay.dts +++ b/qcom/diwali-idp-nopmi-overlay.dts @@ -1,11 +1,13 @@ /dts-v1/; /plugin/; -#include "diwali-idp-nopmi.dtsi" +#include "diwali-idp.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali IDP NOPMI"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,msm-id = <506 0x10000>; qcom,board-id = <34 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0>; }; diff --git a/qcom/diwali-idp-nopmi.dts b/qcom/diwali-idp-nopmi.dts index 211ab6af..6acb7fb4 100644 --- a/qcom/diwali-idp-nopmi.dts +++ b/qcom/diwali-idp-nopmi.dts @@ -1,10 +1,12 @@ /dts-v1/; #include "diwali.dtsi" -#include "diwali-idp-nopmi.dtsi" +#include "diwali-idp.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali IDP NOPMI"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,board-id = <34 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0>; }; diff --git a/qcom/diwali-idp-nopmi.dtsi b/qcom/diwali-idp-nopmi.dtsi deleted file mode 100644 index 17f1e228..00000000 --- a/qcom/diwali-idp-nopmi.dtsi +++ /dev/null @@ -1,2 +0,0 @@ -&soc { -}; diff --git a/qcom/diwali-idp-overlay.dts b/qcom/diwali-idp-overlay.dts index ff5834e7..a8ccdbe8 100644 --- a/qcom/diwali-idp-overlay.dts +++ b/qcom/diwali-idp-overlay.dts @@ -2,10 +2,13 @@ /plugin/; #include "diwali-idp.dtsi" +#include "diwali-idp-pm7250b.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali IDP"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,msm-id = <506 0x10000>; qcom,board-id = <34 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-pm7250b.dtsi b/qcom/diwali-idp-pm7250b.dtsi new file mode 100644 index 00000000..73468473 --- /dev/null +++ b/qcom/diwali-idp-pm7250b.dtsi @@ -0,0 +1,5 @@ +#include "diwali-pm7250b.dtsi" + +&battery_charger { + qcom,thermal-mitigation = <3000000 1500000 1000000 500000>; +}; diff --git a/qcom/diwali-idp-usbc-overlay.dts b/qcom/diwali-idp-usbc-overlay.dts index 120a996e..7d560a8f 100644 --- a/qcom/diwali-idp-usbc-overlay.dts +++ b/qcom/diwali-idp-usbc-overlay.dts @@ -8,4 +8,6 @@ compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,msm-id = <506 0x10000>; qcom,board-id = <34 1>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-usbc.dts b/qcom/diwali-idp-usbc.dts index b185ae1c..535c0a0a 100644 --- a/qcom/diwali-idp-usbc.dts +++ b/qcom/diwali-idp-usbc.dts @@ -7,4 +7,6 @@ model = "Qualcomm Technologies, Inc. Diwali IDP USBC audio"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,board-id = <34 1>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp-usbc.dtsi b/qcom/diwali-idp-usbc.dtsi index 17f1e228..4387108d 100644 --- a/qcom/diwali-idp-usbc.dtsi +++ b/qcom/diwali-idp-usbc.dtsi @@ -1,2 +1,5 @@ +#include "diwali-idp.dtsi" +#include "diwali-idp-pm7250b.dtsi" + &soc { }; diff --git a/qcom/diwali-idp.dts b/qcom/diwali-idp.dts index 23187028..0976e5a9 100644 --- a/qcom/diwali-idp.dts +++ b/qcom/diwali-idp.dts @@ -2,9 +2,12 @@ #include "diwali.dtsi" #include "diwali-idp.dtsi" +#include "diwali-idp-pm7250b.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali IDP"; compatible = "qcom,diwali-idp", "qcom,diwali", "qcom,idp"; qcom,board-id = <34 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-idp.dtsi b/qcom/diwali-idp.dtsi index 4c73efc8..8eb63831 100644 --- a/qcom/diwali-idp.dtsi +++ b/qcom/diwali-idp.dtsi @@ -23,10 +23,6 @@ }; }; -&battery_charger { - qcom,thermal-mitigation = <3000000 1500000 1000000 500000>; -}; - &qupv3_se0_i2c { #address-cells = <1>; #size-cells = <0>; diff --git a/qcom/diwali-pm7250b.dtsi b/qcom/diwali-pm7250b.dtsi new file mode 100644 index 00000000..21e2a160 --- /dev/null +++ b/qcom/diwali-pm7250b.dtsi @@ -0,0 +1,347 @@ +#include +#include +#include "pm7250b.dtsi" + +&soc { + qcom,pmic_glink { + status = "okay"; + }; + + qcom,pmic_glink_log { + compatible = "qcom,pmic-glink"; + qcom,pmic-glink-channel = "PMIC_LOGS_ADSP_APPS"; + + qcom,battery_debug { + compatible = "qcom,battery-debug"; + }; + + qcom,charger_ulog_glink { + compatible = "qcom,charger-ulog-glink"; + }; + + spmi_glink_debug: qcom,spmi_glink_debug { + compatible = "qcom,spmi-glink-debug"; + #address-cells = <1>; + #size-cells = <0>; + depends-on-supply = <&spmi1_bus>; + + /* Primary SPMI bus */ + spmi@0 { + reg = <0>; + #address-cells = <2>; + #size-cells = <0>; + + qcom,pm7250b-debug@8 { + compatible = "qcom,spmi-pmic"; + reg = <8 SPMI_USID>; + qcom,can-sleep; + }; + }; + + /* Secondary SPMI bus */ + spmi@1 { + reg = <1>; + #address-cells = <2>; + #size-cells = <0>; + + smb1394_glink_debug: qcom,smb1394-debug@9 { + compatible = "qcom,spmi-pmic"; + reg = <9 SPMI_USID>; + qcom,can-sleep; + }; + + qcom,smb1394-debug@b { + compatible = "qcom,spmi-pmic"; + reg = <11 SPMI_USID>; + qcom,can-sleep; + }; + + qcom,smb1394-debug@d { + compatible = "qcom,spmi-pmic"; + reg = <12 SPMI_USID>; + qcom,can-sleep; + }; + }; + }; + }; +}; + +&glink_edge { + qcom,pmic_glink_rpmsg { + qcom,glink-channels = "PMIC_RTR_ADSP_APPS"; + }; + + qcom,pmic_glink_log_rpmsg { + qcom,glink-channels = "PMIC_LOGS_ADSP_APPS"; + qcom,intents = <0x800 5 + 0xc00 3 + 0x2000 1>; + }; +}; + +&spmi0_debug_bus { + depends-on2-supply = <&smb1394_glink_debug>; +}; + +&thermal_zones { + socd { + cooling-maps { + socd_apc1 { + trip = <&socd_trip>; + cooling-device = <&APC1_pause 1 1>; + }; + + socd_cdsp1 { + trip = <&socd_trip>; + cooling-device = <&cdsp_sw 4 4>; + }; + + socd_gpu0 { + trip = <&socd_trip>; + cooling-device = <&msm_gpu 2 2>; + }; + }; + }; + + pm7250b-ibat-lvl0 { + trips { + ibat-lvl0 { + temperature = <6000>; + }; + }; + }; + + pm7250b-ibat-lvl1 { + trips { + ibat-lvl1 { + temperature = <7500>; + }; + }; + }; + + pm8350b-bcl-lvl0 { + cooling-maps { + vbat_lte0 { + trip = <&b_bcl_lvl0>; + cooling-device = <&modem_lte_dsc 8 8>; + }; + + vbat_nr0_scg { + trip = <&b_bcl_lvl0>; + cooling-device = <&modem_nr_scg_dsc 3 3>; + }; + + vbat_nr0 { + trip = <&b_bcl_lvl0>; + cooling-device = <&modem_nr_dsc 6 6>; + }; + + vbat_cdsp0 { + trip = <&b_bcl_lvl0>; + cooling-device = <&cdsp_sw 2 2>; + }; + + vbat_cpu_5 { + trip = <&b_bcl_lvl0>; + cooling-device = <&cpu5_pause 1 1>; + }; + + vbat_gpu0 { + trip = <&b_bcl_lvl0>; + cooling-device = <&msm_gpu 1 1>; + }; + }; + }; + + pm8350b-bcl-lvl1 { + cooling-maps { + vbat_lte1 { + trip = <&b_bcl_lvl1>; + cooling-device = <&modem_lte_dsc 10 10>; + }; + + vbat_nr1_scg { + trip = <&b_bcl_lvl1>; + cooling-device = <&modem_nr_scg_dsc 10 10>; + }; + + vbat_nr1 { + trip = <&b_bcl_lvl1>; + cooling-device = <&modem_nr_dsc 9 9>; + }; + + vbat_cdsp1 { + trip = <&b_bcl_lvl1>; + cooling-device = <&cdsp_sw 4 4>; + }; + + vbat_cpu_6_7 { + trip = <&b_bcl_lvl1>; + cooling-device = <&cpu_6_7_pause 1 1>; + }; + + vbat_gpu1 { + trip = <&b_bcl_lvl1>; + cooling-device = <&msm_gpu 2 2>; + }; + }; + }; + + pm8350b-bcl-lvl2 { + cooling-maps { + vbat_cdsp2 { + trip = <&b_bcl_lvl2>; + cooling-device = <&cdsp_sw 5 THERMAL_NO_LIMIT>; + }; + + vbat_gpu2 { + trip = <&b_bcl_lvl2>; + cooling-device = <&msm_gpu 3 THERMAL_NO_LIMIT>; + }; + }; + }; + + conn-therm { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm7250b_vadc ADC5_AMUX_THM3_100K_PU>; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; + + chg-skin-therm { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm7250b_vadc ADC5_AMUX_THM1_100K_PU>; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; +}; + +&battery_charger { + status = "okay"; +}; + +&ucsi { + status = "okay"; +}; + +&altmode { + status = "okay"; +}; + +&pm7250b_clkdiv { + clocks = <&rpmhcc RPMH_CXO_CLK>; +}; + +&spmi0_debug_bus { + 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,pm7250b-debug@8 { + compatible = "qcom,spmi-pmic"; + reg = <8 SPMI_USID>; + qcom,can-sleep; + }; + }; +}; + +&pm7250b_2 { + /* Slave ID - 8 */ + reg = <8 SPMI_USID>; +}; + +&pm7250b_3 { + /* Slave ID - 9 */ + reg = <9 SPMI_USID>; +}; + +&pm7250b_vadc { + interrupts = <0x8 0x31 0x0 IRQ_TYPE_EDGE_RISING>; + + smb1390_therm@e { + qcom,scale-fn-type = ; + }; + + pm7250b_usb_conn_therm { + reg = ; + label = "pm7250b_usb_conn_therm"; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + qcom,pre-scaling = <1 1>; + }; + + pm7250b_smb_skin_therm { + reg = ; + label = "pm7250b_smb_skin_therm"; + 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_THM3_100K_PU>, + <&pm7250b_vadc ADC5_AMUX_THM1_100K_PU>; + + pm7250b_usb_conn_therm { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; + + pm7250b_smb_skin_therm { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; +}; + +&pm7250b_tz { + interrupts = <0x8 0x24 0x0 IRQ_TYPE_EDGE_BOTH>; +}; + +&pm7250b_bcl { + interrupts = <0x8 0x1d 0x0 IRQ_TYPE_EDGE_RISING>, + <0x8 0x1d 0x1 IRQ_TYPE_EDGE_RISING>, + <0x8 0x1d 0x2 IRQ_TYPE_EDGE_RISING>; +}; + +&pm7250b_charger { + status = "disabled"; +}; + +&pm7250b_qg { + status = "disabled"; +}; + +&pm7250b_pdphy { + status = "disabled"; +}; diff --git a/qcom/diwali-pmic-overlay.dtsi b/qcom/diwali-pmic-overlay.dtsi index 1b5230df..872b872a 100644 --- a/qcom/diwali-pmic-overlay.dtsi +++ b/qcom/diwali-pmic-overlay.dtsi @@ -1,42 +1,29 @@ #include #include -#include #include "pmk8350.dtsi" #include "pm8350c.dtsi" #include "pm7325.dtsi" #include "pmr735a.dtsi" -#include "pm7250b.dtsi" - -&pm7250b_clkdiv { - clocks = <&rpmhcc RPMH_CXO_CLK>; -}; - -&spmi0_debug_bus { - qcom,pm7250b-debug@8 { - compatible = "qcom,spmi-pmic"; - reg = <8 SPMI_USID>; - #address-cells = <2>; - #size-cells = <0>; - qcom,can-sleep; +&pm8350c_gpios { + pm8010i_reset { + pm8010i_active: pm8010i_active { + pins = "gpio3"; + function = "normal"; + bias-disable; + output-high; + power-source = <0>; + }; }; - 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,pm7250b-debug@8 { - compatible = "qcom,spmi-pmic"; - reg = <8 SPMI_USID>; - qcom,can-sleep; + pm8010j_reset { + pm8010j_active: pm8010j_active { + pins = "gpio4"; + function = "normal"; + bias-disable; + output-high; + power-source = <0>; }; }; }; @@ -178,40 +165,6 @@ }; }; -&pm7250b_2 { - /* Slave ID - 8 */ - reg = <8 SPMI_USID>; -}; - -&pm7250b_3 { - /* Slave ID - 9 */ - reg = <9 SPMI_USID>; -}; - -&pm7250b_vadc { - interrupts = <0x8 0x31 0x0 IRQ_TYPE_EDGE_RISING>; - - smb1390_therm@e { - qcom,scale-fn-type = ; - }; - - pm7250b_usb_conn_therm { - reg = ; - label = "pm7250b_usb_conn_therm"; - qcom,ratiometric; - qcom,hw-settle-time = <200>; - qcom,pre-scaling = <1 1>; - }; - - pm7250b_smb_skin_therm { - reg = ; - label = "pm7250b_smb_skin_therm"; - qcom,ratiometric; - qcom,hw-settle-time = <200>; - qcom,pre-scaling = <1 1>; - }; -}; - &pm7325_tz { io-channels = <&pmk8350_vadc PM7325_ADC7_DIE_TEMP>; io-channel-names = "thermal"; @@ -260,25 +213,6 @@ }; }; - -&pm7250b_adc_tm { - interrupts = <0x8 0x35 0x0 IRQ_TYPE_EDGE_RISING>; - io-channels = <&pm7250b_vadc ADC5_AMUX_THM3_100K_PU>, - <&pm7250b_vadc ADC5_AMUX_THM1_100K_PU>; - - pm7250b_usb_conn_therm { - reg = ; - qcom,ratiometric; - qcom,hw-settle-time = <200>; - }; - - pm7250b_smb_skin_therm { - reg = ; - qcom,ratiometric; - qcom,hw-settle-time = <200>; - }; -}; - &thermal_zones { skin-msm-therm { polling-delay-passive = <0>; @@ -319,32 +253,6 @@ }; }; - conn-therm { - polling-delay-passive = <0>; - polling-delay = <0>; - thermal-sensors = <&pmk8350_vadc ADC5_AMUX_THM3_100K_PU>; - trips { - active-config0 { - temperature = <125000>; - hysteresis = <1000>; - type = "passive"; - }; - }; - }; - - chg-skin-therm { - polling-delay-passive = <0>; - polling-delay = <0>; - thermal-sensors = <&pmk8350_vadc ADC5_AMUX_THM1_100K_PU>; - trips { - active-config0 { - temperature = <125000>; - hysteresis = <1000>; - type = "passive"; - }; - }; - }; - xo-therm { polling-delay-passive = <0>; polling-delay = <0>; @@ -373,24 +281,230 @@ }; }; -&pm7250b_tz { - interrupts = <0x8 0x24 0x0 IRQ_TYPE_EDGE_BOTH>; +/* + * Each QUP device that's a parent to PMIC must be listed as a critical device + * to GCC + */ +&gcc { + qcom,critical-devices = <&qupv3_se2_i2c>; }; -&pm7250b_bcl { - interrupts = <0x8 0x1d 0x0 IRQ_TYPE_EDGE_RISING>, - <0x8 0x1d 0x1 IRQ_TYPE_EDGE_RISING>, - <0x8 0x1d 0x2 IRQ_TYPE_EDGE_RISING>; -}; +&qupv3_se2_i2c { + #address-cells = <1>; + #size-cells = <0>; + status = "ok"; -&pm7250b_charger { - status = "disabled"; -}; + pm8010i@8 { + compatible = "qcom,i2c-pmic"; + reg = <0x8>; + #address-cells = <1>; + #size-cells = <0>; -&pm7250b_qg { - status = "disabled"; -}; + pinctrl-names = "default"; + pinctrl-0 = <&pm8010i_active>; -&pm7250b_pdphy { - status = "disabled"; + pm8010-chip@900 { + compatible = "qcom,pm8008-chip"; + reg = <0x900>; + + PM8010I_EN: qcom,pm8008-chip-en { + regulator-name = "pm8010i-chip-en"; + }; + }; + + qcom,revid@100 { + compatible = "qcom,qpnp-revid"; + reg = <0x100>; + }; + }; + + pm8010i@9 { + compatible = "qcom,i2c-pmic"; + reg = <0x9>; + #address-cells = <1>; + #size-cells = <0>; + + qcom,pm8010i-regulator { + compatible = "qcom,pm8010-regulator"; + #address-cells = <1>; + #size-cells = <0>; + + pm8008_en-supply = <&PM8010I_EN>; + vdd_l1_l2-supply = <&S8B>; + vdd_l3_l4-supply = <&BOB>; + vdd_l5-supply = <&BOB>; + vdd_l6-supply = <&BOB>; + vdd_l7-supply = <&BOB>; + + L1I: pm8010i_l1: regulator@4000 { + reg = <0x4000>; + regulator-name = "pm8010i_l1"; + regulator-min-microvolt = <254000>; + regulator-max-microvolt = <1200000>; + qcom,min-dropout-voltage = <128000>; + qcom,hpm-min-load = <30000>; + }; + + L2I: pm8010i_l2: regulator@4100 { + reg = <0x4100>; + regulator-name = "pm8010i_l2"; + regulator-min-microvolt = <278000>; + regulator-max-microvolt = <1150000>; + qcom,min-dropout-voltage = <104000>; + qcom,hpm-min-load = <30000>; + }; + + L3I: pm8010i_l3: regulator@4200 { + reg = <0x4200>; + regulator-name = "pm8010i_l3"; + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <3000000>; + qcom,min-dropout-voltage = <192000>; + qcom,hpm-min-load = <0>; + }; + + L4I: pm8010i_l4: regulator@4300 { + reg = <0x4300>; + regulator-name = "pm8010i_l4"; + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <2900000>; + qcom,min-dropout-voltage = <128000>; + qcom,hpm-min-load = <0>; + }; + + L5I: pm8010i_l5: regulator@4400 { + reg = <0x4400>; + regulator-name = "pm8010i_l5"; + regulator-min-microvolt = <1504000>; + regulator-max-microvolt = <3544000>; + qcom,min-dropout-voltage = <0>; + qcom,hpm-min-load = <0>; + }; + + L6I: pm8010i_l6: regulator@4500 { + reg = <0x4500>; + regulator-name = "pm8010i_l6"; + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <2900000>; + qcom,min-dropout-voltage = <128000>; + qcom,hpm-min-load = <0>; + }; + + L7I: pm8010i_l7: regulator@4600 { + reg = <0x4600>; + regulator-name = "pm8010i_l7"; + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <3000000>; + qcom,min-dropout-voltage = <256000>; + qcom,hpm-min-load = <0>; + }; + }; + }; + + pm8010j@c { + compatible = "qcom,i2c-pmic"; + reg = <0xc>; + #address-cells = <1>; + #size-cells = <0>; + + pinctrl-names = "default"; + pinctrl-0 = <&pm8010j_active>; + + pm8010-chip@900 { + compatible = "qcom,pm8008-chip"; + reg = <0x900>; + + PM8010J_EN: qcom,pm8008-chip-en { + regulator-name = "pm8010j-chip-en"; + }; + }; + + qcom,revid@100 { + compatible = "qcom,qpnp-revid"; + reg = <0x100>; + }; + }; + + pm8010j@d { + compatible = "qcom,i2c-pmic"; + reg = <0xd>; + #address-cells = <1>; + #size-cells = <0>; + + qcom,pm8010j-regulator { + compatible = "qcom,pm8010-regulator"; + #address-cells = <1>; + #size-cells = <0>; + + pm8008_en-supply = <&PM8010J_EN>; + vdd_l1_l2-supply = <&S8B>; + vdd_l3_l4-supply = <&S1B>; + vdd_l5-supply = <&BOB>; + vdd_l6-supply = <&BOB>; + vdd_l7-supply = <&BOB>; + + L1J: pm8010j_l1: regulator@4000 { + reg = <0x4000>; + regulator-name = "pm8010j_l1"; + regulator-min-microvolt = <310000>; + regulator-max-microvolt = <1150000>; + qcom,min-dropout-voltage = <72000>; + qcom,hpm-min-load = <30000>; + }; + + L2J: pm8010j_l2: regulator@4100 { + reg = <0x4100>; + regulator-name = "pm8010j_l2"; + regulator-min-microvolt = <358000>; + regulator-max-microvolt = <1486000>; + qcom,min-dropout-voltage = <24000>; + qcom,hpm-min-load = <30000>; + }; + + L3J: pm8010j_l3: regulator@4200 { + reg = <0x4200>; + regulator-name = "pm8010j_l3"; + regulator-min-microvolt = <1628000>; + regulator-max-microvolt = <1950000>; + qcom,min-dropout-voltage = <72000>; + qcom,hpm-min-load = <0>; + }; + + L4J: pm8010j_l4: regulator@4300 { + reg = <0x4300>; + regulator-name = "pm8010j_l4"; + regulator-min-microvolt = <1548000>; + regulator-max-microvolt = <1888000>; + qcom,min-dropout-voltage = <152000>; + qcom,hpm-min-load = <0>; + }; + + L5J: pm8010j_l5: regulator@4400 { + reg = <0x4400>; + regulator-name = "pm8010j_l5"; + regulator-min-microvolt = <1504000>; + regulator-max-microvolt = <3544000>; + qcom,min-dropout-voltage = <0>; + qcom,hpm-min-load = <0>; + }; + + L6J: pm8010j_l6: regulator@4500 { + reg = <0x4500>; + regulator-name = "pm8010j_l6"; + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <2900000>; + qcom,min-dropout-voltage = <128000>; + qcom,hpm-min-load = <0>; + }; + + L7J: pm8010j_l7: regulator@4600 { + reg = <0x4600>; + regulator-name = "pm8010j_l7"; + regulator-min-microvolt = <1504000>; + regulator-max-microvolt = <3544000>; + qcom,min-dropout-voltage = <0>; + qcom,hpm-min-load = <0>; + }; + }; + }; }; diff --git a/qcom/diwali-qrd-nopmi-overlay.dts b/qcom/diwali-qrd-nopmi-overlay.dts index e831dcf9..ec5113fe 100644 --- a/qcom/diwali-qrd-nopmi-overlay.dts +++ b/qcom/diwali-qrd-nopmi-overlay.dts @@ -1,11 +1,13 @@ /dts-v1/; /plugin/; -#include "diwali-qrd-nopmi.dtsi" +#include "diwali-qrd.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali QRD NOPMI"; compatible = "qcom,diwali-qrd", "qcom,diwali", "qcom,qrd"; qcom,msm-id = <506 0x10000>; qcom,board-id = <0x1000B 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0>; }; diff --git a/qcom/diwali-qrd-nopmi.dts b/qcom/diwali-qrd-nopmi.dts index 00cc5dfe..4dbeb1ef 100644 --- a/qcom/diwali-qrd-nopmi.dts +++ b/qcom/diwali-qrd-nopmi.dts @@ -1,10 +1,12 @@ /dts-v1/; #include "diwali.dtsi" -#include "diwali-qrd-nopmi.dtsi" +#include "diwali-qrd.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali QRD NOPMI"; compatible = "qcom,diwali-qrd", "qcom,diwali", "qcom,qrd"; qcom,board-id = <0x1000B 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0>; }; diff --git a/qcom/diwali-qrd-nopmi.dtsi b/qcom/diwali-qrd-nopmi.dtsi deleted file mode 100644 index 17f1e228..00000000 --- a/qcom/diwali-qrd-nopmi.dtsi +++ /dev/null @@ -1,2 +0,0 @@ -&soc { -}; diff --git a/qcom/diwali-qrd-overlay.dts b/qcom/diwali-qrd-overlay.dts index 944ab08a..1c4b19a6 100644 --- a/qcom/diwali-qrd-overlay.dts +++ b/qcom/diwali-qrd-overlay.dts @@ -2,10 +2,13 @@ /plugin/; #include "diwali-qrd.dtsi" +#include "diwali-qrd-pm7250b.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali QRD"; compatible = "qcom,diwali-qrd", "qcom,diwali", "qcom,qrd"; qcom,msm-id = <506 0x10000>; qcom,board-id = <0x1000B 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-qrd-pm7250b.dtsi b/qcom/diwali-qrd-pm7250b.dtsi new file mode 100644 index 00000000..b324266d --- /dev/null +++ b/qcom/diwali-qrd-pm7250b.dtsi @@ -0,0 +1,8 @@ +#include "diwali-pm7250b.dtsi" + +&battery_charger { + qcom,thermal-mitigation = <11500000 11000000 10500000 10000000 9500000 + 9000000 8500000 8000000 7500000 7000000 6500000 + 6000000 5500000 5000000 4500000 4000000 3500000 + 3000000 2500000 2000000 1500000 1000000 500000>; +}; diff --git a/qcom/diwali-qrd.dts b/qcom/diwali-qrd.dts index 5041411e..c182622f 100644 --- a/qcom/diwali-qrd.dts +++ b/qcom/diwali-qrd.dts @@ -2,9 +2,12 @@ #include "diwali.dtsi" #include "diwali-qrd.dtsi" +#include "diwali-qrd-pm7250b.dtsi" / { model = "Qualcomm Technologies, Inc. Diwali QRD"; compatible = "qcom,diwali-qrd", "qcom,diwali", "qcom,qrd"; qcom,board-id = <0x1000B 0>; + qcom,pmic-id-size = <9>; + qcom,pmic-id = <0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x2E>; }; diff --git a/qcom/diwali-qrd.dtsi b/qcom/diwali-qrd.dtsi index fc6c9f13..0c68ad55 100644 --- a/qcom/diwali-qrd.dtsi +++ b/qcom/diwali-qrd.dtsi @@ -28,10 +28,3 @@ }; }; }; - -&battery_charger { - qcom,thermal-mitigation = <11500000 11000000 10500000 10000000 9500000 - 9000000 8500000 8000000 7500000 7000000 6500000 - 6000000 5500000 5000000 4500000 4000000 3500000 - 3000000 2500000 2000000 1500000 1000000 500000>; -}; diff --git a/qcom/diwali-thermal-overlay.dtsi b/qcom/diwali-thermal-overlay.dtsi index b452a344..96886ef9 100644 --- a/qcom/diwali-thermal-overlay.dtsi +++ b/qcom/diwali-thermal-overlay.dtsi @@ -1,123 +1,6 @@ #include &thermal_zones { - socd { - cooling-maps { - socd_apc1 { - trip = <&socd_trip>; - cooling-device = <&APC1_pause 1 1>; - }; - - socd_cdsp1 { - trip = <&socd_trip>; - cooling-device = <&cdsp_sw 4 4>; - }; - - socd_gpu0 { - trip = <&socd_trip>; - cooling-device = <&msm_gpu 2 2>; - }; - }; - }; - - pm7250b-ibat-lvl0 { - trips { - ibat-lvl0 { - temperature = <6000>; - }; - }; - }; - - pm7250b-ibat-lvl1 { - trips { - ibat-lvl1 { - temperature = <7500>; - }; - }; - }; - - pm8350b-bcl-lvl0 { - cooling-maps { - vbat_lte0 { - trip = <&b_bcl_lvl0>; - cooling-device = <&modem_lte_dsc 8 8>; - }; - - vbat_nr0_scg { - trip = <&b_bcl_lvl0>; - cooling-device = <&modem_nr_scg_dsc 3 3>; - }; - - vbat_nr0 { - trip = <&b_bcl_lvl0>; - cooling-device = <&modem_nr_dsc 6 6>; - }; - - vbat_cdsp0 { - trip = <&b_bcl_lvl0>; - cooling-device = <&cdsp_sw 2 2>; - }; - - vbat_cpu_5 { - trip = <&b_bcl_lvl0>; - cooling-device = <&cpu5_pause 1 1>; - }; - - vbat_gpu0 { - trip = <&b_bcl_lvl0>; - cooling-device = <&msm_gpu 1 1>; - }; - }; - }; - - pm8350b-bcl-lvl1 { - cooling-maps { - vbat_lte1 { - trip = <&b_bcl_lvl1>; - cooling-device = <&modem_lte_dsc 10 10>; - }; - - vbat_nr1_scg { - trip = <&b_bcl_lvl1>; - cooling-device = <&modem_nr_scg_dsc 10 10>; - }; - - vbat_nr1 { - trip = <&b_bcl_lvl1>; - cooling-device = <&modem_nr_dsc 9 9>; - }; - - vbat_cdsp1 { - trip = <&b_bcl_lvl1>; - cooling-device = <&cdsp_sw 4 4>; - }; - - vbat_cpu_6_7 { - trip = <&b_bcl_lvl1>; - cooling-device = <&cpu_6_7_pause 1 1>; - }; - - vbat_gpu1 { - trip = <&b_bcl_lvl1>; - cooling-device = <&msm_gpu 2 2>; - }; - }; - }; - - pm8350b-bcl-lvl2 { - cooling-maps { - vbat_cdsp2 { - trip = <&b_bcl_lvl2>; - cooling-device = <&cdsp_sw 5 THERMAL_NO_LIMIT>; - }; - - vbat_gpu2 { - trip = <&b_bcl_lvl2>; - cooling-device = <&msm_gpu 3 THERMAL_NO_LIMIT>; - }; - }; - }; - pm8350c-bcl-lvl0 { cooling-maps { vph_lte0 { diff --git a/qcom/diwali.dtsi b/qcom/diwali.dtsi index e49d6fb7..3616c256 100644 --- a/qcom/diwali.dtsi +++ b/qcom/diwali.dtsi @@ -1756,17 +1756,6 @@ qcom,glink-channels = "fastrpcglink-apps-dsp"; qcom,intents = <0x64 64>; }; - - qcom,pmic_glink_rpmsg { - qcom,glink-channels = "PMIC_RTR_ADSP_APPS"; - }; - - qcom,pmic_glink_log_rpmsg { - qcom,glink-channels = "PMIC_LOGS_ADSP_APPS"; - qcom,intents = <0x800 5 - 0xc00 3 - 0x2000 1>; - }; }; }; @@ -2621,7 +2610,6 @@ #address-cells = <2>; #size-cells = <0>; depends-on-supply = <&spmi1_bus>; - depends-on2-supply = <&smb1394_glink_debug>; qcom,pmk8350-debug@0 { compatible = "qcom,spmi-pmic"; @@ -2670,76 +2658,22 @@ qcom,subsys-name = "lpass"; qcom,protection-domain = "tms/servreg", "msm/adsp/charger_pd"; depends-on-supply = <&ipcc_mproc>; + status = "disabled"; battery_charger: qcom,battery_charger { compatible = "qcom,battery-charger"; + status = "disabled"; }; ucsi: qcom,ucsi { compatible = "qcom,ucsi-glink"; + status = "disabled"; }; altmode: qcom,altmode { compatible = "qcom,altmode-glink"; #altmode-cells = <1>; - }; - }; - - qcom,pmic_glink_log { - compatible = "qcom,pmic-glink"; - qcom,pmic-glink-channel = "PMIC_LOGS_ADSP_APPS"; - - qcom,battery_debug { - compatible = "qcom,battery-debug"; - }; - - qcom,charger_ulog_glink { - compatible = "qcom,charger-ulog-glink"; - }; - - spmi_glink_debug: qcom,spmi_glink_debug { - compatible = "qcom,spmi-glink-debug"; - #address-cells = <1>; - #size-cells = <0>; - depends-on-supply = <&spmi1_bus>; - - /* Primary SPMI bus */ - spmi@0 { - reg = <0>; - #address-cells = <2>; - #size-cells = <0>; - - qcom,pm7250b-debug@8 { - compatible = "qcom,spmi-pmic"; - reg = <8 SPMI_USID>; - qcom,can-sleep; - }; - }; - - /* Secondary SPMI bus */ - spmi@1 { - reg = <1>; - #address-cells = <2>; - #size-cells = <0>; - - smb1394_glink_debug: qcom,smb1394-debug@9 { - compatible = "qcom,spmi-pmic"; - reg = <9 SPMI_USID>; - qcom,can-sleep; - }; - - qcom,smb1394-debug@b { - compatible = "qcom,spmi-pmic"; - reg = <11 SPMI_USID>; - qcom,can-sleep; - }; - - qcom,smb1394-debug@d { - compatible = "qcom,spmi-pmic"; - reg = <12 SPMI_USID>; - qcom,can-sleep; - }; - }; + status = "disabled"; }; }; };