From 70363dbbfa08da53cf9eb5605b0d8b0618a8f42f Mon Sep 17 00:00:00 2001 From: Paulsu Su Date: Thu, 22 Aug 2024 02:32:49 +0000 Subject: [PATCH 1/2] Update mismatched frequency for husky and shiba - Update freq for legacy mismatched frequency with the rule of scaling_max_freq will automatically round down, scaling_min_freq will round up. All powerhint behavior should not change. - Remove some min/max frequency not used in any nodes. Bug: 361294204 FLAG: NONE powerhint do not need flag Change-Id: I0242977f05f859ad5c3c38673579e296e74c78ca --- perf/powerhint-husky.json | 62 +++++++++++++++++---------------------- perf/powerhint-shiba.json | 62 +++++++++++++++++---------------------- 2 files changed, 54 insertions(+), 70 deletions(-) diff --git a/perf/powerhint-husky.json b/perf/powerhint-husky.json index f464ced..fab84f0 100644 --- a/perf/powerhint-husky.json +++ b/perf/powerhint-husky.json @@ -81,8 +81,8 @@ "Values": [ "9999999", "1098000", - "1475000", - "975000", + "1425000", + "955000", "1197000", "1328000", "1548000", @@ -96,7 +96,7 @@ "Path": "/sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq", "Values": [ "9999999", - "1475000", + "1548000", "1197000", "0" ], @@ -120,14 +120,11 @@ "9999999", "2253000", "2130000", - "1082000", - "1221000", - "1418000", "910000", "1328000", - "1622000", + "1572000", "1836000", - "1999000" + "1945000" ], "DefaultIndex": 0, "ResetOnInit": true @@ -140,7 +137,6 @@ "2253000", "2130000", "1836000", - "1221000", "0" ], "ResetOnInit": true @@ -165,14 +161,11 @@ "2704000", "2507000", "2252000", - "893000", - "1328000", - "1852000", - "1164000", + "1298000", "1557000", "1745000", "2049000", - "2409000" + "2363000" ], "DefaultIndex": 0, "ResetOnInit": true @@ -185,8 +178,7 @@ "2704000", "2507000", "2252000", - "1852000", - "1164000", + "1885000", "0" ], "ResetOnInit": true @@ -737,7 +729,7 @@ "Path": "/sys/devices/system/cpu/cpufreq/policy8/sched_pixel/limit_frequency", "Values": [ "2363000", - "1852000", + "1745000", "1298000" ], "DefaultIndex": 0 @@ -1341,7 +1333,7 @@ "PowerHint": "CAMERA_LAUNCH", "Node": "CPUBigClusterMinFreq", "Duration": 1000, - "Value": "1852000" + "Value": "1885000" }, { "PowerHint": "CAMERA_LAUNCH", @@ -1365,7 +1357,7 @@ "PowerHint": "CAMERA_LAUNCH", "Node": "CPULittleClusterMinFreq", "Duration": 1000, - "Value": "1475000" + "Value": "1548000" }, { "PowerHint": "CAMERA_LAUNCH", @@ -1455,19 +1447,19 @@ "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", "Node": "CPUBigClusterMaxFreq", "Duration": 3000, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", "Node": "CPUMidClusterMaxFreq", "Duration": 3000, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", "Node": "CPULittleClusterMaxFreq", "Duration": 3000, - "Value": "1475000" + "Value": "1425000" }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", @@ -2253,19 +2245,19 @@ "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPUBigClusterMaxFreq", "Duration": 0, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPUMidClusterMaxFreq", "Duration": 0, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPULittleClusterMaxFreq", "Duration": 0, - "Value": "1475000" + "Value": "1425000" }, { "PowerHint": "CAMERA_STREAMING_LOW", @@ -2525,7 +2517,7 @@ "PowerHint": "LOW_POWER_LITTLE_CLUSTER_50", "Node": "CPULittleClusterMaxFreq", "Duration": 3600000, - "Value": "975000" + "Value": "955000" }, { "PowerHint": "LOW_POWER_LITTLE_CLUSTER_60", @@ -2567,7 +2559,7 @@ "PowerHint": "LOW_POWER_MID_CLUSTER_70", "Node": "CPUMidClusterMaxFreq", "Duration": 3600000, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "LOW_POWER_MID_CLUSTER_80", @@ -2579,13 +2571,13 @@ "PowerHint": "LOW_POWER_MID_CLUSTER_90", "Node": "CPUMidClusterMaxFreq", "Duration": 3600000, - "Value": "1999000" + "Value": "1945000" }, { "PowerHint": "LOW_POWER_CPU_50", "Node": "CPUBigClusterMaxFreq", "Duration": 3600000, - "Value": "1328000" + "Value": "1298000" }, { "PowerHint": "LOW_POWER_CPU_60", @@ -2609,7 +2601,7 @@ "PowerHint": "LOW_POWER_CPU_90", "Node": "CPUBigClusterMaxFreq", "Duration": 3600000, - "Value": "2409000" + "Value": "2363000" }, { "PowerHint": "LOW_POWER", @@ -2890,7 +2882,7 @@ "PowerHint": "FACE_UNLOCK_BOOST", "Node": "CPUBigClusterMinFreq", "Duration": 500, - "Value": "1852000" + "Value": "1885000" }, { "PowerHint": "FACE_UNLOCK_BOOST", @@ -2992,7 +2984,7 @@ "PowerHint": "CAMERA_PROJECT11", "Node": "PMU_BIG_LIMIT_FREQ", "Duration": 0, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_PROJECT11", @@ -3040,19 +3032,19 @@ "PowerHint": "CAMERA_PROJECT11", "Node": "CPUBigClusterMaxFreq", "Duration": 0, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_PROJECT11", "Node": "CPUMidClusterMaxFreq", "Duration": 0, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "CAMERA_PROJECT11", "Node": "CPULittleClusterMaxFreq", "Duration": 0, - "Value": "1475000" + "Value": "1425000" }, { "PowerHint": "CAMERA_PROJECT11", diff --git a/perf/powerhint-shiba.json b/perf/powerhint-shiba.json index 26f7ea9..8ed56c4 100644 --- a/perf/powerhint-shiba.json +++ b/perf/powerhint-shiba.json @@ -81,8 +81,8 @@ "Values": [ "9999999", "1098000", - "1475000", - "975000", + "1425000", + "955000", "1197000", "1328000", "1548000", @@ -96,7 +96,7 @@ "Path": "/sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq", "Values": [ "9999999", - "1475000", + "1548000", "1197000", "0" ], @@ -118,14 +118,11 @@ "Path": "/sys/devices/system/cpu/cpu4/cpufreq/scaling_max_freq", "Values": [ "9999999", - "1082000", - "1221000", - "1418000", "910000", "1328000", - "1622000", + "1572000", "1836000", - "1999000" + "1945000" ], "DefaultIndex": 0, "ResetOnInit": true @@ -136,7 +133,6 @@ "Values": [ "9999999", "1836000", - "1221000", "0" ], "ResetOnInit": true @@ -158,14 +154,11 @@ "Path": "/sys/devices/system/cpu/cpu8/cpufreq/scaling_max_freq", "Values": [ "9999999", - "893000", - "1328000", - "1852000", - "1164000", + "1298000", "1557000", "1745000", "2049000", - "2409000" + "2363000" ], "DefaultIndex": 0, "ResetOnInit": true @@ -175,8 +168,7 @@ "Path": "/sys/devices/system/cpu/cpu8/cpufreq/scaling_min_freq", "Values": [ "9999999", - "1852000", - "1164000", + "1885000", "0" ], "ResetOnInit": true @@ -737,7 +729,7 @@ "Path": "/sys/devices/system/cpu/cpufreq/policy8/sched_pixel/limit_frequency", "Values": [ "2363000", - "1852000", + "1745000", "1298000" ], "DefaultIndex": 0 @@ -1347,7 +1339,7 @@ "PowerHint": "CAMERA_LAUNCH", "Node": "CPUBigClusterMinFreq", "Duration": 1000, - "Value": "1852000" + "Value": "1885000" }, { "PowerHint": "CAMERA_LAUNCH", @@ -1371,7 +1363,7 @@ "PowerHint": "CAMERA_LAUNCH", "Node": "CPULittleClusterMinFreq", "Duration": 1000, - "Value": "1475000" + "Value": "1548000" }, { "PowerHint": "CAMERA_LAUNCH", @@ -1461,19 +1453,19 @@ "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", "Node": "CPUBigClusterMaxFreq", "Duration": 3000, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", "Node": "CPUMidClusterMaxFreq", "Duration": 3000, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", "Node": "CPULittleClusterMaxFreq", "Duration": 3000, - "Value": "1475000" + "Value": "1425000" }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", @@ -2151,19 +2143,19 @@ "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPUBigClusterMaxFreq", "Duration": 0, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPUMidClusterMaxFreq", "Duration": 0, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPULittleClusterMaxFreq", "Duration": 0, - "Value": "1475000" + "Value": "1425000" }, { "PowerHint": "CAMERA_STREAMING_LOW", @@ -2429,7 +2421,7 @@ "PowerHint": "LOW_POWER_LITTLE_CLUSTER_50", "Node": "CPULittleClusterMaxFreq", "Duration": 3600000, - "Value": "975000" + "Value": "955000" }, { "PowerHint": "LOW_POWER_LITTLE_CLUSTER_60", @@ -2471,7 +2463,7 @@ "PowerHint": "LOW_POWER_MID_CLUSTER_70", "Node": "CPUMidClusterMaxFreq", "Duration": 3600000, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "LOW_POWER_MID_CLUSTER_80", @@ -2483,13 +2475,13 @@ "PowerHint": "LOW_POWER_MID_CLUSTER_90", "Node": "CPUMidClusterMaxFreq", "Duration": 3600000, - "Value": "1999000" + "Value": "1945000" }, { "PowerHint": "LOW_POWER_CPU_50", "Node": "CPUBigClusterMaxFreq", "Duration": 3600000, - "Value": "1328000" + "Value": "1298000" }, { "PowerHint": "LOW_POWER_CPU_60", @@ -2513,7 +2505,7 @@ "PowerHint": "LOW_POWER_CPU_90", "Node": "CPUBigClusterMaxFreq", "Duration": 3600000, - "Value": "2409000" + "Value": "2363000" }, { "PowerHint": "LOW_POWER", @@ -2794,7 +2786,7 @@ "PowerHint": "FACE_UNLOCK_BOOST", "Node": "CPUBigClusterMinFreq", "Duration": 500, - "Value": "1852000" + "Value": "1885000" }, { "PowerHint": "FACE_UNLOCK_BOOST", @@ -2896,7 +2888,7 @@ "PowerHint": "CAMERA_PROJECT11", "Node": "PMU_BIG_LIMIT_FREQ", "Duration": 0, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_PROJECT11", @@ -2944,19 +2936,19 @@ "PowerHint": "CAMERA_PROJECT11", "Node": "CPUBigClusterMaxFreq", "Duration": 0, - "Value": "1852000" + "Value": "1745000" }, { "PowerHint": "CAMERA_PROJECT11", "Node": "CPUMidClusterMaxFreq", "Duration": 0, - "Value": "1622000" + "Value": "1572000" }, { "PowerHint": "CAMERA_PROJECT11", "Node": "CPULittleClusterMaxFreq", "Duration": 0, - "Value": "1475000" + "Value": "1425000" }, { "PowerHint": "CAMERA_PROJECT11", From e2a796691da7a51bb40e31e35449fde71543a4e4 Mon Sep 17 00:00:00 2001 From: Paulsu Su Date: Sat, 31 Aug 2024 05:20:01 +0000 Subject: [PATCH 2/2] powerhint: Update not available frequency to reflect its actual behavior Some frequencies uses unavailable frequency other soc ex: ag/22293847, the patch update them to explicitly show the actual actions of driver. Bug: 361294204 Change-Id: I1adc41aca636650b4eaad179d73bde030146347c FLAG: NONE powerhint do not need flag --- perf/powerhint-husky.json | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/perf/powerhint-husky.json b/perf/powerhint-husky.json index fab84f0..1cf6e87 100644 --- a/perf/powerhint-husky.json +++ b/perf/powerhint-husky.json @@ -118,7 +118,7 @@ "Path": "/sys/devices/system/cpu/cpu4/cpufreq/scaling_max_freq", "Values": [ "9999999", - "2253000", + "2245000", "2130000", "910000", "1328000", @@ -134,7 +134,7 @@ "Path": "/sys/devices/system/cpu/cpu4/cpufreq/scaling_min_freq", "Values": [ "9999999", - "2253000", + "2245000", "2130000", "1836000", "0" @@ -158,9 +158,8 @@ "Path": "/sys/devices/system/cpu/cpu8/cpufreq/scaling_max_freq", "Values": [ "9999999", - "2704000", - "2507000", - "2252000", + "2687000", + "2147000", "1298000", "1557000", "1745000", @@ -175,9 +174,9 @@ "Path": "/sys/devices/system/cpu/cpu8/cpufreq/scaling_min_freq", "Values": [ "9999999", - "2704000", - "2507000", - "2252000", + "2687000", + "2363000", + "2147000", "1885000", "0" ], @@ -1531,13 +1530,13 @@ "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK1", "Node": "CPUBigClusterMaxFreq", "Duration": 3000, - "Value": "2704000" + "Value": "2687000" }, { "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK1", "Node": "CPUBigClusterMinFreq", "Duration": 3000, - "Value": "2704000" + "Value": "2687000" }, { "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK2", @@ -1549,13 +1548,13 @@ "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK2", "Node": "CPUBigClusterMaxFreq", "Duration": 3000, - "Value": "2507000" + "Value": "2363000" }, { "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK2", "Node": "CPUBigClusterMinFreq", "Duration": 3000, - "Value": "2507000" + "Value": "2363000" }, { "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK3", @@ -1567,13 +1566,13 @@ "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK3", "Node": "CPUBigClusterMaxFreq", "Duration": 3000, - "Value": "2252000" + "Value": "2147000" }, { "PowerHint": "GCA_CAMERA_SHOT_BIGCPU_RANK3", "Node": "CPUBigClusterMinFreq", "Duration": 3000, - "Value": "2252000" + "Value": "2147000" }, { "PowerHint": "GCA_CAMERA_SHOT_MIDCPU_RANK1", @@ -1591,13 +1590,13 @@ "PowerHint": "GCA_CAMERA_SHOT_MIDCPU_RANK2", "Node": "CPUMidClusterMaxFreq", "Duration": 3000, - "Value": "2253000" + "Value": "2245000" }, { "PowerHint": "GCA_CAMERA_SHOT_MIDCPU_RANK2", "Node": "CPUMidClusterMinFreq", "Duration": 3000, - "Value": "2253000" + "Value": "2245000" }, { "PowerHint": "GCA_CAMERA_SHOT_MIDCPU_RANK3",