From 0b7de744a0e11ed74eb902e872918ad8856f4916 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michel=20D=C3=A4nzer?= Date: Tue, 20 Sep 2022 19:00:37 +0200 Subject: [PATCH] wayland/dma-buf: Use meta_renderer_native_send_modifiers Do not send modifiers if meta_renderer_native_send_modifiers says not to (and we use scanout). Part-of: --- src/wayland/meta-wayland-dma-buf.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/wayland/meta-wayland-dma-buf.c b/src/wayland/meta-wayland-dma-buf.c index 0f6f6be02..350be1618 100644 --- a/src/wayland/meta-wayland-dma-buf.c +++ b/src/wayland/meta-wayland-dma-buf.c @@ -154,8 +154,6 @@ should_send_modifiers (MetaBackend *backend) { MetaRendererNative *renderer_native; MetaGpuKms *gpu_kms; - MetaKmsDevice *kms_device; - MetaKmsDeviceFlag flags; if (!META_IS_BACKEND_NATIVE (backend)) return FALSE; @@ -165,11 +163,7 @@ should_send_modifiers (MetaBackend *backend) if (!gpu_kms) return TRUE; - kms_device = meta_gpu_kms_get_kms_device (gpu_kms); - - flags = meta_kms_device_get_flags (kms_device); - - return !!(flags & META_KMS_DEVICE_FLAG_HAS_ADDFB2); + return meta_renderer_native_send_modifiers (renderer_native); } static gint