From e33676555674c93a33a57c8786b7aac81f9694d1 Mon Sep 17 00:00:00 2001 From: "Ali K. Zadeh" Date: Fri, 2 Sep 2022 00:12:40 +0000 Subject: [PATCH] Powerhint update containing PMU and EM_Profile tuning Using PMU feature together with Energy Metric (EM) profile is shown to have benefits in terms of power, without increasing the framedrop rate. This CL addes necessary changes to the powerhint files to activate both features for P10 and C10 device. Bug: 235147585 Test: ODPM and framedrop tests Change-Id: I64048cc1c1ad948619dd56ebac0b3af263ab0733 --- powerhint-cheetah-a0.json | 171 ++++++++++++++++++++++++++++++++++---- powerhint-cheetah.json | 171 ++++++++++++++++++++++++++++++++++---- powerhint-panther-a0.json | 171 ++++++++++++++++++++++++++++++++++---- powerhint-panther.json | 171 ++++++++++++++++++++++++++++++++++---- 4 files changed, 612 insertions(+), 72 deletions(-) diff --git a/powerhint-cheetah-a0.json b/powerhint-cheetah-a0.json index 55bbddd..7130951 100644 --- a/powerhint-cheetah-a0.json +++ b/powerhint-cheetah-a0.json @@ -517,6 +517,105 @@ "1" ], "DefaultIndex": 0 + }, + { + "Name": "EM_Profile", + "Path": "/sys/kernel/pixel_em/active_profile", + "Values": [ + "default", + "cam1", + "cam2", + "front_cam" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1401000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "2", + "1", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "70", + "50", + "30", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1836000", + "1491000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "6", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "65", + "50", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "2507000", + "2048000", + "1826000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "5", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "69", + "50", + "0" + ], + "DefaultIndex": 0 } ], "Actions": [ @@ -1011,36 +1110,72 @@ "Duration": 0, "Value": "0" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_LCPI_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_SPC_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LIMIT_FREQ", + "Duration": 0, + "Value": "1836000" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "EM_Profile", + "Duration": 0, + "Value": "cam1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CPUUtilThreshold", "Duration": 0, "Value": "1100" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUMidClusterMaxFreq", - "Duration": 0, - "Value": "1491000" - }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUBigClusterMaxFreq", - "Duration": 0, - "Value": "1826000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CDPreferHighCap", "Duration": 0, "Value": "1" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPULittleClusterMaxFreq", - "Duration": 0, - "Value": "1401000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "MemFreq", diff --git a/powerhint-cheetah.json b/powerhint-cheetah.json index 334f97f..cfce5f4 100644 --- a/powerhint-cheetah.json +++ b/powerhint-cheetah.json @@ -515,6 +515,105 @@ ], "DefaultIndex": 0 }, + { + "Name": "EM_Profile", + "Path": "/sys/kernel/pixel_em/active_profile", + "Values": [ + "default", + "cam1", + "cam2", + "front_cam" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1401000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "2", + "1", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "70", + "50", + "30", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1836000", + "1491000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "6", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "65", + "50", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "2507000", + "2048000", + "1826000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "5", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "69", + "50", + "0" + ], + "DefaultIndex": 0 + }, { "Name": "Dex2oatThreads", "Path": "vendor.powerhal.dalvik.vm.dex2oat-threads", @@ -1053,36 +1152,72 @@ "Duration": 0, "Value": "0" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_LCPI_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_SPC_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LIMIT_FREQ", + "Duration": 0, + "Value": "1836000" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "EM_Profile", + "Duration": 0, + "Value": "cam1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CPUUtilThreshold", "Duration": 0, "Value": "1100" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUMidClusterMaxFreq", - "Duration": 0, - "Value": "1491000" - }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUBigClusterMaxFreq", - "Duration": 0, - "Value": "1826000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CDPreferHighCap", "Duration": 0, "Value": "1" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPULittleClusterMaxFreq", - "Duration": 0, - "Value": "1401000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "MemFreq", diff --git a/powerhint-panther-a0.json b/powerhint-panther-a0.json index 6a0caef..f272cd8 100644 --- a/powerhint-panther-a0.json +++ b/powerhint-panther-a0.json @@ -506,6 +506,105 @@ "1" ], "DefaultIndex": 0 + }, + { + "Name": "EM_Profile", + "Path": "/sys/kernel/pixel_em/active_profile", + "Values": [ + "default", + "cam1", + "cam2", + "front_cam" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1401000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "2", + "1", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "70", + "50", + "30", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1836000", + "1491000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "6", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "65", + "50", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "2507000", + "2048000", + "1826000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "5", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "69", + "50", + "0" + ], + "DefaultIndex": 0 } ], "Actions": [ @@ -893,36 +992,72 @@ "Duration": 0, "Value": "0" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_LCPI_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_SPC_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LIMIT_FREQ", + "Duration": 0, + "Value": "1836000" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "EM_Profile", + "Duration": 0, + "Value": "cam1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CPUUtilThreshold", "Duration": 0, "Value": "1100" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUMidClusterMaxFreq", - "Duration": 0, - "Value": "1491000" - }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUBigClusterMaxFreq", - "Duration": 0, - "Value": "1826000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CDPreferHighCap", "Duration": 0, "Value": "1" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPULittleClusterMaxFreq", - "Duration": 0, - "Value": "1401000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "MemFreq", diff --git a/powerhint-panther.json b/powerhint-panther.json index 3ecbad5..6d999dd 100644 --- a/powerhint-panther.json +++ b/powerhint-panther.json @@ -495,6 +495,105 @@ ], "DefaultIndex": 0 }, + { + "Name": "EM_Profile", + "Path": "/sys/kernel/pixel_em/active_profile", + "Values": [ + "default", + "cam1", + "cam2", + "front_cam" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1401000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "2", + "1", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_LIT_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu0/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "70", + "50", + "30", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "1836000", + "1491000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "6", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_MID_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu4/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "65", + "50", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LIMIT_FREQ", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/limit_frequency", + "Values": [ + "2507000", + "2048000", + "1826000" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_LCPI_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/lcpi_threshold", + "Values": [ + "5", + "3", + "0" + ], + "DefaultIndex": 0 + }, + { + "Name": "PMU_BIG_SPC_THRESHOLD", + "Path": "/sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/spc_threshold", + "Values": [ + "69", + "50", + "0" + ], + "DefaultIndex": 0 + }, { "Name": "Dex2oatThreads", "Path": "vendor.powerhal.dalvik.vm.dex2oat-threads", @@ -915,36 +1014,72 @@ "Duration": 0, "Value": "0" }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_POLL", + "Duration": 0, + "Value": "1" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_LCPI_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_LIT_SPC_THRESHOLD", + "Duration": 0, + "Value": "0" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LIMIT_FREQ", + "Duration": 0, + "Value": "1836000" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_MID_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_LCPI_THRESHOLD", + "Duration": 0, + "Value": "3" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "PMU_BIG_SPC_THRESHOLD", + "Duration": 0, + "Value": "50" + }, + { + "PowerHint": "CAMERA_STREAMING_HIGH", + "Node": "EM_Profile", + "Duration": 0, + "Value": "cam1" + }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CPUUtilThreshold", "Duration": 0, "Value": "1100" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUMidClusterMaxFreq", - "Duration": 0, - "Value": "1491000" - }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPUBigClusterMaxFreq", - "Duration": 0, - "Value": "1826000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CDPreferHighCap", "Duration": 0, "Value": "1" }, - { - "PowerHint": "CAMERA_STREAMING_HIGH", - "Node": "CPULittleClusterMaxFreq", - "Duration": 0, - "Value": "1401000" - }, { "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "MemFreq",