From dc64ebbb620e27b5efda7f7814c3f795efaec58b Mon Sep 17 00:00:00 2001 From: Lokesh Kumar Goel Date: Wed, 10 Jul 2024 21:25:47 +0000 Subject: [PATCH 1/2] caimito: Use build_flags for SVN Flag: build.RELEASE_SVN_CAIMAN Flag: build.RELEASE_SVN_KOMODO Flag: build.RELEASE_SVN_TOKAY Bug: 332726030 Change-Id: I8e2a835fd2887c4e77d95bf0a3bc63a25161b080 --- device-caiman.mk | 9 ++++++++- device-komodo.mk | 9 ++++++++- device-tokay.mk | 9 ++++++++- 3 files changed, 24 insertions(+), 3 deletions(-) diff --git a/device-caiman.mk b/device-caiman.mk index 89ea6cfc..0efba31f 100644 --- a/device-caiman.mk +++ b/device-caiman.mk @@ -69,8 +69,15 @@ include device/google/gs-common/modem/radio_ext/radio_ext.mk include device/google/gs-common/pixelsupport/pixelsupport.mk # Increment the SVN for any official public releases +ifdef RELEASE_SVN_CAIMAN +TARGET_SVN ?= $(RELEASE_SVN_CAIMAN) +else +# Set this for older releases that don't use build flag +TARGET_SVN ?= 03 +endif + PRODUCT_VENDOR_PROPERTIES += \ - ro.vendor.build.svn=3 + ro.vendor.build.svn=$(TARGET_SVN) # go/lyric-soong-variables $(call soong_config_set,lyric,camera_hardware,caiman) diff --git a/device-komodo.mk b/device-komodo.mk index b81efb18..6797e88c 100644 --- a/device-komodo.mk +++ b/device-komodo.mk @@ -69,8 +69,15 @@ include device/google/gs-common/modem/radio_ext/radio_ext.mk include device/google/gs-common/pixelsupport/pixelsupport.mk # Increment the SVN for any official public releases +ifdef RELEASE_SVN_KOMODO +TARGET_SVN ?= $(RELEASE_SVN_KOMODO) +else +# Set this for older releases that don't use build flag +TARGET_SVN ?= 03 +endif + PRODUCT_VENDOR_PROPERTIES += \ - ro.vendor.build.svn=3 + ro.vendor.build.svn=$(TARGET_SVN) # go/lyric-soong-variables $(call soong_config_set,lyric,camera_hardware,komodo) diff --git a/device-tokay.mk b/device-tokay.mk index 08555a72..90433f16 100644 --- a/device-tokay.mk +++ b/device-tokay.mk @@ -59,8 +59,15 @@ include device/google/gs-common/modem/radio_ext/radio_ext.mk include device/google/gs-common/pixelsupport/pixelsupport.mk # Increment the SVN for any official public releases +ifdef RELEASE_SVN_TOKAY +TARGET_SVN ?= $(RELEASE_SVN_TOKAY) +else +# Set this for older releases that don't use build flag +TARGET_SVN ?= 03 +endif + PRODUCT_VENDOR_PROPERTIES += \ - ro.vendor.build.svn=3 + ro.vendor.build.svn=$(TARGET_SVN) # go/lyric-soong-variables $(call soong_config_set,lyric,camera_hardware,tokay) From d68bded2d6e4626511a36b4060ff8da9a30e568f Mon Sep 17 00:00:00 2001 From: zorahchen Date: Thu, 6 Jun 2024 07:11:40 +0000 Subject: [PATCH 2/2] Powerhint tuning for photo capture UClamp.min of all threads in top app is set to mid core max capacity during photo capture, which will dispatch them to big core. Critical threads of photo capture will be interrupted due to their lower priority, while other cores idle. To deal with this situation, prefer_idle mask to big/mid cores can reduce the idle in mid cores. UClamp.min on nice can set UClamp.min of photo capture critical threads to mid core max capacity, while others as zero, this can make critical threads run on big core without frequently interrupted. By applying this, photo capture latency can be reduced with slight change of power consumption. Bug:345601796 Performance Test:https://g3doc.corp.google.com/wireless/android/camera/camera_performance_analyzer/power_tuning/results/g3doc/pmu_retune_capture_enhanced/index.md?cl=alikz/1010 Kibble Power Test:https://g3doc.corp.google.com/wireless/android/camera/camera_performance_analyzer/power_tuning/results/g3doc/pmu_kibble_capture_rt_enhanced/index.md?cl=alikz/1044 Flag: NONE powerhint change does not support flags Change-Id: I8683b50b212d50b85b22b5cb48d712fc8eb43444 --- perf/powerhint-caiman.json | 91 ++++++++++++++++++++++++++++++- perf/powerhint-komodo.json | 89 +++++++++++++++++++++++++++++- perf/powerhint-ripcurrentpro.json | 91 ++++++++++++++++++++++++++++++- perf/powerhint-tokay.json | 91 ++++++++++++++++++++++++++++++- 4 files changed, 355 insertions(+), 7 deletions(-) diff --git a/perf/powerhint-caiman.json b/perf/powerhint-caiman.json index 7fc1824f..64965e19 100644 --- a/perf/powerhint-caiman.json +++ b/perf/powerhint-caiman.json @@ -273,6 +273,42 @@ ], "ResetOnInit": true }, + { + "Name": "TAUclampMinOnNiceEnable", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_enable", + "Values": [ + "1", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidValue", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_value", + "Values": [ + "600", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceHighPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_high_prio", + "Values": [ + "119", + "120" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_prio", + "Values": [ + "128", + "130" + ], + "ResetOnInit": true + }, { "Name": "FGUClampBoost", "Path": "/proc/vendor_sched/groups/fg/uclamp_min", @@ -389,6 +425,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_high", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -398,6 +435,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_mid", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -407,6 +445,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_low", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -1494,9 +1533,57 @@ }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", - "Node": "TAUClampBoost", + "Node": "ReducePreferIdle", "Duration": 3000, - "Value": "600" + "Value": "0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskHigh", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskMid", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskLow", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceEnable", + "Duration": 3000, + "Value": "1" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidValue", + "Duration": 3000, + "Value": "600" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceHighPrio", + "Duration": 3000, + "Value": "119" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidPrio", + "Duration": 3000, + "Value": "128" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferIdle", + "Duration": 3000, + "Value": "1" }, { "PowerHint": "CAMERA_THERMAL_SEVERE_BOOST", diff --git a/perf/powerhint-komodo.json b/perf/powerhint-komodo.json index dcb55105..5a18b465 100644 --- a/perf/powerhint-komodo.json +++ b/perf/powerhint-komodo.json @@ -273,6 +273,42 @@ ], "ResetOnInit": true }, + { + "Name": "TAUclampMinOnNiceEnable", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_enable", + "Values": [ + "1", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidValue", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_value", + "Values": [ + "600", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceHighPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_high_prio", + "Values": [ + "119", + "120" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_prio", + "Values": [ + "128", + "130" + ], + "ResetOnInit": true + }, { "Name": "FGUClampBoost", "Path": "/proc/vendor_sched/groups/fg/uclamp_min", @@ -389,6 +425,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_high", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -398,6 +435,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_mid", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -407,6 +445,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_low", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -1492,12 +1531,60 @@ "Duration": 3000, "Value": "20" }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "ReducePreferIdle", + "Duration": 3000, + "Value": "0" + }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", - "Node": "TAUClampBoost", + "Node": "TAPreferredIdleMaskHigh", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskMid", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskLow", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceEnable", + "Duration": 3000, + "Value": "1" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidValue", "Duration": 3000, "Value": "600" }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceHighPrio", + "Duration": 3000, + "Value": "119" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidPrio", + "Duration": 3000, + "Value": "128" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferIdle", + "Duration": 3000, + "Value": "1" + }, { "PowerHint": "CAMERA_THERMAL_SEVERE_BOOST", "Node": "CDPreferHighCap", diff --git a/perf/powerhint-ripcurrentpro.json b/perf/powerhint-ripcurrentpro.json index a3780cf4..f984eb4b 100644 --- a/perf/powerhint-ripcurrentpro.json +++ b/perf/powerhint-ripcurrentpro.json @@ -327,6 +327,42 @@ ], "ResetOnInit": true }, + { + "Name": "TAUclampMinOnNiceEnable", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_enable", + "Values": [ + "1", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidValue", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_value", + "Values": [ + "600", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceHighPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_high_prio", + "Values": [ + "119", + "120" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_prio", + "Values": [ + "128", + "130" + ], + "ResetOnInit": true + }, { "Name": "FGUClampBoost", "Path": "/proc/vendor_sched/groups/fg/uclamp_min", @@ -443,6 +479,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_high", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -452,6 +489,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_mid", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -461,6 +499,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_low", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -1483,9 +1522,57 @@ }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", - "Node": "TAUClampBoost", + "Node": "ReducePreferIdle", "Duration": 3000, - "Value": "600" + "Value": "0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskHigh", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskMid", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskLow", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceEnable", + "Duration": 3000, + "Value": "1" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidValue", + "Duration": 3000, + "Value": "600" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceHighPrio", + "Duration": 3000, + "Value": "119" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidPrio", + "Duration": 3000, + "Value": "128" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferIdle", + "Duration": 3000, + "Value": "1" }, { "PowerHint": "CAMERA_THERMAL_SEVERE_BOOST", diff --git a/perf/powerhint-tokay.json b/perf/powerhint-tokay.json index 7fc1824f..64965e19 100644 --- a/perf/powerhint-tokay.json +++ b/perf/powerhint-tokay.json @@ -273,6 +273,42 @@ ], "ResetOnInit": true }, + { + "Name": "TAUclampMinOnNiceEnable", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_enable", + "Values": [ + "1", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidValue", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_value", + "Values": [ + "600", + "0" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceHighPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_high_prio", + "Values": [ + "119", + "120" + ], + "ResetOnInit": true + }, + { + "Name": "TAUclampMinOnNiceMidPrio", + "Path": "/proc/vendor_sched/groups/ta/uclamp_min_on_nice_mid_prio", + "Values": [ + "128", + "130" + ], + "ResetOnInit": true + }, { "Name": "FGUClampBoost", "Path": "/proc/vendor_sched/groups/fg/uclamp_min", @@ -389,6 +425,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_high", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -398,6 +435,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_mid", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -407,6 +445,7 @@ "Path": "/proc/vendor_sched/groups/ta/preferred_idle_mask_low", "Values": [ "0xff", + "0xf0", "0x7f" ], "ResetOnInit": true @@ -1494,9 +1533,57 @@ }, { "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", - "Node": "TAUClampBoost", + "Node": "ReducePreferIdle", "Duration": 3000, - "Value": "600" + "Value": "0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskHigh", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskMid", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferredIdleMaskLow", + "Duration": 3000, + "Value": "0xf0" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceEnable", + "Duration": 3000, + "Value": "1" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidValue", + "Duration": 3000, + "Value": "600" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceHighPrio", + "Duration": 3000, + "Value": "119" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAUclampMinOnNiceMidPrio", + "Duration": 3000, + "Value": "128" + }, + { + "PowerHint": "CAMERA_CAPTURE_CPU_THROTTLE", + "Node": "TAPreferIdle", + "Duration": 3000, + "Value": "1" }, { "PowerHint": "CAMERA_THERMAL_SEVERE_BOOST",