platform_hardware_interfaces/graphics/mapper/2.1
David Stevens be8f52e8b0 graphics: fix use-after-free in mapper 2.0 passthrough
The mapper 2.0 gralloc passthrough keeps a set of the native_handle_t
pointers of all imported buffers. This change ensures that the
underlying HAL wrapper freeing the native_handle_t is performed
atomically with respect to accesses to the passthrough's native_handle_t
pointer set.

This fixes a race where a native_handle_t could be reallocated between
being freed by the HAL wrapper and removed from the passthrough's set,
which could then cause the import which happened to reallocate that
native_handle_t to spuriously fail.

Bug: 170798776
Test: Manually very no more spurious import failures in ARCVM's decoder.
Change-Id: I654a44e94adb319f54fb462f4484db414ca1b154
2020-10-22 09:45:09 +09:00
..
default graphics: update OWNERS 2020-03-26 19:31:56 +00:00
utils graphics: fix use-after-free in mapper 2.0 passthrough 2020-10-22 09:45:09 +09:00
vts Mark GraphicsMapperHidlTest as allowing not being instantiated 2020-09-25 21:07:53 -07:00
Android.bp Update hidl makefiles for bpfmt 2019-04-17 09:38:50 -07:00
IMapper.hal graphics: add createDescriptor_2_1 to mapper 2018-01-23 20:37:51 -08:00