From c0f618e35659d69d67cbf3bbf76a07bbfad266c9 Mon Sep 17 00:00:00 2001 From: Qais Yousef Date: Mon, 27 Feb 2023 15:12:54 +0000 Subject: [PATCH] powerhint.json: Update uclamp_min hint to account for margin Upstream has fixed relationship between uclamp_min and margin which means uclamp_min value between 80-100% of capacity of the CPU is a valid value and will not cause upmigration. To keep the current hints in powerhint.json the same, we must update uclamp_min to be capacity_orig_of(medium_cpu) + 1. This change is dependent on uclamp vs fits margin in GKI, vendor modules. And an improvement in sched_pixel to ignore the 25% boost if the only reason to request the frequency is uclamp_min. To cater for the later - we multiply each uclamp_min value with 1.25 - except ones that look intentionally set around capacity boundaries. Bug: 261695590 Test: PtsUiBench Signed-off-by: Qais Yousef Change-Id: I4689a953734b6049da14ec13ef399c1c686b1024 --- powerhint.json | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/powerhint.json b/powerhint.json index 127c21e..b604a78 100644 --- a/powerhint.json +++ b/powerhint.json @@ -150,7 +150,7 @@ "Name": "CAMUClampBoost", "Path": "/proc/vendor_sched/cam_uclamp_min", "Values": [ - "612", + "764", "0" ], "ResetOnInit": true @@ -159,7 +159,7 @@ "Name": "TAUClampBoost", "Path": "/proc/vendor_sched/ta_uclamp_min", "Values": [ - "612", + "764", "1" ], "ResetOnInit": true @@ -177,8 +177,8 @@ "Name": "MLUclampBoost", "Path": "/proc/vendor_sched/nnapi_uclamp_min", "Values": [ - "180", - "650" + "225", + "813" ], "DefaultIndex": 0, "ResetOnInit": true @@ -654,7 +654,7 @@ "PowerHint": "LAUNCH", "Node": "TAUClampBoost", "Duration": 5000, - "Value": "612" + "Value": "764" }, { "PowerHint": "LAUNCH", @@ -779,7 +779,7 @@ "PowerHint": "CAMERA_LAUNCH", "Node": "CAMUClampBoost", "Duration": 1000, - "Value": "612" + "Value": "764" }, { "PowerHint": "CAMERA_LAUNCH", @@ -1986,7 +1986,7 @@ "PowerHint": "ML_ACC", "Node": "MLUclampBoost", "Duration": 2000, - "Value": "650" + "Value": "813" }, { "PowerHint": "ML_ACC", @@ -2008,8 +2008,8 @@ "PID_Do": 500.0, "PID_Du": 0.0, "UclampMin_On": true, - "UclampMin_Init": 185, - "UclampMin_High": 384, + "UclampMin_Init": 232, + "UclampMin_High": 480, "UclampMin_Low": 2, "SamplingWindow_P": 1, "SamplingWindow_I": 0, @@ -2032,8 +2032,8 @@ "PID_Do": 500.0, "PID_Du": 0.0, "UclampMin_On": true, - "UclampMin_Init": 129, - "UclampMin_High": 384, + "UclampMin_Init": 162, + "UclampMin_High": 480, "UclampMin_Low": 2, "SamplingWindow_P": 1, "SamplingWindow_I": 0, @@ -2056,8 +2056,8 @@ "PID_Do": 500.0, "PID_Du": 0.0, "UclampMin_On": true, - "UclampMin_Init": 129, - "UclampMin_High": 384, + "UclampMin_Init": 162, + "UclampMin_High": 480, "UclampMin_Low": 2, "SamplingWindow_P": 1, "SamplingWindow_I": 0, @@ -2083,9 +2083,9 @@ "SamplingWindow_I": 1, "SamplingWindow_D": 1, "UclampMin_On": true, - "UclampMin_Init": 200, - "UclampMin_High": 157, - "UclampMin_Low": 157, + "UclampMin_Init": 250, + "UclampMin_High": 197, + "UclampMin_Low": 197, "ReportingRateLimitNs": 1, "EarlyBoost_On": false, "EarlyBoost_TimeFactor": 0.0, @@ -2107,9 +2107,9 @@ "SamplingWindow_I": 1, "SamplingWindow_D": 1, "UclampMin_On": true, - "UclampMin_Init": 200, - "UclampMin_High": 42, - "UclampMin_Low": 42, + "UclampMin_Init": 250, + "UclampMin_High": 53, + "UclampMin_Low": 53, "ReportingRateLimitNs": 1, "EarlyBoost_On": false, "EarlyBoost_TimeFactor": 0.0, @@ -2131,7 +2131,7 @@ "SamplingWindow_I": 1, "SamplingWindow_D": 1, "UclampMin_On": true, - "UclampMin_Init": 200, + "UclampMin_Init": 250, "UclampMin_High": 0, "UclampMin_Low": 0, "ReportingRateLimitNs": 1,