diff --git a/gralloc_priv.h b/gralloc_priv.h index a9a665d..3869ac3 100644 --- a/gralloc_priv.h +++ b/gralloc_priv.h @@ -311,6 +311,7 @@ struct private_handle_t { PRIV_FLAGS_USES_PMEM_ADSP = 0x00000004, PRIV_FLAGS_NEEDS_FLUSH = 0x00000008, PRIV_FLAGS_USES_ASHMEM = 0x00000010, + PRIV_FLAGS_DO_NOT_FLUSH = 0x00000020, }; enum { diff --git a/mapper.cpp b/mapper.cpp index 4223ae7..4a83483 100644 --- a/mapper.cpp +++ b/mapper.cpp @@ -354,7 +354,8 @@ int gralloc_perform(struct gralloc_module_t const* module, hnd->magic = private_handle_t::sMagic; hnd->fd = fd; hnd->flags = (memoryFlags == GRALLOC_USAGE_PRIVATE_PMEM) ? - private_handle_t::PRIV_FLAGS_USES_PMEM : + private_handle_t::PRIV_FLAGS_USES_PMEM | + private_handle_t::PRIV_FLAGS_DO_NOT_FLUSH: private_handle_t::PRIV_FLAGS_USES_ASHMEM; hnd->size = size; hnd->offset = offset;