diff options
author | Dominggoes Isakh <drjisakh@gmail.com> | 2019-02-15 22:08:09 +0100 |
---|---|---|
committer | Shilin Victor <chrono.monochrome@gmail.com> | 2019-02-24 01:26:26 +0300 |
commit | d480a7affe9f64792e219efaa52ddd98f37a300e (patch) | |
tree | dbc6380c665c5a4f369b078b5b0b2bb0ed6025f6 /exynos4 | |
parent | bb91a6029facbb74dfa4bba58bb18461c22734ea (diff) | |
download | hardware_samsung-d480a7affe9f64792e219efaa52ddd98f37a300e.tar.gz hardware_samsung-d480a7affe9f64792e219efaa52ddd98f37a300e.tar.bz2 hardware_samsung-d480a7affe9f64792e219efaa52ddd98f37a300e.zip |
gralloc: Disable ION allocation for HWC
We got screen tearing issues because only one buffer was used
in /dev/graphics/fb0.
Credits goes to @Chronomonochome for his original commit.
Change-Id: I321bb19ce586a74319941046800f0db07ce7bf98
Diffstat (limited to 'exynos4')
-rw-r--r-- | exynos4/hal/libgralloc_ump/alloc_device.cpp | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/exynos4/hal/libgralloc_ump/alloc_device.cpp b/exynos4/hal/libgralloc_ump/alloc_device.cpp index 7a4c672..cd53376 100644 --- a/exynos4/hal/libgralloc_ump/alloc_device.cpp +++ b/exynos4/hal/libgralloc_ump/alloc_device.cpp @@ -296,12 +296,7 @@ static int gralloc_alloc_buffer(alloc_device_t* dev, size_t size, int usage, } ret = -1; - if (usage & (GRALLOC_USAGE_HW_COMPOSER | GRALLOC_USAGE_HW_ION)) { - ALOGV("%s: Allocating for HWC via ION...", __func__); - // the handle is guaranteed to have this usage flag set - // if it is going to be used as an HWC layer (see hwcomposer.h in hardware/libhardware) - ret = gralloc_alloc_ion(dev, size, usage, format, &ion_fd, &ion_paddr, &priv_alloc_flag, &ump_mem_handle); - } else if (usage & (GRALLOC_USAGE_HW_RENDER | GRALLOC_USAGE_HW_TEXTURE)) { + if (usage & (GRALLOC_USAGE_HW_RENDER | GRALLOC_USAGE_HW_TEXTURE)) { ALOGV("%s: Allocating graphicbuffer via ION...", __func__); priv_alloc_flag = priv_alloc_flag | private_handle_t::PRIV_FLAGS_GRAPHICBUFFER; ret = gralloc_alloc_ion(dev, size, usage, format, &ion_fd, &ion_paddr, &priv_alloc_flag, &ump_mem_handle); |