libgralloc-qsd8k: ashmem changes
- Remove unused GRALLOC_USAGE_PRIVATE_PMEM flag. This flag is no longer used. - Flush ashmem region cache instead of Invalidating it. (cherry picked from commit 12254ff74f5a97dcf5ded90f53e9d6fd0fa47b9c) Change-Id: I92e4dcd8c89eb9ae0c0484f039d152b7bbb28bbe
This commit is contained in:
parent
4066a02c83
commit
1efe8832e9
@ -181,10 +181,6 @@ int gpu_context_t::gralloc_alloc_buffer(size_t size, int usage, buffer_handle_t*
|
||||
if (usage & GRALLOC_USAGE_HW_2D) {
|
||||
flags |= private_handle_t::PRIV_FLAGS_USES_PMEM;
|
||||
}
|
||||
#else
|
||||
if (usage & GRALLOC_USAGE_PRIVATE_PMEM){
|
||||
flags |= private_handle_t::PRIV_FLAGS_USES_PMEM;
|
||||
}
|
||||
#endif
|
||||
if ((usage & GRALLOC_USAGE_PRIVATE_PMEM_ADSP) || (usage & GRALLOC_USAGE_PRIVATE_PMEM_SMIPOOL)) {
|
||||
flags |= private_handle_t::PRIV_FLAGS_USES_PMEM_ADSP;
|
||||
|
@ -291,7 +291,7 @@ int gralloc_unlock(gralloc_module_t const* module,
|
||||
err = ioctl( hnd->fd, PMEM_CLEAN_CACHES, &pmem_addr);
|
||||
} else if ((hnd->flags & private_handle_t::PRIV_FLAGS_USES_ASHMEM)) {
|
||||
unsigned long addr = hnd->base + hnd->offset;
|
||||
err = ioctl(hnd->fd, ASHMEM_CACHE_CLEAN_RANGE, NULL);
|
||||
err = ioctl(hnd->fd, ASHMEM_CACHE_FLUSH_RANGE, NULL);
|
||||
}
|
||||
|
||||
LOGE_IF(err < 0, "cannot flush handle %p (offs=%x len=%x)\n",
|
||||
|
Loading…
Reference in New Issue
Block a user