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.

Change-Id: Ice72269e4295497825050385b15dbdec2258100c
2 files changed
tree: 92f63e07ac2dcf5d4b862ad5754de069b3a6a8f5
  1. host/
  2. shared/
  3. system/
  4. tests/
  5. Android.mk
  6. common.mk
  7. README