summaryrefslogtreecommitdiff
path: root/platform/platformminigbm.cpp
AgeCommit message (Collapse)AuthorFilesLines
2019-12-19drm_hwcomposer: Extract ConvertBoInfo() from ImportBuffer() methodRoman Stratiienko1-20/+4
To check either BO could be imported on validation stage, we need to get more information regarding buffer (format, size, etc.) This extraction also allows us to make ImportBuffer() and CanImport() methods generic for all platforms. In case BO can't be imported due to already existant checks in ImportBuffer(), validator only marks single layer to be elaborated by GPU instead of whole composition. Signed-off-by: Roman Stratiienko <roman.stratiienko@globallogic.com>
2019-12-09drm_hwcomposer: Add refcount for GEM handleVincent Donnefort1-0/+2
The linux kernel doesn't provide reference counting for the handle returned by FD_TO_HANDLE ioctl. It means that if the same Gralloc buffer is imported twice, the first GEM_CLOSE will destroy the handle even if it is still in use by another import. Remedy this issue by doing the reference counting directly in the DRM generic platform support: ImportHandle() will increase the reference, while ReleaseHandle() will decrease and close it, if necessary. Signed-off-by: Vincent Donnefort <vincent.donnefort@arm.com>
2019-11-27drm_hwcomposer: Fix missing definition build error on P and earlierRoman Stratiienko1-1/+0
DRM_FORMAT_INVALID was introduced after libdrm-2.4.94, and does not exists in Android-P and earlier. Fixes: f63726cabf3f ("drm_hwcomposer: avoid using signed errno on uint32 type") Signed-off-by: Roman Stratiienko <roman.stratiienko@globallogic.com>
2019-06-11drm_hwcomposer: Organize files into subdirsSean Paul1-0/+87
This is way overdue Signed-off-by: Sean Paul <seanpaul@chromium.org> Change-Id: I1bcbd8fdb0bb03feafd76bc41f6f11c03cdf9c25