aboutsummaryrefslogtreecommitdiff
path: root/bufferinfo/legacy/BufferInfoLibdrm.h
diff options
context:
space:
mode:
authorRoman Stratiienko <roman.o.stratiienko@globallogic.com>2021-11-30 17:06:44 +0200
committerRoman Stratiienko <roman.o.stratiienko@globallogic.com>2021-12-06 13:22:34 +0200
commit39d8f7e1934b40dc84e784f2ab2f637f1a6202bb (patch)
tree65ea53ecfab78033746dc497d2e755b9e2ecbf39 /bufferinfo/legacy/BufferInfoLibdrm.h
parenta148f21336adb103964fea1d2cacc3f408715c4b (diff)
downloaddrm_hwcomposer-39d8f7e1934b40dc84e784f2ab2f637f1a6202bb.tar.gz
drm_hwcomposer: Validate gralloc0 name for minigbm and libdrm getters
Using of incorrect gralloc0 results in a runtime issues, with logs like "Cannot convert hal format to drm format <VALUE>" or other. Validate gralloc name and exit gracefully in case it doesnt't match the one we are expecting. Signed-off-by: Roman Stratiienko <roman.o.stratiienko@globallogic.com>
Diffstat (limited to 'bufferinfo/legacy/BufferInfoLibdrm.h')
-rw-r--r--bufferinfo/legacy/BufferInfoLibdrm.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/bufferinfo/legacy/BufferInfoLibdrm.h b/bufferinfo/legacy/BufferInfoLibdrm.h
index 4d37d00..cad8add 100644
--- a/bufferinfo/legacy/BufferInfoLibdrm.h
+++ b/bufferinfo/legacy/BufferInfoLibdrm.h
@@ -27,6 +27,7 @@ class BufferInfoLibdrm : public LegacyBufferInfoGetter {
public:
using LegacyBufferInfoGetter::LegacyBufferInfoGetter;
int ConvertBoInfo(buffer_handle_t handle, hwc_drm_bo_t *bo) override;
+ int ValidateGralloc() override;
private:
bool GetYuvPlaneInfo(int num_fds, buffer_handle_t handle, hwc_drm_bo_t *bo);