diff --git a/conf/init.pantah.rc b/conf/init.pantah.rc index e14b913..48abe65 100644 --- a/conf/init.pantah.rc +++ b/conf/init.pantah.rc @@ -107,3 +107,11 @@ on property:vendor.device.modules.ready=1 chown system system /proc/focaltech_touch/selftest/Scap_Rawdata chown system system /proc/focaltech_touch/selftest/Short chown system system /proc/focaltech_touch/selftest/Strength + +# Override SF and RE uclamps to 0 on boot after being set elsewhere, for adpf cpu hints +on property:sys.boot_completed=1 + trigger override-sf-uclamp + +on override-sf-uclamp + write /proc/vendor_sched/rt_uclamp_min 0 + write /proc/vendor_sched/sf_uclamp_min 0 diff --git a/device-cheetah.mk b/device-cheetah.mk index 84af1e1..4b775b2 100644 --- a/device-cheetah.mk +++ b/device-cheetah.mk @@ -256,7 +256,7 @@ PRODUCT_VENDOR_PROPERTIES += \ # Increment the SVN for any official public releases PRODUCT_VENDOR_PROPERTIES += \ - ro.vendor.build.svn=1 + ro.vendor.build.svn=2 # DCK properties based on target PRODUCT_PROPERTY_OVERRIDES += \ @@ -331,3 +331,7 @@ PRODUCT_VENDOR_PROPERTIES += \ # Device features PRODUCT_COPY_FILES += \ frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml + +# Enable adpf cpu hint session for SurfaceFlinger +PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ + debug.sf.enable_adpf_cpu_hint=true diff --git a/device-panther.mk b/device-panther.mk index 37c438d..926fab4 100644 --- a/device-panther.mk +++ b/device-panther.mk @@ -243,7 +243,7 @@ PRODUCT_VENDOR_PROPERTIES += \ # Increment the SVN for any official public releases PRODUCT_VENDOR_PROPERTIES += \ - ro.vendor.build.svn=1 + ro.vendor.build.svn=2 # DCK properties based on target PRODUCT_PROPERTY_OVERRIDES += \ @@ -317,3 +317,7 @@ PRODUCT_VENDOR_PROPERTIES += \ # Device features PRODUCT_COPY_FILES += \ frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml + +# Enable adpf cpu hint session for SurfaceFlinger +PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ + debug.sf.enable_adpf_cpu_hint=true diff --git a/powerhint-cheetah-a0.json b/powerhint-cheetah-a0.json index 79588d9..ec24509 100644 --- a/powerhint-cheetah-a0.json +++ b/powerhint-cheetah-a0.json @@ -162,16 +162,6 @@ ], "ResetOnInit": true }, - { - "Name": "SFUClampBoost", - "Path": "/proc/vendor_sched/sf_uclamp_min", - "Values": [ - "159", - "85", - "39" - ], - "ResetOnInit": true - }, { "Name": "MLUclampBoost", "Path": "/proc/vendor_sched/nnapi_uclamp_min", @@ -530,18 +520,6 @@ } ], "Actions": [ - { - "PowerHint": "INTERACTION", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, - { - "PowerHint": "LAUNCH_120FPS", - "Node": "SFUClampBoost", - "Duration": 1000, - "Value": "159" - }, { "PowerHint": "LAUNCH", "Node": "FGPreferIdle", @@ -553,12 +531,6 @@ "Type": "DoHint", "Value": "LAUNCH_120FPS" }, - { - "PowerHint": "LAUNCH", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "CPUBigClusterMaxFreq", diff --git a/powerhint-cheetah.json b/powerhint-cheetah.json index a42dc48..772b4e8 100644 --- a/powerhint-cheetah.json +++ b/powerhint-cheetah.json @@ -188,16 +188,6 @@ ], "ResetOnInit": true }, - { - "Name": "SFUClampBoost", - "Path": "/proc/vendor_sched/sf_uclamp_min", - "Values": [ - "159", - "85", - "39" - ], - "ResetOnInit": true - }, { "Name": "MLUclampBoost", "Path": "/proc/vendor_sched/nnapi_uclamp_min", @@ -536,12 +526,6 @@ } ], "Actions": [ - { - "PowerHint": "INTERACTION", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "UClampThreshold", @@ -560,12 +544,6 @@ "Duration": 1000, "Value": "10" }, - { - "PowerHint": "LAUNCH_120FPS", - "Node": "SFUClampBoost", - "Duration": 1000, - "Value": "159" - }, { "PowerHint": "LAUNCH", "Node": "FGPreferIdle", @@ -582,12 +560,6 @@ "Type": "DoHint", "Value": "LAUNCH_GPU" }, - { - "PowerHint": "LAUNCH", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "CPUBigClusterMaxFreq", diff --git a/powerhint-panther-a0.json b/powerhint-panther-a0.json index 98883cb..f26e9be 100644 --- a/powerhint-panther-a0.json +++ b/powerhint-panther-a0.json @@ -151,16 +151,6 @@ ], "ResetOnInit": true }, - { - "Name": "SFUClampBoost", - "Path": "/proc/vendor_sched/sf_uclamp_min", - "Values": [ - "159", - "85", - "39" - ], - "ResetOnInit": true - }, { "Name": "MLUclampBoost", "Path": "/proc/vendor_sched/nnapi_uclamp_min", @@ -519,24 +509,12 @@ } ], "Actions": [ - { - "PowerHint": "INTERACTION", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "FGPreferIdle", "Duration": 5000, "Value": "1" }, - { - "PowerHint": "LAUNCH", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "CPUBigClusterMaxFreq", diff --git a/powerhint-panther.json b/powerhint-panther.json index 800376c..e037835 100644 --- a/powerhint-panther.json +++ b/powerhint-panther.json @@ -168,16 +168,6 @@ ], "ResetOnInit": true }, - { - "Name": "SFUClampBoost", - "Path": "/proc/vendor_sched/sf_uclamp_min", - "Values": [ - "159", - "85", - "39" - ], - "ResetOnInit": true - }, { "Name": "MLUclampBoost", "Path": "/proc/vendor_sched/nnapi_uclamp_min", @@ -516,12 +506,6 @@ } ], "Actions": [ - { - "PowerHint": "INTERACTION", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "UClampThreshold", @@ -540,12 +524,6 @@ "Duration": 5000, "Value": "1" }, - { - "PowerHint": "LAUNCH", - "Node": "SFUClampBoost", - "Duration": 5000, - "Value": "85" - }, { "PowerHint": "LAUNCH", "Node": "CPUBigClusterMaxFreq", diff --git a/thermal_info_config_cheetah.json b/thermal_info_config_cheetah.json index 5a134bd..b848b8a 100644 --- a/thermal_info_config_cheetah.json +++ b/thermal_info_config_cheetah.json @@ -511,7 +511,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 5, 5, 5] + } + ] }, { "Name":"BCL_AUDIO_BAACL", @@ -532,7 +547,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"vdroop2", @@ -541,7 +571,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 4, 4, 4] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"smpl_gm", @@ -550,7 +595,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_cpu1", diff --git a/thermal_info_config_cloudripper.json b/thermal_info_config_cloudripper.json index 95bde43..a597fac 100644 --- a/thermal_info_config_cloudripper.json +++ b/thermal_info_config_cloudripper.json @@ -174,7 +174,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 5, 5, 5] + } + ] }, { "Name":"BCL_AUDIO_BAACL", @@ -227,7 +242,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 10, 10] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"vdroop2", @@ -253,7 +283,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 10, 10] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 4, 4, 4] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"smpl_gm", @@ -279,7 +324,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 10, 10] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_cpu1", diff --git a/thermal_info_config_panther.json b/thermal_info_config_panther.json index 0ea1598..7597ae5 100644 --- a/thermal_info_config_panther.json +++ b/thermal_info_config_panther.json @@ -512,7 +512,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 5, 5, 5] + } + ] }, { "Name":"BCL_AUDIO_BAACL", @@ -533,7 +548,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"vdroop2", @@ -542,7 +572,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 4, 4, 4] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"smpl_gm", @@ -551,7 +596,22 @@ "HotHysteresis":[0.0, 0.0, 0.0, 0.0, 100, 0.0, 0.0], "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_cpu1", diff --git a/thermal_info_config_ravenclaw.json b/thermal_info_config_ravenclaw.json index f417914..26e5dbd 100644 --- a/thermal_info_config_ravenclaw.json +++ b/thermal_info_config_ravenclaw.json @@ -376,7 +376,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 5, 5, 5] + } + ] }, { "Name":"BCL_AUDIO_BAACL", @@ -429,7 +444,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"vdroop2", @@ -455,7 +485,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 4, 4, 4] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"smpl_gm", @@ -481,7 +526,22 @@ "VrThreshold":"NAN", "Multiplier":1, "Monitor":true, - "PassiveDelay":7000 + "PollingDelay":0, + "PassiveDelay":1000, + "BindedCdevInfo": [ + { + "CdevRequest": "thermal-cpufreq-2", + "LimitInfo": [0, 0, 0, 0, 7, 7, 7] + }, + { + "CdevRequest": "thermal-gpufreq-0", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + }, + { + "CdevRequest": "tpu_cooling", + "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + } + ] }, { "Name":"ocp_cpu1",