From 3f4c1166f6d262b1d28017a6f64a9f7e5d3984fb Mon Sep 17 00:00:00 2001 From: TeYuan Wang Date: Fri, 6 Aug 2021 16:11:16 +0800 Subject: [PATCH 1/3] thermal: add TPU throttling for SKIN thermal optimization Bug: 188701596 Test: Verified by emul temp Change-Id: I37300afd1aa9678b22e7108c918b515f83347f37 --- thermal_info_config_oriole.json | 9 +++++++++ thermal_info_config_raven.json | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/thermal_info_config_oriole.json b/thermal_info_config_oriole.json index 4f4e670..68b8792 100644 --- a/thermal_info_config_oriole.json +++ b/thermal_info_config_oriole.json @@ -399,6 +399,10 @@ "CdevFloorWithPowerLink": [0, 1, 1, 2, 5, 5, 5], "ReleaseLogic": "RELEASE_TO_FLOOR", "ThrottlingWithPowerLink":true + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 1, 2, 3, 4, 4, 4] } ] }, @@ -1076,6 +1080,11 @@ { "Name":"usbc-port", "Type":"BATTERY" + }, + { + "Name":"tpu_cooling", + "Type":"NPU", + "WritePath":"/dev/thermal/cdev-by-name/tpu_cooling/user_vote" } ], "PowerRails":[ diff --git a/thermal_info_config_raven.json b/thermal_info_config_raven.json index d5d2b00..786cd56 100644 --- a/thermal_info_config_raven.json +++ b/thermal_info_config_raven.json @@ -399,6 +399,10 @@ "CdevFloorWithPowerLink": [0, 1, 1, 2, 3, 4, 4], "ReleaseLogic": "RELEASE_TO_FLOOR", "ThrottlingWithPowerLink":true + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 1, 2, 3, 4, 4, 4] } ] }, @@ -1080,6 +1084,11 @@ { "Name":"usbc-port", "Type":"BATTERY" + }, + { + "Name":"tpu_cooling", + "Type":"NPU", + "WritePath":"/dev/thermal/cdev-by-name/tpu_cooling/user_vote" } ], "PowerRails":[ From f7e42d69e021f95fd3d7606cc5ed42480ba63d53 Mon Sep 17 00:00:00 2001 From: George Lee Date: Fri, 6 Aug 2021 14:16:42 -0700 Subject: [PATCH 2/3] bcl: Update soft_ocp cooling device Add cooling device for soft_ocp_warn. Bug: 188701596 Test: Local test and check trip point Signed-off-by: George Lee Change-Id: Ife680d79467d9a07e14cc890d60f35aba02c0b65 --- thermal_info_config_oriole.json | 16 ++++++++++++++-- thermal_info_config_oriole_WHI_A.json | 21 +++++++++++++++++++-- thermal_info_config_raven.json | 16 ++++++++++++++-- 3 files changed, 47 insertions(+), 6 deletions(-) diff --git a/thermal_info_config_oriole.json b/thermal_info_config_oriole.json index 68b8792..cb9757a 100644 --- a/thermal_info_config_oriole.json +++ b/thermal_info_config_oriole.json @@ -897,7 +897,13 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true + "Monitor":true, + "BindedCdevInfo": [ + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_gpu", @@ -997,7 +1003,13 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true + "Monitor":true, + "BindedCdevInfo": [ + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"soft_ocp_gpu", diff --git a/thermal_info_config_oriole_WHI_A.json b/thermal_info_config_oriole_WHI_A.json index ba7f348..3683359 100644 --- a/thermal_info_config_oriole_WHI_A.json +++ b/thermal_info_config_oriole_WHI_A.json @@ -570,7 +570,13 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true + "Monitor":true, + "BindedCdevInfo": [ + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_gpu", @@ -670,7 +676,13 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true + "Monitor":true, + "BindedCdevInfo": [ + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"soft_ocp_gpu", @@ -737,6 +749,11 @@ "Type":"GPU", "WritePath":"/dev/thermal/cdev-by-name/thermal-gpufreq-0/user_vote", "State2Power":["2580", "2033", "1427", "826", "358"] + }, + { + "Name":"tpu_cooling", + "Type":"NPU", + "WritePath":"/dev/thermal/cdev-by-name/tpu_cooling/user_vote" } ], "PowerRails":[ diff --git a/thermal_info_config_raven.json b/thermal_info_config_raven.json index 786cd56..5bec3b0 100644 --- a/thermal_info_config_raven.json +++ b/thermal_info_config_raven.json @@ -897,7 +897,13 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true + "Monitor":true, + "BindedCdevInfo": [ + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_gpu", @@ -997,7 +1003,13 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true + "Monitor":true, + "BindedCdevInfo": [ + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"soft_ocp_gpu", From 8fadec702cb0981dae8ad4bc541d8c79414aaa6c Mon Sep 17 00:00:00 2001 From: George Lee Date: Tue, 10 Aug 2021 16:58:09 -0700 Subject: [PATCH 3/3] bcl: lower ocp_warn for tpu and gpu Bug: 181348043 Test: Local test and verify trip point Signed-off-by: George Lee Change-Id: Ifea3ea71e658b1ca0d9d87c2ca1cdb16b290a6b9 --- thermal_info_config_oriole.json | 8 ++++---- thermal_info_config_oriole_WHI_A.json | 8 ++++---- thermal_info_config_raven.json | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/thermal_info_config_oriole.json b/thermal_info_config_oriole.json index cb9757a..97d0b1c 100644 --- a/thermal_info_config_oriole.json +++ b/thermal_info_config_oriole.json @@ -882,7 +882,7 @@ "NAN", "NAN", "NAN", - 10500, + 8500, "NAN", "NAN" ], @@ -913,7 +913,7 @@ "NAN", "NAN", "NAN", - 12000, + 9000, "NAN", "NAN" ], @@ -988,7 +988,7 @@ "NAN", "NAN", "NAN", - 8500, + 7500, "NAN", "NAN" ], @@ -1019,7 +1019,7 @@ "NAN", "NAN", "NAN", - 9000, + 8000, "NAN", "NAN" ], diff --git a/thermal_info_config_oriole_WHI_A.json b/thermal_info_config_oriole_WHI_A.json index 3683359..6094307 100644 --- a/thermal_info_config_oriole_WHI_A.json +++ b/thermal_info_config_oriole_WHI_A.json @@ -555,7 +555,7 @@ "NAN", "NAN", "NAN", - 10500, + 8500, "NAN", "NAN" ], @@ -586,7 +586,7 @@ "NAN", "NAN", "NAN", - 12000, + 9000, "NAN", "NAN" ], @@ -661,7 +661,7 @@ "NAN", "NAN", "NAN", - 8500, + 7500, "NAN", "NAN" ], @@ -692,7 +692,7 @@ "NAN", "NAN", "NAN", - 9000, + 8000, "NAN", "NAN" ], diff --git a/thermal_info_config_raven.json b/thermal_info_config_raven.json index 5bec3b0..cb769fb 100644 --- a/thermal_info_config_raven.json +++ b/thermal_info_config_raven.json @@ -882,7 +882,7 @@ "NAN", "NAN", "NAN", - 10500, + 8500, "NAN", "NAN" ], @@ -913,7 +913,7 @@ "NAN", "NAN", "NAN", - 12000, + 9000, "NAN", "NAN" ], @@ -988,7 +988,7 @@ "NAN", "NAN", "NAN", - 8500, + 7500, "NAN", "NAN" ], @@ -1019,7 +1019,7 @@ "NAN", "NAN", "NAN", - 9000, + 8000, "NAN", "NAN" ],