From cbbd6d71bf4e785b35d7028e1865f70209e2b6f8 Mon Sep 17 00:00:00 2001 From: Pekka Paalanen Date: Fri, 9 Nov 2018 14:17:12 +0200 Subject: [PATCH] renderer/native: use DRM formats for dumb buffers Change the callers of init_dumb_fb () to use DRM format codes. DRM and GBM format codes are identical, but since this is about dumb buffers, DRM formats fit better. The header /usr/include/gbm.h installed by Mesa says: * The FourCC format codes are taken from the drm_fourcc.h definition, and * re-namespaced. New GBM formats must not be added, unless they are * identical ports from drm_fourcc. That refers to the GBM_FORMAT_* codes. --- src/backends/native/meta-renderer-native.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backends/native/meta-renderer-native.c b/src/backends/native/meta-renderer-native.c index ad4f289c9..13596d002 100644 --- a/src/backends/native/meta-renderer-native.c +++ b/src/backends/native/meta-renderer-native.c @@ -676,7 +676,7 @@ init_secondary_gpu_state_cpu_copy_mode (MetaRendererNative *renderer_nat if (!init_dumb_fb (dumb_fb, gpu_kms, width, height, - GBM_FORMAT_XBGR8888, + DRM_FORMAT_XBGR8888, error)) { secondary_gpu_state_free (secondary_gpu_state); @@ -2434,7 +2434,7 @@ meta_onscreen_native_allocate (CoglOnscreen *onscreen, if (!init_dumb_fb (&onscreen_native->egl.dumb_fb, onscreen_native->render_gpu, width, height, - GBM_FORMAT_XRGB8888, + DRM_FORMAT_XRGB8888, error)) return FALSE;