OSDN Git Service

gralloc ashmem hack to delay cb close
authorLingfeng Yang <lfy@google.com>
Sat, 6 May 2017 08:00:03 +0000 (01:00 -0700)
committerandroid-build-team Robot <android-build-team-robot@google.com>
Fri, 23 Jun 2017 20:45:13 +0000 (20:45 +0000)
commit8a78b215c555fa8a3f793c72f12f50b199c57d7d
treee956fe7377d7081b8551f01f7603612dff0827ea
parentdcacca1449afecd0604a16c8dc97e2a67c47ce56
gralloc ashmem hack to delay cb close

Tired of public emulators not working with O

See this CL for context:

https://android-review.googlesource.com/#/c/372376/

This CL moves that to the guest, and detects if
each gralloc cb has been opened at least once
before allowing gralloc_free to call rcCloseColorBuffer.

Images using Treble / HIDL gralloc that have this CL
should work with older emulator versions.

Bug: 37302997

Test: Build and run sdk_google_aw_x86-userdebug emulator

Change-Id: Ice72269e4295497825050385b15dbdec2258100c
(cherry picked from commit ef6676015bfec4538a552204b51e32f02d721fb0)
Android.mk
system/gralloc/gralloc.cpp