Gralloc: Do not use adreno for secure camera and secure display
Avoid using adreno size calculations for secure camera and
secure display buffers.
Change-Id: Ib61d893cbcc57b10070250a63b8fa79106de4af3
CRs-Fixed: 2262355
diff --git a/gralloc/gr_buf_mgr.cpp b/gralloc/gr_buf_mgr.cpp
index 7aa4b05..41f590d 100644
--- a/gralloc/gr_buf_mgr.cpp
+++ b/gralloc/gr_buf_mgr.cpp
@@ -285,7 +285,7 @@
bool use_adreno_for_size = false;
GraphicsMetadata graphics_metadata = {};
- use_adreno_for_size = ((buffer_type != BUFFER_TYPE_VIDEO) && GetAdrenoSizeAPIStatus());
+ use_adreno_for_size = CanUseAdrenoForSize(buffer_type, usage);
if (use_adreno_for_size) {
GetGpuResourceSizeAndDimensions(info, &size, &alignedw, &alignedh, &graphics_metadata);
} else {