From 4a6d0b7b8ee9ed3439e5c95cc8cf8f88734d753f Mon Sep 17 00:00:00 2001 From: George Lee Date: Thu, 12 Aug 2021 08:40:55 -0700 Subject: [PATCH 1/4] bcl: change tpu_cooling state from 3 to 2 ocp_tpu Per quality testing of Face Auth, noticed 2 failures out of 30 tries of Face Auth. Per thermal log, tpu_cooling state changed 2 times. Over throttling on TPU by setting tpu_cooling state to 3 may cause Face Auth to fail. Changing it to 3. Bug: 181348043 Bug: 196315467 Test: Local test and verify Face Auth Signed-off-by: George Lee Change-Id: I535f0734c247b2041af0f7cc69ef8e6706c9a909 --- thermal_info_config_oriole.json | 10 ++-------- thermal_info_config_oriole_WHI_A.json | 10 ++-------- thermal_info_config_raven.json | 10 ++-------- 3 files changed, 6 insertions(+), 24 deletions(-) diff --git a/thermal_info_config_oriole.json b/thermal_info_config_oriole.json index 97d0b1c..945ac4a 100644 --- a/thermal_info_config_oriole.json +++ b/thermal_info_config_oriole.json @@ -901,7 +901,7 @@ "BindedCdevInfo": [ { "CdevRequest": "tpu_cooling", - "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] } ] }, @@ -1003,13 +1003,7 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true, - "BindedCdevInfo": [ - { - "CdevRequest": "tpu_cooling", - "LimitInfo": [0, 0, 0, 0, 3, 3, 3] - } - ] + "Monitor":true }, { "Name":"soft_ocp_gpu", diff --git a/thermal_info_config_oriole_WHI_A.json b/thermal_info_config_oriole_WHI_A.json index 6094307..c60da21 100644 --- a/thermal_info_config_oriole_WHI_A.json +++ b/thermal_info_config_oriole_WHI_A.json @@ -574,7 +574,7 @@ "BindedCdevInfo": [ { "CdevRequest": "tpu_cooling", - "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] } ] }, @@ -676,13 +676,7 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true, - "BindedCdevInfo": [ - { - "CdevRequest": "tpu_cooling", - "LimitInfo": [0, 0, 0, 0, 3, 3, 3] - } - ] + "Monitor":true }, { "Name":"soft_ocp_gpu", diff --git a/thermal_info_config_raven.json b/thermal_info_config_raven.json index cb769fb..f73ade1 100644 --- a/thermal_info_config_raven.json +++ b/thermal_info_config_raven.json @@ -901,7 +901,7 @@ "BindedCdevInfo": [ { "CdevRequest": "tpu_cooling", - "LimitInfo": [0, 0, 0, 0, 3, 3, 3] + "LimitInfo": [0, 0, 0, 0, 2, 2, 2] } ] }, @@ -1003,13 +1003,7 @@ ], "VrThreshold":"NAN", "Multiplier":1, - "Monitor":true, - "BindedCdevInfo": [ - { - "CdevRequest": "tpu_cooling", - "LimitInfo": [0, 0, 0, 0, 3, 3, 3] - } - ] + "Monitor":true }, { "Name":"soft_ocp_gpu", From f1820dbcbd50dabf53b9075ffb4e8cf15f1e873f Mon Sep 17 00:00:00 2001 From: samou Date: Thu, 29 Jul 2021 07:38:05 +0000 Subject: [PATCH 2/4] powerstats: correct display odpm rail name Bug: 194651088 Test: dumpsys android.hardware.power.stats.IPowerStats/default Change-Id: I40b1ab79c64a26008746933fd293064ff69eeebd --- powerstats/oriole/service.cpp | 18 +++++++++++++++++- powerstats/raven/service.cpp | 18 +++++++++++++++++- 2 files changed, 34 insertions(+), 2 deletions(-) diff --git a/powerstats/oriole/service.cpp b/powerstats/oriole/service.cpp index ee9d57e..8331997 100644 --- a/powerstats/oriole/service.cpp +++ b/powerstats/oriole/service.cpp @@ -31,6 +31,13 @@ using aidl::android::hardware::power::stats::DisplayStateResidencyDataProvider; using aidl::android::hardware::power::stats::EnergyConsumerType; using aidl::android::hardware::power::stats::PowerStatsEnergyConsumer; +const char kBootRevision[] = "ro.boot.revision"; +std::map displayChannelNames = { + {"PROTO1.0", "PPVAR_VSYS_PWR_DISP"}, + {"EVT1.0", "PPVAR_VSYS_PWR_DISP"}, + {"EVT1.1", "VSYS_PWR_DISPLAY"}, +}; + void addDisplay(std::shared_ptr p) { // Add display residency stats std::vector states = { @@ -45,13 +52,22 @@ void addDisplay(std::shared_ptr p) { "/sys/class/backlight/panel0-backlight/state", states)); + std::string rev = android::base::GetProperty(kBootRevision, ""); + + std::string channelName; + if (displayChannelNames.find(rev) == displayChannelNames.end()) { + channelName = displayChannelNames["EVT1.1"]; + } else { + channelName = displayChannelNames[rev]; + } + // Add display energy consumer /* * TODO(b/167216667): Add correct display power model here. Must read from display rail * and include proper coefficients for display states. */ p->addEnergyConsumer(PowerStatsEnergyConsumer::createMeterAndEntityConsumer(p, - EnergyConsumerType::DISPLAY, "display", {"PPVAR_VSYS_PWR_DISP"}, "Display", + EnergyConsumerType::DISPLAY, "display", {channelName}, "Display", {{"LP: 1080x2400@30", 1}, {"On: 1080x2400@60", 2}, {"On: 1080x2400@90", 3}, diff --git a/powerstats/raven/service.cpp b/powerstats/raven/service.cpp index 6ee27d8..579efa1 100644 --- a/powerstats/raven/service.cpp +++ b/powerstats/raven/service.cpp @@ -33,6 +33,13 @@ using aidl::android::hardware::power::stats::EnergyConsumerType; using aidl::android::hardware::power::stats::GenericStateResidencyDataProvider; using aidl::android::hardware::power::stats::PowerStatsEnergyConsumer; +const char kBootRevision[] = "ro.boot.revision"; +std::map displayChannelNames = { + {"PROTO1.0", "PPVAR_VSYS_PWR_DISP"}, + {"EVT1.0", "PPVAR_VSYS_PWR_DISP"}, + {"EVT1.1", "VSYS_PWR_DISPLAY"}, +}; + void addDisplay(std::shared_ptr p) { // Add display residency stats std::vector states = { @@ -51,13 +58,22 @@ void addDisplay(std::shared_ptr p) { "/sys/class/backlight/panel0-backlight/state", states)); + std::string rev = android::base::GetProperty(kBootRevision, ""); + + std::string channelName; + if (displayChannelNames.find(rev) == displayChannelNames.end()) { + channelName = displayChannelNames["EVT1.1"]; + } else { + channelName = displayChannelNames[rev]; + } + // Add display energy consumer /* * TODO(b/167216667): Add correct display power model here. Must read from display rail * and include proper coefficients for display states. */ p->addEnergyConsumer(PowerStatsEnergyConsumer::createMeterAndEntityConsumer(p, - EnergyConsumerType::DISPLAY, "display", {"PPVAR_VSYS_PWR_DISP"}, "Display", + EnergyConsumerType::DISPLAY, "display", {channelName}, "Display", {{"LP: 1440x3120@10", 1}, {"LP: 1440x3120@30", 2}, {"On: 1440x3120@10", 3}, From 7494ecc0949116bc10dd2ff4ba0e928b84dfdbc5 Mon Sep 17 00:00:00 2001 From: Daniel Solomon Date: Fri, 6 Aug 2021 14:37:47 -0700 Subject: [PATCH 3/4] display: override Oriole set_idle_timer_ms Bug: 195699802 Change-Id: I6d707b1630d26e0c2018c12566f2a294c4dadd10 --- device-oriole.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/device-oriole.mk b/device-oriole.mk index 1178bca..0faa113 100644 --- a/device-oriole.mk +++ b/device-oriole.mk @@ -128,8 +128,9 @@ PRODUCT_SOONG_NAMESPACES += \ # Keyboard bottom padding in dp for portrait mode PRODUCT_PRODUCT_PROPERTIES += ro.com.google.ime.kb_pad_port_b=10 -# Display LBE +# Display PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.lbe.supported=1 +PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.surface_flinger.set_idle_timer_ms=1500 # userdebug specific ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) From 2d185271955ee9c816d0fe6d568195fc16b396d5 Mon Sep 17 00:00:00 2001 From: linpeter Date: Fri, 13 Aug 2021 18:46:54 +0800 Subject: [PATCH 4/4] display: disable hbm dimming Bug: 194656170 test: no panel dimming Change-Id: I5907697c546bd11d6e8ca67b4fde2a67b3ab8764 --- device-raven.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/device-raven.mk b/device-raven.mk index 20e7b44..3c740c8 100644 --- a/device-raven.mk +++ b/device-raven.mk @@ -90,7 +90,7 @@ PRODUCT_COPY_FILES += \ device/google/raviole/raven/display_colordata_dev_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_dev_cal0.pb #config of display brightness dimming -PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.brightness.dimming.usage=1 +PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.brightness.dimming.usage=2 # NFC PRODUCT_COPY_FILES += \