From d0326a2063dac14bd2502b5c98ede67635da6d4b Mon Sep 17 00:00:00 2001 From: Gopala Krishna Nuthaki Date: Mon, 14 Sep 2020 14:46:57 +0530 Subject: [PATCH 1/3] ARM: dts: msm: update modem qmi sennor list for SHIMA Update modem qmi sensor list for SHIMA. Add msm_skin_therm sensor and remove sys_therm2,sdr_mmw_therm in qmi_sensor list for SHIMA. Change-Id: Ia788efd2289cd485210e92e395f29aba14485046 --- qcom/shima-thermal.dtsi | 67 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/qcom/shima-thermal.dtsi b/qcom/shima-thermal.dtsi index 400c81e2b65a..fc97b1dddafa 100644 --- a/qcom/shima-thermal.dtsi +++ b/qcom/shima-thermal.dtsi @@ -2,6 +2,23 @@ #include "lahaina-thermal-modem.dtsi" &qmi_tmd { + modem { + modem_current: modem_current { + qcom,qmi-dev-name = "modem_current"; + #cooling-cells = <2>; + }; + + modem_bw_backoff: modem_bw_backoff { + qcom,qmi-dev-name = "modem_bw_backoff"; + #cooling-cells = <2>; + }; + + modem_wlan_bw: modem_wlan_bw { + qcom,qmi-dev-name = "wlan_bw"; + #cooling-cells = <2>; + }; + }; + cdsp { qcom,instance-id = ; @@ -17,6 +34,38 @@ }; }; +&soc { + qmi-ts-sensors { + modem { + qcom,qmi-sensor-names = "pa", + "pa_1", + "qfe_wtr0", + "modem_tsens", + "qfe_mmw0", + "qfe_mmw1", + "qfe_mmw2", + "qfe_mmw3", + "xo_therm", + "qfe_mmw_streamer0", + "qfe_mmw0_mod", + "qfe_mmw1_mod", + "qfe_mmw2_mod", + "qfe_mmw3_mod", + "qfe_ret_pa0", + "qfe_wtr_pa0", + "qfe_wtr_pa1", + "qfe_wtr_pa2", + "qfe_wtr_pa3", + "sys_therm1", + "modem_tsens1", + "mmw_pa1", + "mmw_pa2", + "mmw_pa3", + "msm_skin_therm"; + }; + }; +}; + &cpufreq_hw { qcom,cpu-isolation { compatible = "qcom,cpu-isolate"; @@ -75,6 +124,24 @@ }; &thermal_zones { + /delete-node/ modem-sdr-mmw-usr; + /delete-node/ modem-ambient-usr; + + msm-skin-therm-usr { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-governor = "user_space"; + thermal-sensors = <&qmi_sensor + (QMI_MODEM_INST_ID+QMI_MSM_SKIN)>; + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "passive"; + }; + }; + }; + aoss-0-usr { polling-delay-passive = <0>; polling-delay = <0>; From 8c4d819e50522b88094e229186f4d9002e1efb86 Mon Sep 17 00:00:00 2001 From: Gopala Krishna Nuthaki Date: Mon, 14 Sep 2020 15:01:01 +0530 Subject: [PATCH 2/3] dt-bindings: thermal: Add support for bandwidth cooling devices Add support for modem_bw_backoff and wlan_bw cooling devices. Change-Id: I71fd52e7e1e26ab5b9c8ab7e10ca3da3f14734e1 --- bindings/thermal/qti-qmi-cdev.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bindings/thermal/qti-qmi-cdev.txt b/bindings/thermal/qti-qmi-cdev.txt index 127a9d8caecf..d22547641936 100644 --- a/bindings/thermal/qti-qmi-cdev.txt +++ b/bindings/thermal/qti-qmi-cdev.txt @@ -41,6 +41,9 @@ Subsystem properties: "modem" -> for processor passive cooling device, "modem_current" -> for current limiting device, "modem_bw" -> for bus bandwidth limiting device, + "modem_bw_backoff" -> for bus bandwidth limit device with + absolute bandwidth reduction from max bandwidth + in 100mbbs resolution, "vbatt_low" -> BCL vbat mitigation device, "mmw0" -> Millimeter wave limiting device 0, "mmw1" -> Millimeter wave limiting device 1, @@ -53,6 +56,7 @@ Subsystem properties: "mmw_skin3" -> MMW skin mitigation device3, "cpr_cold" -> for cpr restriction, "wlan" -> for modem wlan mitigation device, + "wlan_bw" -> for bus bandwidth limiting device, "cdsp_sw" -> for CDSP DCVS mitigation device, "cdsp_hw" -> for CDSP hardware mitigation device, "mmw_skin0_dsc" -> DSC based MMW skin mitigation From adbcb4d69ee738e2699d9287bef8dea4d956a974 Mon Sep 17 00:00:00 2001 From: Gopala Krishna Nuthaki Date: Mon, 14 Sep 2020 15:10:13 +0530 Subject: [PATCH 3/3] dt-bindings: thermal: Add support for modem skin sensor via QMI Add support to expose msm_skin_therm sensor via QMI. Change-Id: I3ee24239314fb25d19267b4199fa2c137a51ffb7 --- bindings/thermal/qti-qmi-sensor.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/bindings/thermal/qti-qmi-sensor.txt b/bindings/thermal/qti-qmi-sensor.txt index 5c8f0bfc7e80..b9a703cf1a14 100644 --- a/bindings/thermal/qti-qmi-sensor.txt +++ b/bindings/thermal/qti-qmi-sensor.txt @@ -61,6 +61,7 @@ Subsystem properties: 28. mmw_pa2 29. mmw_pa3 30. sdr_mmw_therm + 31. msm_skin_therm Example: