xserver: Branch 'server-1.20-branch'
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Thu Mar 12 10:47:16 UTC 2020
hw/xwayland/xwayland-glamor-gbm.c | 4 ++++
1 file changed, 4 insertions(+)
New commits:
commit a033571644d277dc49a489f7ae32c4ad92856543
Author: Jonas Ådahl <jadahl at gmail.com>
Date: Fri Sep 13 17:11:27 2019 +0200
xwayland/glamor-gbm: Handle DRM_FORMAT_MOD_INVALID gracefully
The compositor may send DRM_FORMAT_MOD_INVALID instead of a list of
modifiers for various reasons. Handle this gracefully by ignoring it.
Without this, if a compositor would send DRM_FORMAT_MOD_INVALID, it'd
result in empty windows provided by Xwayland.
Signed-off-by: Jonas Ådahl <jadahl at gmail.com>
Reviewed-by: Olivier Fourdan <ofourdan at redhat.com>
Reviewed-by: Michel Dänzer <mdaenzer at redhat.com>
(cherry picked from commit edf964434eac10ffbe27cc883e3ab95505669aee)
diff --git a/hw/xwayland/xwayland-glamor-gbm.c b/hw/xwayland/xwayland-glamor-gbm.c
index c02ba7363..dce782fc3 100644
--- a/hw/xwayland/xwayland-glamor-gbm.c
+++ b/hw/xwayland/xwayland-glamor-gbm.c
@@ -798,6 +798,10 @@ xwl_dmabuf_handle_modifier(void *data, struct zwp_linux_dmabuf_v1 *dmabuf,
struct xwl_format *xwl_format = NULL;
int i;
+ if (modifier_hi == (DRM_FORMAT_MOD_INVALID >> 32) &&
+ modifier_lo == (DRM_FORMAT_MOD_INVALID & 0xffffffff))
+ return;
+
for (i = 0; i < xwl_screen->num_formats; i++) {
if (xwl_screen->formats[i].format == format) {
xwl_format = &xwl_screen->formats[i];
More information about the xorg-commit
mailing list