summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Leon Scroggins III <scroggo@google.com> 2023-10-20 09:58:17 -0400
committer Leon Scroggins III <scroggo@google.com> 2023-11-21 15:11:03 -0500
commitdb635045fbf961623259ec8dfcd9f466d73512e7 (patch)
tree324f2b9985a41a98811885bf59fef280f6ae3d71
parent2f60d735f5e2e77643efa8b7129aeb81f93c9008 (diff)
AidlComposer: read flag to determine number of readers
Follow-on to I28169352933dcc76ab9778a5a14a191867ea42f7. While that CL doesn't (or at least shouldn't) change any user visible behavior, it does slightly change the implementation. This CL makes it so that the implementation only changes if the trunk stable flag (or debug sysprop) is set. Bug: 259132483 Bug: 284156408 Test: manual Change-Id: I1ba3b4909129aba14036cfd34a5c3126b2483228
-rw-r--r--services/surfaceflinger/DisplayHardware/AidlComposerHal.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/services/surfaceflinger/DisplayHardware/AidlComposerHal.cpp b/services/surfaceflinger/DisplayHardware/AidlComposerHal.cpp
index 62701f3196..cc2f6c7cb3 100644
--- a/services/surfaceflinger/DisplayHardware/AidlComposerHal.cpp
+++ b/services/surfaceflinger/DisplayHardware/AidlComposerHal.cpp
@@ -1575,6 +1575,7 @@ void AidlComposer::onHotplugDisconnect(Display display) {
}
bool AidlComposer::hasMultiThreadedPresentSupport(Display display) {
+ if (!FlagManager::getInstance().multithreaded_present()) return false;
const auto displayId = translate<int64_t>(display);
std::vector<AidlDisplayCapability> capabilities;
const auto status = mAidlComposerClient->getDisplayCapabilities(displayId, &capabilities);