From fbc1696da275e13a83335cce877f72664002f17f Mon Sep 17 00:00:00 2001 From: Manaf Meethalavalappu Pallikunhi Date: Wed, 22 Jul 2020 15:57:49 +0530 Subject: [PATCH] ARM: dts: qcom: Enable cold temperature VDD restriction for HOLI Enable cold temperature tsens zeroc interrupt sensor, thermal zone for each zeroc sensor and different railway vdd restriction cooling devices for HOLI. Change-Id: Iebf30020088b926b759b9cd414e85629a74eca37 --- qcom/holi-regulators.dtsi | 24 +++++++++ qcom/holi-thermal.dtsi | 103 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 127 insertions(+) diff --git a/qcom/holi-regulators.dtsi b/qcom/holi-regulators.dtsi index 294ac7b7d39a..17095374b554 100644 --- a/qcom/holi-regulators.dtsi +++ b/qcom/holi-regulators.dtsi @@ -49,6 +49,14 @@ ; qcom,use-voltage-level; }; + + gfx_cdev: gfx-reg-cdev { + compatible = "qcom,regulator-cooling-device"; + regulator-cdev-supply = <&VDD_GFX_LEVEL_AO>; + regulator-levels = ; + #cooling-cells = <2>; + }; }; /* PM6350 L1 - VDD_MX supply */ @@ -93,6 +101,14 @@ ; qcom,use-voltage-level; }; + + mx_cdev: mx-cdev-lvl { + compatible = "qcom,regulator-cooling-device"; + regulator-cdev-supply = <&VDD_MX_LEVEL>; + regulator-levels = ; + #cooling-cells = <2>; + }; }; /* VDD_LPI_CX supply */ @@ -390,6 +406,14 @@ ; qcom,use-voltage-level; }; + + cx_cdev: cx-cdev-lvl { + compatible = "qcom,regulator-cooling-device"; + regulator-cdev-supply = <&VDD_CX_FLOOR_LEVEL>; + regulator-levels = ; + #cooling-cells = <2>; + }; }; rpm-regulator-smpe8 { diff --git a/qcom/holi-thermal.dtsi b/qcom/holi-thermal.dtsi index 606e9e3b2ad4..47ec397c488d 100644 --- a/qcom/holi-thermal.dtsi +++ b/qcom/holi-thermal.dtsi @@ -15,6 +15,7 @@ "tsens-critical", "tsens-0C"; tsens-reinit-wa; + 0C-sensor-num = <16>; #thermal-sensor-cells = <1>; }; @@ -31,6 +32,7 @@ "tsens-critical", "tsens-0C"; tsens-reinit-wa; + 0C-sensor-num = <16>; #thermal-sensor-cells = <1>; }; @@ -62,6 +64,13 @@ }; }; +&rpm_bus { + rpm_smd_cdev: rpm-smd-cdev { + compatible = "qcom,rpm-smd-cooling-device"; + #cooling-cells = <2>; + }; +}; + &cpufreq_hw { qcom,cpu-isolation { compatible = "qcom,cpu-isolate"; @@ -996,4 +1005,98 @@ }; }; }; + + zeroc-0-step { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&tsens0 16>; + thermal-governor = "step_wise"; + + trips { + zeroc_0_trip: active-config0 { + temperature = <1>; + hysteresis = <1>; + type = "passive"; + }; + }; + + cooling-maps { + rpm_smd_cdev { + trip = <&zeroc_0_trip>; + cooling-device = <&rpm_smd_cdev 2 2>; + }; + + cx_vdd_cdev { + trip = <&zeroc_0_trip>; + cooling-device = <&cx_cdev 1 1>; + }; + + mx_vdd_cdev { + trip = <&zeroc_0_trip>; + cooling-device = <&mx_cdev 1 1>; + }; + + gfx_vdd_cdev { + trip = <&zeroc_0_trip>; + cooling-device = <&gfx_cdev 1 1>; + }; + + adsp_vdd_cdev { + trip = <&zeroc_0_trip>; + cooling-device = <&adsp_vdd 1 1>; + }; + + modem_vdd_cdev { + trip = <&zeroc_0_trip>; + cooling-device = <&modem_vdd 1 1>; + }; + }; + }; + + zeroc-1-step { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&tsens1 16>; + thermal-governor = "step_wise"; + + trips { + zeroc_1_trip: active-config0 { + temperature = <1>; + hysteresis = <1>; + type = "passive"; + }; + }; + + cooling-maps { + rpm_smd_cdev { + trip = <&zeroc_1_trip>; + cooling-device = <&rpm_smd_cdev 2 2>; + }; + + cx_vdd_cdev { + trip = <&zeroc_1_trip>; + cooling-device = <&cx_cdev 1 1>; + }; + + mx_vdd_cdev { + trip = <&zeroc_1_trip>; + cooling-device = <&mx_cdev 1 1>; + }; + + gfx_vdd_cdev { + trip = <&zeroc_1_trip>; + cooling-device = <&gfx_cdev 1 1>; + }; + + adsp_vdd_cdev { + trip = <&zeroc_1_trip>; + cooling-device = <&adsp_vdd 1 1>; + }; + + modem_vdd_cdev { + trip = <&zeroc_1_trip>; + cooling-device = <&modem_vdd 1 1>; + }; + }; + }; };