From 2c94505351705e741b161c2807786516ae918eee Mon Sep 17 00:00:00 2001 From: sashwinbalaji Date: Fri, 19 Apr 2024 03:33:46 +0800 Subject: [PATCH] thermal: read thermistor temperature from upstream sysfs tz_temp callback will invoke thermal_zone_device_update and return the cached temp from thermal core. However, during device resume, the cached temp may be reset to INVALID number before being returned. So, change the reading path to upstream temp_show which will return the temperature from thermistor driver directly. Current Issue: We are observing lot of extreme low temp for vskin being reported and with all coefficients being positive the only way negative vskin is reported is when thermistors report very low temp. Since abnormality logging is rate limited this reduces the amount of ml model issues reported. Bug: 323987378 Test: Local build and verify lshal Change-Id: I2445f9d654c2a86c9507bf1654dc44f3b765c889 --- thermal/thermal_info_config_charge_comet.json | 6 ------ thermal/thermal_info_config_comet.json | 8 -------- 2 files changed, 14 deletions(-) diff --git a/thermal/thermal_info_config_charge_comet.json b/thermal/thermal_info_config_charge_comet.json index e8b7e55..8ab9979 100644 --- a/thermal/thermal_info_config_charge_comet.json +++ b/thermal/thermal_info_config_charge_comet.json @@ -4,7 +4,6 @@ "Name": "soc_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 34.29, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/soc_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -13,7 +12,6 @@ "Name": "rffe_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 35.07, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/rffe_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -22,7 +20,6 @@ "Name": "modem_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 33.31, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/modem_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -31,7 +28,6 @@ "Name": "gnss_tcxo_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 32.08, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/gnss_tcxo_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -40,7 +36,6 @@ "Name": "usb_conn_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 46.0, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/usb_conn_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -49,7 +44,6 @@ "Name": "charger_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 34.89, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/charger_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 diff --git a/thermal/thermal_info_config_comet.json b/thermal/thermal_info_config_comet.json index bb699f5..48361f6 100644 --- a/thermal/thermal_info_config_comet.json +++ b/thermal/thermal_info_config_comet.json @@ -44,7 +44,6 @@ "Name": "soc_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 34.29, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/soc_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -53,7 +52,6 @@ "Name": "rffe_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 35.07, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/rffe_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -62,7 +60,6 @@ "Name": "modem_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 33.31, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/modem_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -71,7 +68,6 @@ "Name": "gnss_tcxo_therm", "Type": "UNKNOWN", "HotThreshold": ["NaN", 32.08, "NaN", "NaN", "NaN", "NaN", "NaN"], - "TempPath": "/dev/thermal/tz-by-name/gnss_tcxo_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -80,7 +76,6 @@ "Name": "usb_conn_therm", "Type": "UNKNOWN", "HotThreshold": ["NAN", 30.79, "NAN", "NAN", "NAN", "NAN", "NAN"], - "TempPath": "/dev/thermal/tz-by-name/usb_conn_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -89,7 +84,6 @@ "Name": "charger_therm", "Type": "UNKNOWN", "HotThreshold": ["NAN", 34.89, "NAN", "NAN", "NAN", "NAN", "NAN"], - "TempPath": "/dev/thermal/tz-by-name/charger_therm/tz_temp", "Multiplier": 0.001, "PollingDelay": 300000, "PassiveDelay": 7000 @@ -97,13 +91,11 @@ { "Name": "inner_display_therm", "Type": "UNKNOWN", - "TempPath": "/dev/thermal/tz-by-name/inner_display_therm/tz_temp", "Multiplier": 0.001 }, { "Name": "display_therm", "Type": "UNKNOWN", - "TempPath": "/dev/thermal/tz-by-name/display_therm/tz_temp", "Multiplier": 0.001 }, {