From fbe12053106b7390175371c889123bac5e3aa718 Mon Sep 17 00:00:00 2001 From: TeYuan Wang Date: Fri, 7 Jul 2023 14:20:25 -0700 Subject: [PATCH 1/2] thermal: modify emergency and shutdown threshold Bug: 289752109 Test: adb shell cat /dev/thermal/tz-by-name/skin_therm/trip_point_*_temp Test: adb shell dumpsys android.hardware.thermal.IThermal/default (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:b486f5a3ee3fc3c7ac98e8a51377dce7cbb22a6b) Merged-In: I619fd5a5ee4e668430b4002c58123525e9b14812 Change-Id: I619fd5a5ee4e668430b4002c58123525e9b14812 --- conf/init.felix.rc | 4 ++++ thermal_info_config_felix.json | 10 +++++----- thermal_info_config_proactive_skin_felix.json | 10 +++++----- 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/conf/init.felix.rc b/conf/init.felix.rc index 34059f0..1b5ce74 100644 --- a/conf/init.felix.rc +++ b/conf/init.felix.rc @@ -106,6 +106,10 @@ on property:vendor.mfgapi.touchpanel.permission=1 on property:persist.device_config.vendor_system_native_boot.thermal_proactive_skin=1 setprop vendor.thermal.config "thermal_info_config_proactive_skin.json" +on property:vendor.thermal.link_ready=1 + write /dev/thermal/tz-by-name/skin_therm/trip_point_1_temp 61000 + write /dev/thermal/tz-by-name/skin_therm/trip_point_2_temp 63000 + # Bluetooth on post-fs-data chown bluetooth system /proc/bluetooth/timesync diff --git a/thermal_info_config_felix.json b/thermal_info_config_felix.json index 6bbb5b0..6a35aab 100644 --- a/thermal_info_config_felix.json +++ b/thermal_info_config_felix.json @@ -270,7 +270,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 37.0, 43.0, 45.0, 46.5, 51.0, 54.0], + "HotThreshold":["NAN", 37.0, 43.0, 45.0, 46.5, 53.0, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.4, 1.9, 1.9], "Multiplier":0.001, "SendPowerHint":true, @@ -285,7 +285,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", "NAN", "NAN", "NAN", "NAN", 52.5, "NAN"], + "HotThreshold":["NAN", "NAN", "NAN", "NAN", "NAN", 55.0, "NAN"], "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 0.0, 1.9, 0.0], "Multiplier":0.001, "PollingDelay":300000, @@ -301,7 +301,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 37.0, 39.0, 41.0, 46.5, 51.0, 54.0], + "HotThreshold":["NAN", 37.0, 39.0, 41.0, 46.5, 53.0, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.4, 1.9, 1.9], "Multiplier":0.001, "PollingDelay":300000, @@ -362,7 +362,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 37.0, 43.0, 45.0, 46.5, 51.0, 54.0], + "HotThreshold":["NAN", 37.0, 43.0, 45.0, 46.5, 53.0, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.4, 1.9, 1.9], "Multiplier":0.001, "PollingDelay":300000, @@ -427,7 +427,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 25.0, 39.0, 41.0, 45.0, 46.5, 54.0], + "HotThreshold":["NAN", 25.0, 39.0, 41.0, 45.0, 46.5, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.9, 1.4, 1.9], "Multiplier":0.001, "PollingDelay":60000, diff --git a/thermal_info_config_proactive_skin_felix.json b/thermal_info_config_proactive_skin_felix.json index 1b7c446..1a6321f 100644 --- a/thermal_info_config_proactive_skin_felix.json +++ b/thermal_info_config_proactive_skin_felix.json @@ -270,7 +270,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 37.0, 41.0, 45.0, 46.5, 51.0, 54.0], + "HotThreshold":["NAN", 37.0, 41.0, 45.0, 46.5, 53.0, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.4, 1.9, 1.9], "Multiplier":0.001, "SendPowerHint":true, @@ -285,7 +285,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", "NAN", "NAN", "NAN", "NAN", 52.5, "NAN"], + "HotThreshold":["NAN", "NAN", "NAN", "NAN", "NAN", 55.0, "NAN"], "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 0.0, 1.9, 0.0], "Multiplier":0.001, "PollingDelay":300000, @@ -301,7 +301,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 37.0, 39.0, 41.0, 46.5, 51.0, 54.0], + "HotThreshold":["NAN", 37.0, 39.0, 41.0, 46.5, 53.0, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.4, 1.9, 1.9], "Multiplier":0.001, "PollingDelay":300000, @@ -362,7 +362,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 37.0, 43.0, 45.0, 46.5, 51.0, 54.0], + "HotThreshold":["NAN", 37.0, 43.0, 45.0, 46.5, 53.0, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.4, 1.9, 1.9], "Multiplier":0.001, "PollingDelay":300000, @@ -427,7 +427,7 @@ "Formula":"MAXIMUM", "Combination":["VIRTUAL-SKIN"], "Coefficient":[1.0], - "HotThreshold":["NAN", 25.0, 39.0, 41.0, 45.0, 46.5, 54.0], + "HotThreshold":["NAN", 25.0, 39.0, 41.0, 45.0, 46.5, 57.0], "HotHysteresis":[0.0, 1.9, 1.9, 1.9, 1.9, 1.4, 1.9], "Multiplier":0.001, "PollingDelay":60000, From 6c2cd58841b3e8e93041573ec17f8e748e90355c Mon Sep 17 00:00:00 2001 From: TeYuan Wang Date: Wed, 5 Jul 2023 23:26:34 -0700 Subject: [PATCH 2/2] thermal: Update VSKIN equation V06.2 Bug: 289752109 Test: adb shell dumpsys android.hardware.thermal.IThermal/default (cherry picked from commit 68182cb0cbe267f6162b33b37f09ee80e314010e) (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:6a3ea3d37c70c8d3b47310c70c1c1d5dbc64e1f8) Merged-In: Ib957fae2db39f421c0b11c3b3b106f3ec333e4f5 Change-Id: Ib957fae2db39f421c0b11c3b3b106f3ec333e4f5 --- thermal_info_config_charge_felix.json | 6 +++--- thermal_info_config_felix.json | 8 ++++---- thermal_info_config_proactive_skin_felix.json | 8 ++++---- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/thermal_info_config_charge_felix.json b/thermal_info_config_charge_felix.json index ceb9181..80cd32c 100644 --- a/thermal_info_config_charge_felix.json +++ b/thermal_info_config_charge_felix.json @@ -204,9 +204,9 @@ "Hidden":true, "VirtualSensor":true, "Formula":"WEIGHTED_AVG", - "Combination":["neutral_therm", "skin_therm", "usb_pwr_therm", "usb_pwr_therm2", "inner_disp_therm"], - "Coefficient":[0.15, 1.05, -0.65, 1, -0.55], - "Offset":3540, + "Combination":["quiet_therm", "skin_therm", "usb_pwr_therm"], + "Coefficient":[0.429, 0.314, 0.205], + "Offset":2600, "Multiplier":0.001 }, { diff --git a/thermal_info_config_felix.json b/thermal_info_config_felix.json index 6a35aab..e55585e 100644 --- a/thermal_info_config_felix.json +++ b/thermal_info_config_felix.json @@ -210,9 +210,9 @@ "Hidden":true, "VirtualSensor":true, "Formula":"WEIGHTED_AVG", - "Combination":["neutral_therm", "skin_therm", "usb_pwr_therm", "usb_pwr_therm2", "inner_disp_therm"], - "Coefficient":[0.15, 1.05, -0.65, 1, -0.55], - "Offset":3540, + "Combination":["quiet_therm", "skin_therm", "usb_pwr_therm"], + "Coefficient":[0.429, 0.314, 0.205], + "Offset":2600, "Multiplier":0.001 }, { @@ -238,7 +238,7 @@ { "Name":"VIRTUAL-SKIN", "Type":"SKIN", - "Version":"0.5", + "Version":"6.2", "VirtualSensor":true, "TriggerSensor":"skin_therm", "Formula":"MAXIMUM", diff --git a/thermal_info_config_proactive_skin_felix.json b/thermal_info_config_proactive_skin_felix.json index 1a6321f..a603558 100644 --- a/thermal_info_config_proactive_skin_felix.json +++ b/thermal_info_config_proactive_skin_felix.json @@ -210,9 +210,9 @@ "Hidden":true, "VirtualSensor":true, "Formula":"WEIGHTED_AVG", - "Combination":["neutral_therm", "skin_therm", "usb_pwr_therm", "usb_pwr_therm2", "inner_disp_therm"], - "Coefficient":[0.15, 1.05, -0.65, 1, -0.55], - "Offset":3540, + "Combination":["quiet_therm", "skin_therm", "usb_pwr_therm"], + "Coefficient":[0.429, 0.314, 0.205], + "Offset":2600, "Multiplier":0.001 }, { @@ -238,7 +238,7 @@ { "Name":"VIRTUAL-SKIN", "Type":"SKIN", - "Version":"0.5", + "Version":"6.2", "VirtualSensor":true, "TriggerSensor":"skin_therm", "Formula":"MAXIMUM",