From 810337a8f74b7fa1fa0ec80edccaaebfcdc737d7 Mon Sep 17 00:00:00 2001 From: "Ali K. Zadeh" Date: Wed, 28 Sep 2022 17:24:53 +0000 Subject: [PATCH] Disable PMU at the start of camera launch A recent change (ag/20028064) has caused regression in GCA launch time due to activation of PMU at the camera launch time, and capping the CPU frequency. This CL prevents PMU activation for as long as we are in powerhints or power-boosts related to camera launch (LAUNCH, CAMERA_LAUNCH, CAMERA_LAUNCH_EXTENDED). Bug: 248718485 Test: Perfetto trace Change-Id: I6d88e4ccaf6790578223202ee69c105360cfc559 --- powerhint-cheetah-a0.json | 47 +++++++++++++++++++++++++++++---------- powerhint-cheetah.json | 47 +++++++++++++++++++++++++++++---------- powerhint-panther-a0.json | 47 +++++++++++++++++++++++++++++---------- powerhint-panther.json | 47 +++++++++++++++++++++++++++++---------- 4 files changed, 140 insertions(+), 48 deletions(-) diff --git a/powerhint-cheetah-a0.json b/powerhint-cheetah-a0.json index 1207c8d..299b45c 100644 --- a/powerhint-cheetah-a0.json +++ b/powerhint-cheetah-a0.json @@ -653,6 +653,17 @@ "Duration": 5000, "Value": "0" }, + { + "PowerHint": "LAUNCH", + "Type": "DoHint", + "Value": "LAUNCH_PMU" + }, + { + "PowerHint": "LAUNCH_PMU", + "Node": "PMU_POLL", + "Duration": 3000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH", "Node": "MemFreq", @@ -713,6 +724,12 @@ "Duration": 1000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH", + "Node": "PMU_POLL", + "Duration": 1000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH_EXTENDED", "Node": "CPUBigClusterMaxFreq", @@ -737,6 +754,12 @@ "Duration": 2000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH_EXTENDED", + "Node": "PMU_POLL", + "Duration": 2000, + "Value": "0" + }, { "PowerHint": "CAMERA_THERMAL_CPU_THROTTLE", "Node": "CPUBigClusterMaxFreq", @@ -1097,12 +1120,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1145,6 +1162,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "EM_Profile", @@ -1211,12 +1234,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_STANDARD", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1259,6 +1276,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_STANDARD", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "EM_Profile", diff --git a/powerhint-cheetah.json b/powerhint-cheetah.json index a752ab3..9362996 100644 --- a/powerhint-cheetah.json +++ b/powerhint-cheetah.json @@ -695,6 +695,17 @@ "Duration": 5000, "Value": "0" }, + { + "PowerHint": "LAUNCH", + "Type": "DoHint", + "Value": "LAUNCH_PMU" + }, + { + "PowerHint": "LAUNCH_PMU", + "Node": "PMU_POLL", + "Duration": 3000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH", "Node": "MemFreq", @@ -755,6 +766,12 @@ "Duration": 1000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH", + "Node": "PMU_POLL", + "Duration": 1000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH_EXTENDED", "Node": "CPUBigClusterMaxFreq", @@ -779,6 +796,12 @@ "Duration": 2000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH_EXTENDED", + "Node": "PMU_POLL", + "Duration": 2000, + "Value": "0" + }, { "PowerHint": "CAMERA_THERMAL_CPU_THROTTLE", "Node": "CPUBigClusterMaxFreq", @@ -1139,12 +1162,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1187,6 +1204,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "EM_Profile", @@ -1253,12 +1276,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_STANDARD", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1301,6 +1318,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_STANDARD", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "EM_Profile", diff --git a/powerhint-panther-a0.json b/powerhint-panther-a0.json index a5daca8..20e6528 100644 --- a/powerhint-panther-a0.json +++ b/powerhint-panther-a0.json @@ -642,6 +642,17 @@ "Duration": 5000, "Value": "0" }, + { + "PowerHint": "LAUNCH", + "Type": "DoHint", + "Value": "LAUNCH_PMU" + }, + { + "PowerHint": "LAUNCH_PMU", + "Node": "PMU_POLL", + "Duration": 3000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH", "Node": "MemFreq", @@ -702,6 +713,12 @@ "Duration": 1000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH", + "Node": "PMU_POLL", + "Duration": 1000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH_EXTENDED", "Node": "CPUBigClusterMaxFreq", @@ -726,6 +743,12 @@ "Duration": 2000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH_EXTENDED", + "Node": "PMU_POLL", + "Duration": 2000, + "Value": "0" + }, { "PowerHint": "CAMERA_THERMAL_CPU_THROTTLE", "Node": "CPUBigClusterMaxFreq", @@ -984,12 +1007,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1032,6 +1049,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "EM_Profile", @@ -1098,12 +1121,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_STANDARD", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1146,6 +1163,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_STANDARD", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "EM_Profile", diff --git a/powerhint-panther.json b/powerhint-panther.json index 4298584..4fbae02 100644 --- a/powerhint-panther.json +++ b/powerhint-panther.json @@ -664,6 +664,17 @@ "Duration": 5000, "Value": "0" }, + { + "PowerHint": "LAUNCH", + "Type": "DoHint", + "Value": "LAUNCH_PMU" + }, + { + "PowerHint": "LAUNCH_PMU", + "Node": "PMU_POLL", + "Duration": 3000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH", "Node": "MemFreq", @@ -724,6 +735,12 @@ "Duration": 1000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH", + "Node": "PMU_POLL", + "Duration": 1000, + "Value": "0" + }, { "PowerHint": "CAMERA_LAUNCH_EXTENDED", "Node": "CPUBigClusterMaxFreq", @@ -748,6 +765,12 @@ "Duration": 2000, "Value": "0" }, + { + "PowerHint": "CAMERA_LAUNCH_EXTENDED", + "Node": "PMU_POLL", + "Duration": 2000, + "Value": "0" + }, { "PowerHint": "CAMERA_THERMAL_CPU_THROTTLE", "Node": "CPUBigClusterMaxFreq", @@ -1006,12 +1029,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1054,6 +1071,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "EM_Profile", @@ -1120,12 +1143,6 @@ "Duration": 0, "Value": "0" }, - { - "PowerHint": "CAMERA_STREAMING_STANDARD", - "Node": "PMU_POLL", - "Duration": 0, - "Value": "1" - }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "PMU_LIT_LCPI_THRESHOLD", @@ -1168,6 +1185,12 @@ "Duration": 0, "Value": "50" }, + { + "PowerHint": "CAMERA_STREAMING_STANDARD", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, { "PowerHint": "CAMERA_STREAMING_STANDARD", "Node": "EM_Profile",