diff options
author | Treehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com> | 2023-11-09 08:03:01 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2023-11-09 08:03:01 +0000 |
commit | af160a4cec08f6da0d09c0a4700ecc7d07e169d3 (patch) | |
tree | 4426de04af8fcd2e94b81ca078e3524f7812bbe7 | |
parent | d52862cd6ddc892c4f522c67b0f214ee06712c09 (diff) | |
parent | 5c90fe738a2fad705ba01df6eb5b9a33f9a8f3d3 (diff) |
Merge "sf: upsert RenderEngine's caches" into u-keystone-qcom-dev
-rw-r--r-- | services/surfaceflinger/Layer.cpp | 23 |
1 files changed, 5 insertions, 18 deletions
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp index 4f02e4b8d3..0dcac494e3 100644 --- a/services/surfaceflinger/Layer.cpp +++ b/services/surfaceflinger/Layer.cpp @@ -3518,24 +3518,11 @@ void Layer::gatherBufferInfo() { err = mapper.setDataspace(mBufferInfo.mBuffer->getBuffer()->handle, static_cast<ui::Dataspace>(mBufferInfo.mDataspace)); } - - // Some GPU drivers may cache gralloc metadata which means before we composite we need - // to upsert RenderEngine's caches. Put in a special workaround to be backwards - // compatible with old vendors, with a ticking clock. - static const int32_t kVendorVersion = - base::GetIntProperty("ro.vndk.version", __ANDROID_API_FUTURE__); - if (const auto format = - static_cast<aidl::android::hardware::graphics::common::PixelFormat>( - mBufferInfo.mBuffer->getPixelFormat()); - err == OK && kVendorVersion < __ANDROID_API_U__ && - (format == - aidl::android::hardware::graphics::common::PixelFormat:: - IMPLEMENTATION_DEFINED || - format == aidl::android::hardware::graphics::common::PixelFormat::YCBCR_420_888 || - format == aidl::android::hardware::graphics::common::PixelFormat::YV12 || - format == aidl::android::hardware::graphics::common::PixelFormat::YCBCR_P010)) { - mBufferInfo.mBuffer->remapBuffer(); - } + /* QTI_BEGIN */ + // GPU drivers cache gralloc metadata which means before we composite we need + // to upsert RenderEngine's cache. + mBufferInfo.mBuffer->remapBuffer(); + /* QTI_END */ } } if (lastDataspace != mBufferInfo.mDataspace) { |