Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/xorg-x11-server.git#283d9cdb0767a503157cec6279cf6fe622d365c2
This commit is contained in:
DistroBaker 2020-12-02 10:20:39 +00:00
parent 8eca31ec62
commit 9ac3ca055f
43 changed files with 177 additions and 1377 deletions

View File

@ -1,61 +0,0 @@
From 4b6fce5975c2f931a0478cf4deeec97529b05eb6 Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Tue, 8 Sep 2020 10:01:55 +0200
Subject: [PATCH xserver 01/16] Revert "linux: Fix platform device probe for
DT-based PCI"
This reverts commit 249a12c54a9316b089bd22683c011519348496df.
https://gitlab.freedesktop.org/xorg/xserver/-/issues/1068
---
config/udev.c | 27 +--------------------------
1 file changed, 1 insertion(+), 26 deletions(-)
diff --git a/config/udev.c b/config/udev.c
index b00d90237..14409549b 100644
--- a/config/udev.c
+++ b/config/udev.c
@@ -464,31 +464,6 @@ config_udev_fini(void)
#ifdef CONFIG_UDEV_KMS
-/* Find the last occurrence of the needle in haystack */
-static char *strrstr(const char *haystack, const char *needle)
-{
- char *prev, *last, *tmp;
-
- prev = strstr(haystack, needle);
- if (!prev)
- return NULL;
-
- last = prev;
- tmp = prev + 1;
-
- while (tmp) {
- last = strstr(tmp, needle);
- if (!last)
- return prev;
- else {
- prev = last;
- tmp = prev + 1;
- }
- }
-
- return last;
-}
-
static void
config_udev_odev_setup_attribs(struct udev_device *udev_device, const char *path, const char *syspath,
int major, int minor,
@@ -503,7 +478,7 @@ config_udev_odev_setup_attribs(struct udev_device *udev_device, const char *path
attribs->minor = minor;
value = udev_device_get_property_value(udev_device, "ID_PATH");
- if (value && (str = strrstr(value, "pci-"))) {
+ if (value && (str = strstr(value, "pci-"))) {
attribs->busid = XNFstrdup(str);
attribs->busid[3] = ':';
}
--
2.28.0

View File

@ -1,7 +1,7 @@
From 3d78af269556f554c517801d0de481ba56d4e603 Mon Sep 17 00:00:00 2001
From a815e5f51f75684a53d8fa14b596e03b738cd281 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Thu, 29 Aug 2019 14:18:28 +0200
Subject: [PATCH xserver 01/24] dix: Add GetCurrentClient helper
Subject: [PATCH xserver 01/25] dix: Add GetCurrentClient helper
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
@ -112,5 +112,5 @@ index b6e2bcfde..d65060cb6 100644
extern _X_EXPORT void SetInputCheck(HWEventQueuePtr /*c0 */ ,
HWEventQueuePtr /*c1 */ );
--
2.26.2
2.28.0

View File

@ -1,40 +0,0 @@
From 39cb95e959fab97a7e255dda1a1599b096fb0f7e Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Tue, 8 Sep 2020 10:03:11 +0200
Subject: [PATCH xserver 02/16] Revert "linux: Fix platform device PCI
detection for complex bus topologies"
This reverts commit 5c96eb5f44e62a4cfe835023cde304eb5795b8fd.
https://gitlab.freedesktop.org/xorg/xserver/-/issues/1068
---
config/udev.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/config/udev.c b/config/udev.c
index 14409549b..8c6c4b666 100644
--- a/config/udev.c
+++ b/config/udev.c
@@ -470,7 +470,7 @@ config_udev_odev_setup_attribs(struct udev_device *udev_device, const char *path
config_odev_probe_proc_ptr probe_callback)
{
struct OdevAttributes *attribs = config_odev_allocate_attributes();
- const char *value, *str;
+ const char *value;
attribs->path = XNFstrdup(path);
attribs->syspath = XNFstrdup(syspath);
@@ -478,8 +478,8 @@ config_udev_odev_setup_attribs(struct udev_device *udev_device, const char *path
attribs->minor = minor;
value = udev_device_get_property_value(udev_device, "ID_PATH");
- if (value && (str = strstr(value, "pci-"))) {
- attribs->busid = XNFstrdup(str);
+ if (value && !strncmp(value, "pci-", 4)) {
+ attribs->busid = XNFstrdup(value);
attribs->busid[3] = ':';
}
--
2.28.0

View File

@ -1,7 +1,7 @@
From 14e9b030449611a7a80f640129138c49ab46774e Mon Sep 17 00:00:00 2001
From 0a3046286e69b171c319ff419c94cf62929246bf Mon Sep 17 00:00:00 2001
From: Robert Mader <robert.mader@posteo.de>
Date: Mon, 22 Jan 2018 22:02:32 +0100
Subject: [PATCH xserver 02/24] xwayland: Add wp_viewport wayland extension
Subject: [PATCH xserver 02/25] xwayland: Add wp_viewport wayland extension
support
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -81,10 +81,10 @@ index 36bf2133a..4a8d171bb 100644
xwayland_glamor = []
eglstream_srcs = []
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index d02934cd5..98592025a 100644
index b353167c3..a70c1002f 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -925,6 +925,9 @@ registry_global(void *data, struct wl_registry *registry, uint32_t id,
@@ -912,6 +912,9 @@ registry_global(void *data, struct wl_registry *registry, uint32_t id,
wl_registry_bind(registry, id, &zxdg_output_manager_v1_interface, 1);
xwl_screen_init_xdg_output(xwl_screen);
}
@ -115,5 +115,5 @@ index b9495b313..91ae21eeb 100644
#define XWL_FORMAT_ARGB8888 (1 << 0)
--
2.26.2
2.28.0

View File

@ -1,133 +0,0 @@
From af4c84ce8855e84c0ad89b929bc972e884f0b8e3 Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Tue, 8 Sep 2020 10:03:33 +0200
Subject: [PATCH xserver 03/16] Revert "linux: Make platform device probe less
fragile"
This reverts commit 74b7427c41b4e4104af7abf70a996c086d3d7628.
https://gitlab.freedesktop.org/xorg/xserver/-/issues/1068
---
config/udev.c | 17 +++++------------
hw/xfree86/os-support/linux/lnx_platform.c | 20 ++++++++++++++++++--
2 files changed, 23 insertions(+), 14 deletions(-)
diff --git a/config/udev.c b/config/udev.c
index 8c6c4b666..3a73189e2 100644
--- a/config/udev.c
+++ b/config/udev.c
@@ -56,7 +56,7 @@ static struct udev_monitor *udev_monitor;
#ifdef CONFIG_UDEV_KMS
static void
-config_udev_odev_setup_attribs(struct udev_device *udev_device, const char *path, const char *syspath,
+config_udev_odev_setup_attribs(const char *path, const char *syspath,
int major, int minor,
config_odev_probe_proc_ptr probe_callback);
#endif
@@ -128,7 +128,7 @@ device_added(struct udev_device *udev_device)
LogMessage(X_INFO, "config/udev: Adding drm device (%s)\n", path);
- config_udev_odev_setup_attribs(udev_device, path, syspath, major(devnum),
+ config_udev_odev_setup_attribs(path, syspath, major(devnum),
minor(devnum), NewGPUDeviceRequest);
return;
}
@@ -322,7 +322,7 @@ device_removed(struct udev_device *device)
LogMessage(X_INFO, "config/udev: removing GPU device %s %s\n",
syspath, path);
- config_udev_odev_setup_attribs(device, path, syspath, major(devnum),
+ config_udev_odev_setup_attribs(path, syspath, major(devnum),
minor(devnum), DeleteGPUDeviceRequest);
/* Retry vtenter after a drm node removal */
systemd_logind_vtenter();
@@ -465,24 +465,17 @@ config_udev_fini(void)
#ifdef CONFIG_UDEV_KMS
static void
-config_udev_odev_setup_attribs(struct udev_device *udev_device, const char *path, const char *syspath,
+config_udev_odev_setup_attribs(const char *path, const char *syspath,
int major, int minor,
config_odev_probe_proc_ptr probe_callback)
{
struct OdevAttributes *attribs = config_odev_allocate_attributes();
- const char *value;
attribs->path = XNFstrdup(path);
attribs->syspath = XNFstrdup(syspath);
attribs->major = major;
attribs->minor = minor;
- value = udev_device_get_property_value(udev_device, "ID_PATH");
- if (value && !strncmp(value, "pci-", 4)) {
- attribs->busid = XNFstrdup(value);
- attribs->busid[3] = ':';
- }
-
/* ownership of attribs is passed to probe layer */
probe_callback(attribs);
}
@@ -523,7 +516,7 @@ config_udev_odev_probe(config_odev_probe_proc_ptr probe_callback)
else if (!check_seat(udev_device))
goto no_probe;
- config_udev_odev_setup_attribs(udev_device, path, syspath, major(devnum),
+ config_udev_odev_setup_attribs(path, syspath, major(devnum),
minor(devnum), probe_callback);
no_probe:
udev_device_unref(udev_device);
diff --git a/hw/xfree86/os-support/linux/lnx_platform.c b/hw/xfree86/os-support/linux/lnx_platform.c
index e62306219..70374ace8 100644
--- a/hw/xfree86/os-support/linux/lnx_platform.c
+++ b/hw/xfree86/os-support/linux/lnx_platform.c
@@ -23,13 +23,13 @@
static Bool
get_drm_info(struct OdevAttributes *attribs, char *path, int delayed_index)
{
+ drmSetVersion sv;
drmVersionPtr v;
+ char *buf;
int fd;
int err = 0;
Bool paused, server_fd = FALSE;
- LogMessage(X_INFO, "Platform probe for %s\n", attribs->syspath);
-
fd = systemd_logind_take_fd(attribs->major, attribs->minor, path, &paused);
if (fd != -1) {
if (paused) {
@@ -48,6 +48,18 @@ get_drm_info(struct OdevAttributes *attribs, char *path, int delayed_index)
if (fd == -1)
return FALSE;
+ sv.drm_di_major = 1;
+ sv.drm_di_minor = 4;
+ sv.drm_dd_major = -1; /* Don't care */
+ sv.drm_dd_minor = -1; /* Don't care */
+
+ err = drmSetInterfaceVersion(fd, &sv);
+ if (err) {
+ xf86Msg(X_ERROR, "%s: failed to set DRM interface version 1.4: %s\n",
+ path, strerror(-err));
+ goto out;
+ }
+
/* for a delayed probe we've already added the device */
if (delayed_index == -1) {
xf86_add_platform_device(attribs, FALSE);
@@ -57,6 +69,10 @@ get_drm_info(struct OdevAttributes *attribs, char *path, int delayed_index)
if (server_fd)
xf86_platform_devices[delayed_index].flags |= XF86_PDEV_SERVER_FD;
+ buf = drmGetBusid(fd);
+ xf86_platform_odev_attributes(delayed_index)->busid = XNFstrdup(buf);
+ drmFreeBusid(buf);
+
v = drmGetVersion(fd);
if (!v) {
xf86Msg(X_ERROR, "%s: failed to query DRM version\n", path);
--
2.28.0

View File

@ -1,7 +1,7 @@
From a86c70ed7e9c2b4e8e2f93beddbc51c0cdad57f2 Mon Sep 17 00:00:00 2001
From 30859f64d1718d1476648dcddbb3d81c2f932828 Mon Sep 17 00:00:00 2001
From: Robert Mader <robert.mader@posteo.de>
Date: Tue, 2 Jul 2019 12:03:12 +0200
Subject: [PATCH xserver 03/24] xwayland: Use buffer_damage instead of surface
Subject: [PATCH xserver 03/25] xwayland: Use buffer_damage instead of surface
damage if available
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -64,10 +64,10 @@ index 66720bcc0..cbc715061 100644
xwl_cursor->frame_cb = wl_surface_frame(xwl_cursor->surface);
wl_callback_add_listener(xwl_cursor->frame_cb, &frame_listener, xwl_cursor);
diff --git a/hw/xwayland/xwayland-present.c b/hw/xwayland/xwayland-present.c
index 6076f6498..ef75ad2ef 100644
index d177abdd8..f4027f91e 100644
--- a/hw/xwayland/xwayland-present.c
+++ b/hw/xwayland/xwayland-present.c
@@ -497,11 +497,11 @@ xwl_present_flip(WindowPtr present_window,
@@ -505,11 +505,11 @@ xwl_present_flip(WindowPtr present_window,
/* Realign timer */
xwl_present_reset_timer(xwl_present_window);
@ -85,10 +85,10 @@ index 6076f6498..ef75ad2ef 100644
wl_surface_commit(xwl_window->surface);
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 98592025a..f7fcd1e32 100644
index a70c1002f..811257b00 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -805,6 +805,16 @@ xwl_destroy_window(WindowPtr window)
@@ -792,6 +792,16 @@ xwl_destroy_window(WindowPtr window)
return ret;
}
@ -105,7 +105,7 @@ index 98592025a..f7fcd1e32 100644
static void
xwl_window_post_damage(struct xwl_window *xwl_window)
{
@@ -841,13 +851,15 @@ xwl_window_post_damage(struct xwl_window *xwl_window)
@@ -828,13 +838,15 @@ xwl_window_post_damage(struct xwl_window *xwl_window)
*/
if (RegionNumRects(region) > 256) {
box = RegionExtents(region);
@ -126,7 +126,7 @@ index 98592025a..f7fcd1e32 100644
}
xwl_window_create_frame_callback(xwl_window);
@@ -906,8 +918,13 @@ registry_global(void *data, struct wl_registry *registry, uint32_t id,
@@ -893,8 +905,13 @@ registry_global(void *data, struct wl_registry *registry, uint32_t id,
struct xwl_screen *xwl_screen = data;
if (strcmp(interface, "wl_compositor") == 0) {
@ -156,5 +156,5 @@ index 91ae21eeb..1244d2e91 100644
void xwl_screen_roundtrip (struct xwl_screen *xwl_screen);
--
2.26.2
2.28.0

View File

@ -1,35 +0,0 @@
From b28c882889cbea9be3748d3dee1b21ba6eb90b66 Mon Sep 17 00:00:00 2001
From: Arthur Williams <taaparthur@gmail.com>
Date: Fri, 25 Sep 2020 04:52:57 +0000
Subject: [PATCH xserver 04/16] include: Increase the number of max. input
devices to 256.
Extending the decade old f0124ed93, to increase the number of input
devices from 40 to 256. 40 translates at most 9 MD, while 256 will allow
63 MD. It is an arbitrary number, but people are hitting the current
limit under reasonable conditions.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=64793
Signed-off-by: Arthur Williams <taaparthur@gmail.com>
(cherry picked from commit fe439596b99db65bbae35eff1ea0b79db167f8d6)
---
include/misc.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/misc.h b/include/misc.h
index 14920c3c3..9b422e53b 100644
--- a/include/misc.h
+++ b/include/misc.h
@@ -91,7 +91,7 @@ OF THIS SOFTWARE.
#define LIMITCLIENTS 256 /* Must be a power of 2 and <= MAXCLIENTS */
#define MAXEXTENSIONS 128
#define MAXFORMATS 8
-#define MAXDEVICES 40 /* input devices */
+#define MAXDEVICES 256 /* input devices */
#define GPU_SCREEN_OFFSET 256
/* 128 event opcodes for core + extension events, excluding GE */
--
2.28.0

View File

@ -1,7 +1,7 @@
From c0595515c65571d6304530c51331013381eea1dd Mon Sep 17 00:00:00 2001
From 32987e08e7f1e79ee50ce032cc6c1b6d28e6a50d Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Wed, 26 Jun 2019 16:46:54 +0200
Subject: [PATCH xserver 04/24] xwayland: Add fake output modes to xrandr
Subject: [PATCH xserver 04/25] xwayland: Add fake output modes to xrandr
output mode lists
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -163,7 +163,7 @@ index ae646c663..4036ba681 100644
xorg_list_for_each_entry(it, &xwl_screen->output_list, link) {
/* output done event is sent even when some property
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index f7fcd1e32..ffd4809df 100644
index 811257b00..e84515f94 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -154,6 +154,23 @@ xwl_screen_get(ScreenPtr screen)
@ -203,5 +203,5 @@ index 1244d2e91..200e18a8d 100644
void xwl_tablet_tool_set_cursor(struct xwl_tablet_tool *tool);
void xwl_seat_set_cursor(struct xwl_seat *xwl_seat);
--
2.26.2
2.28.0

View File

@ -1,71 +0,0 @@
From 8c3c8bda2c44fb3d62b954b02b08e3b1771ef5bc Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Tue, 25 Aug 2020 17:26:56 +0200
Subject: [PATCH xserver 05/16] glamor: Fix glamor_poly_fill_rect_gl
xRectangle::width/height handling
(Using GLSL 1.30 or newer)
The width/height members of xRectangle are unsigned, but they were
being interpreted as signed when converting to floating point for the
vertex shader, producing incorrect drawing for values > 32767.
v2:
* Use separate GL_UNSIGNED_SHORT vertex attribute for width/height.
(Eric Anholt)
Reviewed-by: Eric Anholt <eric@anholt.net>
(cherry picked from commit 032af35657aa95c6bbdb74ff8c72e535b9b56cfa)
---
glamor/glamor_rects.c | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
diff --git a/glamor/glamor_rects.c b/glamor/glamor_rects.c
index 6cbb040c1..ae4fe8bcc 100644
--- a/glamor/glamor_rects.c
+++ b/glamor/glamor_rects.c
@@ -27,8 +27,10 @@
static const glamor_facet glamor_facet_polyfillrect_130 = {
.name = "poly_fill_rect",
.version = 130,
- .vs_vars = "attribute vec4 primitive;\n",
- .vs_exec = (" vec2 pos = primitive.zw * vec2(gl_VertexID&1, (gl_VertexID&2)>>1);\n"
+ .source_name = "size",
+ .vs_vars = "attribute vec2 primitive;\n"
+ "attribute vec2 size;\n",
+ .vs_exec = (" vec2 pos = size * vec2(gl_VertexID&1, (gl_VertexID&2)>>1);\n"
GLAMOR_POS(gl_Position, (primitive.xy + pos))),
};
@@ -81,9 +83,14 @@ glamor_poly_fill_rect_gl(DrawablePtr drawable,
glEnableVertexAttribArray(GLAMOR_VERTEX_POS);
glVertexAttribDivisor(GLAMOR_VERTEX_POS, 1);
- glVertexAttribPointer(GLAMOR_VERTEX_POS, 4, GL_SHORT, GL_FALSE,
+ glVertexAttribPointer(GLAMOR_VERTEX_POS, 2, GL_SHORT, GL_FALSE,
4 * sizeof (short), vbo_offset);
+ glEnableVertexAttribArray(GLAMOR_VERTEX_SOURCE);
+ glVertexAttribDivisor(GLAMOR_VERTEX_SOURCE, 1);
+ glVertexAttribPointer(GLAMOR_VERTEX_SOURCE, 2, GL_UNSIGNED_SHORT, GL_FALSE,
+ 4 * sizeof (short), vbo_offset + 2 * sizeof (short));
+
memcpy(v, prect, nrect * sizeof (xRectangle));
glamor_put_vbo_space(screen);
@@ -156,8 +163,11 @@ glamor_poly_fill_rect_gl(DrawablePtr drawable,
bail:
glDisable(GL_SCISSOR_TEST);
- if (glamor_priv->glsl_version >= 130)
+ if (glamor_priv->glsl_version >= 130) {
+ glVertexAttribDivisor(GLAMOR_VERTEX_SOURCE, 0);
+ glDisableVertexAttribArray(GLAMOR_VERTEX_SOURCE);
glVertexAttribDivisor(GLAMOR_VERTEX_POS, 0);
+ }
glDisableVertexAttribArray(GLAMOR_VERTEX_POS);
return ret;
--
2.28.0

View File

@ -1,7 +1,7 @@
From 19e725dd368e25c057770530cdd622234303003e Mon Sep 17 00:00:00 2001
From 09dcf01f5ea8d1f828a58e54edd608e6918d0b59 Mon Sep 17 00:00:00 2001
From: Robert Mader <robert.mader@posteo.de>
Date: Mon, 22 Jan 2018 17:57:38 +0100
Subject: [PATCH xserver 05/24] xwayland: Use RandR 1.2 interface (rev 2)
Subject: [PATCH xserver 05/25] xwayland: Use RandR 1.2 interface (rev 2)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
@ -135,5 +135,5 @@ index 4036ba681..633ebb89e 100644
return TRUE;
}
--
2.26.2
2.28.0

View File

@ -1,34 +0,0 @@
From 1e84fda2020b12a83c6b9c6d31ab84f993c6176c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Tue, 1 Sep 2020 11:24:57 +0200
Subject: [PATCH xserver 06/16] xfree86: Take second reference for SavedCursor
in xf86CursorSetCursor
The same pointer is kept in CurrentCursor as well, therefore two
RefCursor calls are needed.
Fixes use-after-free after switching VTs.
Closes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1067
(cherry picked from commit 919f1f46fc67dae93b2b3f278fcbfc77af34ec58)
---
hw/xfree86/ramdac/xf86CursorRD.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/hw/xfree86/ramdac/xf86CursorRD.c b/hw/xfree86/ramdac/xf86CursorRD.c
index ee1d98916..02dab36fe 100644
--- a/hw/xfree86/ramdac/xf86CursorRD.c
+++ b/hw/xfree86/ramdac/xf86CursorRD.c
@@ -334,6 +334,9 @@ xf86CursorSetCursor(DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCurs,
ScreenPriv->HotY = cursor->bits->yhot;
if (!infoPtr->pScrn->vtSema) {
+ cursor = RefCursor(cursor);
+ if (ScreenPriv->SavedCursor)
+ FreeCursor(ScreenPriv->SavedCursor, None);
ScreenPriv->SavedCursor = cursor;
return;
}
--
2.28.0

View File

@ -1,7 +1,7 @@
From e6ba28eb96b227e47c371a7063f778fb2ab82a0b Mon Sep 17 00:00:00 2001
From ca0616ca4ca1badff2674fa5db8f290935b81e7f Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Thu, 29 Aug 2019 22:45:12 +0200
Subject: [PATCH xserver 06/24] xwayland: Add per client private data
Subject: [PATCH xserver 06/25] xwayland: Add per client private data
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
@ -21,7 +21,7 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2 files changed, 19 insertions(+)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index ffd4809df..e00dba334 100644
index e84515f94..f422cfc29 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -137,11 +137,18 @@ ddxProcessArgument(int argc, char *argv[], int i)
@ -43,7 +43,7 @@ index ffd4809df..e00dba334 100644
static struct xwl_window *
xwl_window_get(WindowPtr window)
{
@@ -1158,6 +1165,13 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
@@ -1145,6 +1152,13 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
return FALSE;
if (!dixRegisterPrivateKey(&xwl_damage_private_key, PRIVATE_WINDOW, 0))
return FALSE;
@ -76,5 +76,5 @@ index 200e18a8d..19626d394 100644
void xwl_surface_damage(struct xwl_screen *xwl_screen,
struct wl_surface *surface,
--
2.26.2
2.28.0

View File

@ -1,37 +0,0 @@
From f4006d795cb199bf7deeb00f542c592db6a5becb Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Mon, 7 Sep 2020 18:35:10 +0200
Subject: [PATCH xserver 07/16] present/wnmd: Can't use page flipping for
windows clipped by children
Noticed this was missing while working on the following fix.
v2:
* Dropped present_wnmd_can_window_flip hunk (that function is never
called, will be cleaned up in a follow-up MR).
Reviewed-by: Olivier Fourdan <ofourdan@redhat.com> # v1
Reviewed-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit 7ac303c7b1e3b1be79ba3648e217798683e65a99)
---
present/present_wnmd.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/present/present_wnmd.c b/present/present_wnmd.c
index 32c4d55f1..6a3d1035b 100644
--- a/present/present_wnmd.c
+++ b/present/present_wnmd.c
@@ -291,6 +291,10 @@ present_wnmd_check_flip(RRCrtcPtr crtc,
if ( !RegionEqual(&window->winSize, &toplvl_window->winSize) )
return FALSE;
+ /* Can't flip if window clipped by children */
+ if (!RegionEqual(&window->clipList, &window->winSize))
+ return FALSE;
+
/* Ask the driver for permission */
if (screen_priv->wnmd_info->check_flip2) {
if (!(*screen_priv->wnmd_info->check_flip2) (crtc, window, pixmap, sync_flip, reason)) {
--
2.28.0

View File

@ -1,7 +1,7 @@
From 575c8b49a715d45115625643b8495ad786961e38 Mon Sep 17 00:00:00 2001
From 4bc5480d2e63cceecdc18b4bfda4fb4624f8fb43 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Thu, 29 Aug 2019 23:04:36 +0200
Subject: [PATCH xserver 07/24] xwayland: Add support for storing per client
Subject: [PATCH xserver 07/25] xwayland: Add support for storing per client
per output emulated resolution
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -145,5 +145,5 @@ index 19626d394..c886d77e9 100644
float VRefresh, Bool Reduced, Bool Interlaced);
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 1317f1f02fd0037e2bf7a678f2c3a9a4170161e9 Mon Sep 17 00:00:00 2001
From 2f2a6b8556bd104740d76126640abcfe4705047c Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Tue, 2 Jul 2019 11:55:26 +0200
Subject: [PATCH xserver 08/24] xwayland: Add support for randr-resolution
Subject: [PATCH xserver 08/25] xwayland: Add support for randr-resolution
change emulation using viewport
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -143,7 +143,7 @@ index 64794dee7..e09d00108 100644
static Bool
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index e00dba334..9c6cf7cf5 100644
index f422cfc29..87870a5f1 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -178,6 +178,23 @@ xwl_screen_has_resolution_change_emulation(struct xwl_screen *xwl_screen)
@ -170,7 +170,7 @@ index e00dba334..9c6cf7cf5 100644
static void
xwl_window_set_allow_commits(struct xwl_window *xwl_window, Bool allow,
const char *debug_msg)
@@ -514,6 +531,150 @@ xwl_pixmap_get(PixmapPtr pixmap)
@@ -501,6 +518,150 @@ xwl_pixmap_get(PixmapPtr pixmap)
return dixLookupPrivate(&pixmap->devPrivates, &xwl_pixmap_private_key);
}
@ -321,7 +321,7 @@ index e00dba334..9c6cf7cf5 100644
static void
xwl_window_init_allow_commits(struct xwl_window *xwl_window)
{
@@ -584,6 +745,8 @@ ensure_surface_for_window(WindowPtr window)
@@ -571,6 +732,8 @@ ensure_surface_for_window(WindowPtr window)
xwl_window->xwl_screen = xwl_screen;
xwl_window->window = window;
@ -330,7 +330,7 @@ index e00dba334..9c6cf7cf5 100644
xwl_window->surface = wl_compositor_create_surface(xwl_screen->compositor);
if (xwl_window->surface == NULL) {
ErrorF("wl_display_create_surface failed\n");
@@ -625,6 +788,7 @@ ensure_surface_for_window(WindowPtr window)
@@ -612,6 +775,7 @@ ensure_surface_for_window(WindowPtr window)
dixSetPrivate(&window->devPrivates, &xwl_window_private_key, xwl_window);
xorg_list_init(&xwl_window->link_damage);
@ -338,7 +338,7 @@ index e00dba334..9c6cf7cf5 100644
#ifdef GLAMOR_HAS_GBM
xorg_list_init(&xwl_window->frame_callback_list);
@@ -718,8 +882,12 @@ xwl_unrealize_window(WindowPtr window)
@@ -705,8 +869,12 @@ xwl_unrealize_window(WindowPtr window)
if (!xwl_window)
return ret;
@ -351,7 +351,7 @@ index e00dba334..9c6cf7cf5 100644
unregister_damage(window);
if (xwl_window->frame_callback)
@@ -769,6 +937,33 @@ xwl_set_window_pixmap(WindowPtr window,
@@ -756,6 +924,33 @@ xwl_set_window_pixmap(WindowPtr window,
ensure_surface_for_window(window);
}
@ -385,7 +385,7 @@ index e00dba334..9c6cf7cf5 100644
static void
frame_callback(void *data,
struct wl_callback *callback,
@@ -1246,6 +1441,7 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
@@ -1233,6 +1428,7 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
xorg_list_init(&xwl_screen->output_list);
xorg_list_init(&xwl_screen->seat_list);
xorg_list_init(&xwl_screen->damage_window_list);
@ -393,7 +393,7 @@ index e00dba334..9c6cf7cf5 100644
xwl_screen->depth = 24;
if (!monitorResolution)
@@ -1340,6 +1536,9 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
@@ -1332,6 +1528,9 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
xwl_screen->CloseScreen = pScreen->CloseScreen;
pScreen->CloseScreen = xwl_close_screen;
@ -458,5 +458,5 @@ index c886d77e9..36c4c4c8b 100644
float VRefresh, Bool Reduced, Bool Interlaced);
--
2.26.2
2.28.0

View File

@ -1,45 +0,0 @@
From 51ee6e5ceb0cacc8e2fa225ad5391ffb159e36a0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Mon, 7 Sep 2020 18:39:17 +0200
Subject: [PATCH xserver 08/16] xwayland: Check window pixmap in
xwl_present_check_flip2
We can only flip if the window pixmap matches that of the toplevel
window. Doing so regardless could cause the toplevel window pixmap to
get destroyed while it was still referenced by the window, resulting in
use-after-free and likely a crash.
Closes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1033
Reviewed-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit 4c25356d6cd908c5030c70e712076dff318ac00d)
---
hw/xwayland/xwayland-present.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/hw/xwayland/xwayland-present.c b/hw/xwayland/xwayland-present.c
index 6076f6498..d177abdd8 100644
--- a/hw/xwayland/xwayland-present.c
+++ b/hw/xwayland/xwayland-present.c
@@ -421,10 +421,18 @@ xwl_present_check_flip2(RRCrtcPtr crtc,
PresentFlipReason *reason)
{
struct xwl_window *xwl_window = xwl_window_from_window(present_window);
+ ScreenPtr screen = pixmap->drawable.pScreen;
if (!xwl_window)
return FALSE;
+ /* Can't flip if the window pixmap doesn't match the xwl_window parent
+ * window's, e.g. because a client redirected this window or one of its
+ * parents.
+ */
+ if (screen->GetWindowPixmap(xwl_window->window) != screen->GetWindowPixmap(present_window))
+ return FALSE;
+
/*
* We currently only allow flips of windows, that have the same
* dimensions as their xwl_window parent window. For the case of
--
2.28.0

View File

@ -1,33 +0,0 @@
From 174cb91d82d643f78d8ba2b9999312b9d7dea98c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Mon, 7 Sep 2020 18:40:34 +0200
Subject: [PATCH xserver 09/16] present/wnmd: Remove dead check from
present_wnmd_check_flip
present_wnmd_toplvl_pixmap_window returns a window with the same window
pixmap, so the check could never fail.
Reviewed-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit b6b1161fd7ac409156fb69439897bcabdeacf393)
---
present/present_wnmd.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/present/present_wnmd.c b/present/present_wnmd.c
index 6a3d1035b..35ea12968 100644
--- a/present/present_wnmd.c
+++ b/present/present_wnmd.c
@@ -270,10 +270,6 @@ present_wnmd_check_flip(RRCrtcPtr crtc,
if (!screen_priv->wnmd_info->flip)
return FALSE;
- /* Can't flip redirected child windows */
- if (screen->GetWindowPixmap(window) != screen->GetWindowPixmap(toplvl_window))
- return FALSE;
-
/* Source pixmap must align with window exactly */
if (x_off || y_off)
return FALSE;
--
2.28.0

View File

@ -1,7 +1,7 @@
From 0efb1df3a2ef4bc2dd329af63e1bd3dbda3445e4 Mon Sep 17 00:00:00 2001
From aedd71a61ac2d78c347180e7d87e5918b795609e Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 8 Jul 2019 14:00:27 +0200
Subject: [PATCH xserver 09/24] xwayland: Add xwlRRModeToDisplayMode() helper
Subject: [PATCH xserver 09/25] xwayland: Add xwlRRModeToDisplayMode() helper
function
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -97,5 +97,5 @@ index d25d1aca1..428af716d 100644
return TRUE;
}
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From fdbc9904d5af48db56877369f8b4671985ffc363 Mon Sep 17 00:00:00 2001
From 719c1d2ef99784043883787d04afc0437f3a9b8f Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 8 Jul 2019 18:35:27 +0200
Subject: [PATCH xserver 10/24] xwayland: Add xwlVidModeGetCurrentRRMode helper
Subject: [PATCH xserver 10/25] xwayland: Add xwlVidModeGetCurrentRRMode helper
to the vidmode code
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -189,5 +189,5 @@ index 428af716d..7cf982fcc 100644
static void
--
2.26.2
2.28.0

View File

@ -1,73 +0,0 @@
From d108c2c82cba242ea5998d7c91254d90d3a5db71 Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Fri, 11 Sep 2020 11:30:18 +0200
Subject: [PATCH xserver 10/16] xwayland: Do not discard frame callbacks on
allow commits
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Currently, when a X11 client (usually the X11 window manager from a
Wayland compositor) changes the value of the X11 property
`_XWAYLAND_ALLOW_COMMITS` from `false` to `true`, all pending frame
callbacks on the window are discarded so that the commit occurs
immediately.
Weston uses that mechanism to prevent the content of the window from
showing before it's ready when mapping the window initially, but
discarding the pending frame callbacks has no effect on the initial
mapping of the X11 window since at that point there cannot be any frame
callback on a surface which hasn't been committed yet anyway.
However, discarding pending frame callbacks can be problematic if we
were to use the same `_XWAYLAND_ALLOW_COMMITS` mechanism to prevent
damages to be posted before the X11 toplevel is updated completely
(including the window decorations from the X11 window manager).
Remove the portion of code discarding the pending frame callback,
Xwayland should always wait for a pending frame callback if there's one
before posting new damages.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
https://gitlab.freedesktop.org/xorg/xserver/merge_requests/333
(cherry picked from commit 66da95a172c4941b75ffedcdaa0138c0a48f11fb)
---
hw/xwayland/xwayland.c | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index d02934cd5..a69188c0f 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -193,8 +193,6 @@ static void
xwl_window_property_allow_commits(struct xwl_window *xwl_window,
PropertyStateRec *propstate)
{
- Bool old_allow_commits = xwl_window->allow_commits;
-
switch (propstate->state) {
case PropertyNewValue:
xwl_window_set_allow_commits_from_property(xwl_window, propstate->prop);
@@ -207,17 +205,6 @@ xwl_window_property_allow_commits(struct xwl_window *xwl_window,
default:
break;
}
-
- /* If allow_commits turned from off to on, discard any frame
- * callback we might be waiting for so that a new buffer is posted
- * immediately through block_handler() if there is damage to post.
- */
- if (!old_allow_commits && xwl_window->allow_commits) {
- if (xwl_window->frame_callback) {
- wl_callback_destroy(xwl_window->frame_callback);
- xwl_window->frame_callback = NULL;
- }
- }
}
static void
--
2.28.0

View File

@ -1,7 +1,7 @@
From aa5920519dff3dc3dfb33af342e454627fa5402c Mon Sep 17 00:00:00 2001
From 98e6cadf2ba8490c303cdc94106baf3f31006299 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Tue, 9 Jul 2019 09:31:13 +0200
Subject: [PATCH xserver 11/24] xwayland: Add vidmode mode changing emulation
Subject: [PATCH xserver 11/25] xwayland: Add vidmode mode changing emulation
support
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -232,5 +232,5 @@ index 7cf982fcc..99a4d2c92 100644
static Bool
--
2.26.2
2.28.0

View File

@ -1,68 +0,0 @@
From 1ac389dda89b2882c80767c91bbe88e01818491c Mon Sep 17 00:00:00 2001
From: Greg V <greg@unrelenting.technology>
Date: Tue, 15 Sep 2020 17:41:04 +0300
Subject: [PATCH xserver 11/16] xwayland: use drmGetNodeTypeFromFd for checking
if a node is a render one
Major/minor numbers are a.. major (ha) source of pain in FreeBSD porting.
In this case, Xwayland was thinking that /dev/dri/card0 is already a render node,
because the st_rdev on FreeBSD was passing the Linux-style check,
and because of the assumption, acceleration would fail because
various ioctls like AMDGPU_INFO would be denied on the non-render node.
Switch to libdrm's function that already works correctly on all platforms.
Signed-off-by: Greg V <greg@unrelenting.technology>
Reviewed-by: Emmanuel Vadot <manu@FreeBSD.org>
(cherry picked from commit 239ebdc9e447d4f836d0c2aa6068c6064fffb46c)
---
hw/xwayland/xwayland-glamor-gbm.c | 19 ++-----------------
1 file changed, 2 insertions(+), 17 deletions(-)
diff --git a/hw/xwayland/xwayland-glamor-gbm.c b/hw/xwayland/xwayland-glamor-gbm.c
index ebff70a00..b519492cc 100644
--- a/hw/xwayland/xwayland-glamor-gbm.c
+++ b/hw/xwayland/xwayland-glamor-gbm.c
@@ -110,21 +110,6 @@ wl_drm_format_for_depth(int depth)
}
}
-static char
-is_fd_render_node(int fd)
-{
- struct stat render;
-
- if (fstat(fd, &render))
- return 0;
- if (!S_ISCHR(render.st_mode))
- return 0;
- if (render.st_rdev & 0x80)
- return 1;
-
- return 0;
-}
-
static char
is_device_path_render_node (const char *device_path)
{
@@ -135,7 +120,7 @@ is_device_path_render_node (const char *device_path)
if (fd < 0)
return 0;
- is_render_node = is_fd_render_node(fd);
+ is_render_node = (drmGetNodeTypeFromFd(fd) == DRM_NODE_RENDER);
close(fd);
return is_render_node;
@@ -767,7 +752,7 @@ xwl_drm_handle_device(void *data, struct wl_drm *drm, const char *device)
return;
}
- if (is_fd_render_node(xwl_gbm->drm_fd)) {
+ if (drmGetNodeTypeFromFd(xwl_gbm->drm_fd) == DRM_NODE_RENDER) {
xwl_gbm->fd_render_node = 1;
xwl_screen->expecting_event--;
} else {
--
2.28.0

View File

@ -1,43 +0,0 @@
From 1930ed233fdec5d22e4fc192769a0126faabb3ea Mon Sep 17 00:00:00 2001
From: Olivier Fourdan <ofourdan@redhat.com>
Date: Mon, 14 Sep 2020 15:39:10 +0200
Subject: [PATCH xserver 12/16] xwayland: Remove pending stream reference when
freeing
The EGLStream backend keeps a queue of pending streams for each Xwayland
window.
However, when this pending queue is freed, the corresponding private
data may not be cleared (typically if the pixmap for this window has
changed before the compositor finished attaching the consumer for the
window's pixmap's original eglstream), leading to a use-after-free and a
crash when trying to use that data as the window pixmap.
Make sure to clear the private data when the pending stream is freed.
Closes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1055
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Tested-by: Karol Szuster <karolsz9898@gmail.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
(cherry picked from commit a5f439dcd21b4fda093cb382bb1a758b434a1444)
---
hw/xwayland/xwayland-glamor-eglstream.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/xwayland/xwayland-glamor-eglstream.c b/hw/xwayland/xwayland-glamor-eglstream.c
index 36b749aaf..0c32fff4d 100644
--- a/hw/xwayland/xwayland-glamor-eglstream.c
+++ b/hw/xwayland/xwayland-glamor-eglstream.c
@@ -431,8 +431,8 @@ xwl_eglstream_consumer_ready_callback(void *data,
DebugF("eglstream: win %d completes eglstream for pixmap %p, congrats!\n",
pending->window->drawable.id, pending->pixmap);
- xwl_eglstream_window_set_pending(pending->window, NULL);
out:
+ xwl_eglstream_window_set_pending(pending->window, NULL);
xorg_list_del(&pending->link);
free(pending);
}
--
2.28.0

View File

@ -1,7 +1,7 @@
From a090b038c45732676d9b7e367848d5bee7ab0ea5 Mon Sep 17 00:00:00 2001
From 3d359d03573dee270b72f0cea1ea9061c2c886c3 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 26 Aug 2019 12:26:34 +0200
Subject: [PATCH xserver 12/24] xwayland: xwl_window_should_enable_viewport:
Subject: [PATCH xserver 12/25] xwayland: xwl_window_should_enable_viewport:
Add extra test
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -25,10 +25,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 17 insertions(+)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 9c6cf7cf5..2e01822fd 100644
index 87870a5f1..9175396f7 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -651,6 +651,23 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -638,6 +638,23 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
}
}
@ -53,5 +53,5 @@ index 9c6cf7cf5..2e01822fd 100644
}
--
2.26.2
2.28.0

View File

@ -1,121 +0,0 @@
From dae234efdb7bba75744aa1697386df3c0db5348a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Fri, 11 Sep 2020 17:00:18 +0200
Subject: [PATCH xserver 13/16] present: Move flip target_msc adjustment out of
present_vblank_create
Preparation for different handling between SCMD & WNMD. No functional
change intended.
Reviewed-by: Roman Gilg <subdiff@gmail.com>
Tested-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit 4c92dea952f7fed19857904f0f552900257ef4b9)
---
present/present_priv.h | 2 +-
present/present_scmd.c | 5 ++++-
present/present_vblank.c | 9 ++++-----
present/present_wnmd.c | 5 ++++-
4 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/present/present_priv.h b/present/present_priv.h
index 5849b9e0b..90c3f4e79 100644
--- a/present/present_priv.h
+++ b/present/present_priv.h
@@ -469,7 +469,7 @@ present_vblank_create(WindowPtr window,
const uint32_t *capabilities,
present_notify_ptr notifies,
int num_notifies,
- uint64_t *target_msc,
+ uint64_t target_msc,
uint64_t crtc_msc);
void
diff --git a/present/present_scmd.c b/present/present_scmd.c
index 6a580cb7a..a4d046ca8 100644
--- a/present/present_scmd.c
+++ b/present/present_scmd.c
@@ -745,12 +745,15 @@ present_scmd_pixmap(WindowPtr window,
screen_priv->info ? &screen_priv->info->capabilities : NULL,
notifies,
num_notifies,
- &target_msc,
+ target_msc,
crtc_msc);
if (!vblank)
return BadAlloc;
+ if (vblank->flip && vblank->sync_flip)
+ target_msc--;
+
xorg_list_append(&vblank->event_queue, &present_exec_queue);
vblank->queued = TRUE;
if (msc_is_after(target_msc, crtc_msc)) {
diff --git a/present/present_vblank.c b/present/present_vblank.c
index 2c124f4bb..a4b70c0d9 100644
--- a/present/present_vblank.c
+++ b/present/present_vblank.c
@@ -57,7 +57,7 @@ present_vblank_create(WindowPtr window,
const uint32_t *capabilities,
present_notify_ptr notifies,
int num_notifies,
- uint64_t *target_msc,
+ uint64_t target_msc,
uint64_t crtc_msc)
{
ScreenPtr screen = window->drawable.pScreen;
@@ -100,7 +100,7 @@ present_vblank_create(WindowPtr window,
vblank->x_off = x_off;
vblank->y_off = y_off;
- vblank->target_msc = *target_msc;
+ vblank->target_msc = target_msc;
vblank->crtc = target_crtc;
vblank->msc_offset = window_priv->msc_offset;
vblank->notifies = notifies;
@@ -111,12 +111,11 @@ present_vblank_create(WindowPtr window,
if (pixmap != NULL &&
!(options & PresentOptionCopy) &&
capabilities) {
- if (msc_is_after(*target_msc, crtc_msc) &&
+ if (msc_is_after(target_msc, crtc_msc) &&
screen_priv->check_flip (target_crtc, window, pixmap, TRUE, valid, x_off, y_off, &reason))
{
vblank->flip = TRUE;
vblank->sync_flip = TRUE;
- *target_msc = *target_msc - 1;
} else if ((*capabilities & PresentCapabilityAsync) &&
screen_priv->check_flip (target_crtc, window, pixmap, FALSE, valid, x_off, y_off, &reason))
{
@@ -139,7 +138,7 @@ present_vblank_create(WindowPtr window,
if (pixmap)
DebugPresent(("q %" PRIu64 " %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 " (crtc %p) flip %d vsync %d serial %d\n",
- vblank->event_id, vblank, *target_msc,
+ vblank->event_id, vblank, target_msc,
vblank->pixmap->drawable.id, vblank->window->drawable.id,
target_crtc, vblank->flip, vblank->sync_flip, vblank->serial));
return vblank;
diff --git a/present/present_wnmd.c b/present/present_wnmd.c
index 35ea12968..31e83d6ee 100644
--- a/present/present_wnmd.c
+++ b/present/present_wnmd.c
@@ -626,11 +626,14 @@ present_wnmd_pixmap(WindowPtr window,
&screen_priv->wnmd_info->capabilities,
notifies,
num_notifies,
- &target_msc,
+ target_msc,
crtc_msc);
if (!vblank)
return BadAlloc;
+ if (vblank->flip && vblank->sync_flip)
+ target_msc--;
+
xorg_list_append(&vblank->event_queue, &window_priv->exec_queue);
vblank->queued = TRUE;
if (crtc_msc < target_msc) {
--
2.28.0

View File

@ -1,7 +1,7 @@
From e40d94637207543481769fb570515b782225ff09 Mon Sep 17 00:00:00 2001
From 48bc25613f91b69d9ee68e8211f8bf22317aa40a Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 2 Sep 2019 17:32:45 +0200
Subject: [PATCH xserver 13/24] xwayland: Set _XWAYLAND_RANDR_EMU_MONITOR_RECTS
Subject: [PATCH xserver 13/25] xwayland: Set _XWAYLAND_RANDR_EMU_MONITOR_RECTS
property for resolution emulation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -139,10 +139,10 @@ index e09d00108..0d6b9ac9f 100644
static void
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 2e01822fd..ac4d98e6a 100644
index 9175396f7..32442d88e 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -692,6 +692,27 @@ xwl_screen_check_resolution_change_emulation(struct xwl_screen *xwl_screen)
@@ -679,6 +679,27 @@ xwl_screen_check_resolution_change_emulation(struct xwl_screen *xwl_screen)
xwl_window_check_resolution_change_emulation(xwl_window);
}
@ -170,7 +170,7 @@ index 2e01822fd..ac4d98e6a 100644
static void
xwl_window_init_allow_commits(struct xwl_window *xwl_window)
{
@@ -857,6 +878,8 @@ xwl_realize_window(WindowPtr window)
@@ -844,6 +865,8 @@ xwl_realize_window(WindowPtr window)
return FALSE;
}
@ -201,5 +201,5 @@ index 36c4c4c8b..1317ae5bb 100644
RRModePtr xwayland_cvt(int HDisplay, int VDisplay,
float VRefresh, Bool Reduced, Bool Interlaced);
--
2.26.2
2.28.0

View File

@ -1,236 +0,0 @@
From 669e40390c3679b649db33f0aa4ae4cfdd17e2a9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Fri, 11 Sep 2020 17:00:35 +0200
Subject: [PATCH xserver 14/16] present: Add present_vblank::exec_msc field
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
For tracking the MSC when the present can be executed separately from
the target MSC.
Allows removing the requeue field instead, plus more later.
v2:
* Rename wait_msc → exec_msc (Roman Gilg)
* Use exec_msc = target_msc instead of exec_msc++, for clarity.
* Bug fix: Set exec_msc = target_msc also if present_flip returned
false in present_execute.
v3:
* Set exec_msc = target_msc also if present_wnmd_flip returned
false in present_wnmd_execute, for consistency.
v4:
* Specifically check for exec_msc == crtc_msc + 1 in
present_execute_wait/copy, to avoid re-introducing
https://bugs.freedesktop.org/show_bug.cgi?id=94596 .
Reviewed-by: Roman Gilg <subdiff@gmail.com>
Tested-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit b0b3159abd8001fa3f6dfc44a288a95a62aa5cf6)
---
present/present_execute.c | 23 ++++++++++-------------
present/present_priv.h | 4 ++--
present/present_scmd.c | 13 +++++++------
present/present_vblank.c | 9 +++++----
present/present_wnmd.c | 13 +++++++------
5 files changed, 31 insertions(+), 31 deletions(-)
diff --git a/present/present_execute.c b/present/present_execute.c
index 8d1ef4a8c..58066db86 100644
--- a/present/present_execute.c
+++ b/present/present_execute.c
@@ -48,16 +48,13 @@ present_execute_wait(present_vblank_ptr vblank, uint64_t crtc_msc)
ScreenPtr screen = window->drawable.pScreen;
present_screen_priv_ptr screen_priv = present_screen_priv(screen);
- if (vblank->requeue) {
- vblank->requeue = FALSE;
- if (msc_is_after(vblank->target_msc, crtc_msc) &&
- Success == screen_priv->queue_vblank(screen,
- window,
- vblank->crtc,
- vblank->event_id,
- vblank->target_msc))
- return TRUE;
- }
+ /* We may have to requeue for the next MSC if check_flip_window prevented
+ * using a flip.
+ */
+ if (vblank->exec_msc == crtc_msc + 1 &&
+ screen_priv->queue_vblank(screen, window, vblank->crtc, vblank->event_id,
+ vblank->exec_msc) == Success)
+ return TRUE;
if (vblank->wait_fence) {
if (!present_fence_check_triggered(vblank->wait_fence)) {
@@ -75,13 +72,13 @@ present_execute_copy(present_vblank_ptr vblank, uint64_t crtc_msc)
ScreenPtr screen = window->drawable.pScreen;
present_screen_priv_ptr screen_priv = present_screen_priv(screen);
- /* If present_flip failed, we may have to requeue for the target MSC */
- if (vblank->target_msc == crtc_msc + 1 &&
+ /* If present_flip failed, we may have to requeue for the next MSC */
+ if (vblank->exec_msc == crtc_msc + 1 &&
Success == screen_priv->queue_vblank(screen,
window,
vblank->crtc,
vblank->event_id,
- vblank->target_msc)) {
+ vblank->exec_msc)) {
vblank->queued = TRUE;
return;
}
diff --git a/present/present_priv.h b/present/present_priv.h
index 90c3f4e79..f34edd5cf 100644
--- a/present/present_priv.h
+++ b/present/present_priv.h
@@ -70,14 +70,14 @@ struct present_vblank {
int16_t y_off;
CARD16 kind;
uint64_t event_id;
- uint64_t target_msc;
+ uint64_t target_msc; /* target MSC when present should complete */
+ uint64_t exec_msc; /* MSC at which present can be executed */
uint64_t msc_offset;
present_fence_ptr idle_fence;
present_fence_ptr wait_fence;
present_notify_ptr notifies;
int num_notifies;
Bool queued; /* on present_exec_queue */
- Bool requeue; /* on queue, but target_msc has changed */
Bool flip; /* planning on using flip */
Bool flip_ready; /* wants to flip, but waiting for previous flip or unflip */
Bool flip_idler; /* driver explicitly permitted idling */
diff --git a/present/present_scmd.c b/present/present_scmd.c
index a4d046ca8..3e3ae3477 100644
--- a/present/present_scmd.c
+++ b/present/present_scmd.c
@@ -361,8 +361,8 @@ present_flip_notify(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
ScreenPtr screen = vblank->screen;
present_screen_priv_ptr screen_priv = present_screen_priv(screen);
- DebugPresent(("\tn %" PRIu64 " %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
- vblank->event_id, vblank, vblank->target_msc,
+ DebugPresent(("\tn %" PRIu64 " %p %" PRIu64 " %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
+ vblank->event_id, vblank, vblank->exec_msc, vblank->target_msc,
vblank->pixmap ? vblank->pixmap->drawable.id : 0,
vblank->window ? vblank->window->drawable.id : 0));
@@ -482,7 +482,7 @@ present_check_flip_window (WindowPtr window)
vblank->flip = FALSE;
vblank->reason = reason;
if (vblank->sync_flip)
- vblank->requeue = TRUE;
+ vblank->exec_msc = vblank->target_msc;
}
}
}
@@ -608,6 +608,7 @@ present_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
*/
screen_priv->flip_pending = NULL;
vblank->flip = FALSE;
+ vblank->exec_msc = vblank->target_msc;
}
DebugPresent(("\tc %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
vblank, crtc_msc, vblank->pixmap->drawable.id, vblank->window->drawable.id));
@@ -752,12 +753,12 @@ present_scmd_pixmap(WindowPtr window,
return BadAlloc;
if (vblank->flip && vblank->sync_flip)
- target_msc--;
+ vblank->exec_msc--;
xorg_list_append(&vblank->event_queue, &present_exec_queue);
vblank->queued = TRUE;
- if (msc_is_after(target_msc, crtc_msc)) {
- ret = present_queue_vblank(screen, window, target_crtc, vblank->event_id, target_msc);
+ if (msc_is_after(vblank->exec_msc, crtc_msc)) {
+ ret = present_queue_vblank(screen, window, target_crtc, vblank->event_id, vblank->exec_msc);
if (ret == Success)
return Success;
diff --git a/present/present_vblank.c b/present/present_vblank.c
index a4b70c0d9..af14fe134 100644
--- a/present/present_vblank.c
+++ b/present/present_vblank.c
@@ -101,6 +101,7 @@ present_vblank_create(WindowPtr window,
vblank->x_off = x_off;
vblank->y_off = y_off;
vblank->target_msc = target_msc;
+ vblank->exec_msc = target_msc;
vblank->crtc = target_crtc;
vblank->msc_offset = window_priv->msc_offset;
vblank->notifies = notifies;
@@ -152,8 +153,8 @@ no_mem:
void
present_vblank_scrap(present_vblank_ptr vblank)
{
- DebugPresent(("\tx %" PRIu64 " %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 " (crtc %p)\n",
- vblank->event_id, vblank, vblank->target_msc,
+ DebugPresent(("\tx %" PRIu64 " %p %" PRIu64 " %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 " (crtc %p)\n",
+ vblank->event_id, vblank, vblank->exec_msc, vblank->target_msc,
vblank->pixmap->drawable.id, vblank->window->drawable.id,
vblank->crtc));
@@ -174,8 +175,8 @@ present_vblank_destroy(present_vblank_ptr vblank)
/* Also make sure vblank is removed from event queue (wnmd) */
xorg_list_del(&vblank->event_queue);
- DebugPresent(("\td %" PRIu64 " %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
- vblank->event_id, vblank, vblank->target_msc,
+ DebugPresent(("\td %" PRIu64 " %p %" PRIu64 " %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
+ vblank->event_id, vblank, vblank->exec_msc, vblank->target_msc,
vblank->pixmap ? vblank->pixmap->drawable.id : 0,
vblank->window ? vblank->window->drawable.id : 0));
diff --git a/present/present_wnmd.c b/present/present_wnmd.c
index 31e83d6ee..339e93edb 100644
--- a/present/present_wnmd.c
+++ b/present/present_wnmd.c
@@ -168,8 +168,8 @@ present_wnmd_flip_notify(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_
WindowPtr window = vblank->window;
present_window_priv_ptr window_priv = present_window_priv(window);
- DebugPresent(("\tn %" PRIu64 " %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
- vblank->event_id, vblank, vblank->target_msc,
+ DebugPresent(("\tn %" PRIu64 " %p %" PRIu64 " %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
+ vblank->event_id, vblank, vblank->exec_msc, vblank->target_msc,
vblank->pixmap ? vblank->pixmap->drawable.id : 0,
vblank->window ? vblank->window->drawable.id : 0));
@@ -343,7 +343,7 @@ present_wnmd_check_flip_window (WindowPtr window)
vblank->flip = FALSE;
vblank->reason = reason;
if (vblank->sync_flip)
- vblank->requeue = TRUE;
+ vblank->exec_msc = vblank->target_msc;
}
}
}
@@ -491,6 +491,7 @@ present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
*/
window_priv->flip_pending = NULL;
vblank->flip = FALSE;
+ vblank->exec_msc = vblank->target_msc;
}
DebugPresent(("\tc %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
vblank, crtc_msc, vblank->pixmap->drawable.id, vblank->window->drawable.id));
@@ -632,12 +633,12 @@ present_wnmd_pixmap(WindowPtr window,
return BadAlloc;
if (vblank->flip && vblank->sync_flip)
- target_msc--;
+ vblank->exec_msc--;
xorg_list_append(&vblank->event_queue, &window_priv->exec_queue);
vblank->queued = TRUE;
- if (crtc_msc < target_msc) {
- if (present_wnmd_queue_vblank(screen, window, target_crtc, vblank->event_id, target_msc) == Success) {
+ if (crtc_msc < vblank->exec_msc) {
+ if (present_wnmd_queue_vblank(screen, window, target_crtc, vblank->event_id, vblank->exec_msc) == Success) {
return Success;
}
DebugPresent(("present_queue_vblank failed\n"));
--
2.28.0

View File

@ -1,7 +1,7 @@
From a35e6f9a2b15a446138f6f3e201a19833a5a2454 Mon Sep 17 00:00:00 2001
From 12a0f852e3276cb5c60e44b8b0d6ddd97975fd42 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 27 Jan 2020 11:08:00 +0100
Subject: [PATCH xserver 14/24] xwayland: Cache client-id for the
Subject: [PATCH xserver 14/25] xwayland: Cache client-id for the
window-manager client
Instead of iterating over all clients which are listening for events on the
@ -24,10 +24,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2 files changed, 34 insertions(+), 16 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index ac4d98e6a..c16da330c 100644
index 32442d88e..f99cdf81f 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -578,20 +578,11 @@ xwl_window_enable_viewport(struct xwl_window *xwl_window,
@@ -565,20 +565,11 @@ xwl_window_enable_viewport(struct xwl_window *xwl_window,
}
static Bool
@ -51,7 +51,7 @@ index ac4d98e6a..c16da330c 100644
}
static ClientPtr
@@ -605,7 +596,7 @@ xwl_window_get_owner(struct xwl_window *xwl_window)
@@ -592,7 +583,7 @@ xwl_window_get_owner(struct xwl_window *xwl_window)
* decoration window. In that case return the client of the
* first *and only* child of the toplevel (decoration) window.
*/
@ -60,7 +60,7 @@ index ac4d98e6a..c16da330c 100644
if (window->firstChild && window->firstChild == window->lastChild)
return wClient(window->firstChild);
else
@@ -700,9 +691,7 @@ xwl_screen_check_resolution_change_emulation(struct xwl_screen *xwl_screen)
@@ -687,9 +678,7 @@ xwl_screen_check_resolution_change_emulation(struct xwl_screen *xwl_screen)
Bool
xwl_window_is_toplevel(WindowPtr window)
{
@ -71,7 +71,7 @@ index ac4d98e6a..c16da330c 100644
return FALSE;
/* CSD and override-redirect toplevel windows */
@@ -977,6 +966,30 @@ xwl_set_window_pixmap(WindowPtr window,
@@ -964,6 +953,30 @@ xwl_set_window_pixmap(WindowPtr window,
ensure_surface_for_window(window);
}
@ -102,7 +102,7 @@ index ac4d98e6a..c16da330c 100644
static void
xwl_resize_window(WindowPtr window,
int x, int y,
@@ -1576,6 +1589,9 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
@@ -1568,6 +1581,9 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
xwl_screen->CloseScreen = pScreen->CloseScreen;
pScreen->CloseScreen = xwl_close_screen;
@ -133,5 +133,5 @@ index 1317ae5bb..f5ffadfcc 100644
struct xorg_list output_list;
--
2.26.2
2.28.0

View File

@ -1,58 +0,0 @@
From 96ef31e0f20fcffb2edfe4cb9510f994c188785f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Tue, 28 Jul 2020 18:53:45 +0200
Subject: [PATCH xserver 15/16] present/wnmd: Move up present_wnmd_queue_vblank
Allowing it to be called from more functions than before. No functional
change.
Reviewed-by: Roman Gilg <subdiff@gmail.com>
Tested-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit d14ea667feccf085c7d66a7c63f380975e07af66)
---
present/present_wnmd.c | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/present/present_wnmd.c b/present/present_wnmd.c
index 339e93edb..2c11e53f5 100644
--- a/present/present_wnmd.c
+++ b/present/present_wnmd.c
@@ -42,6 +42,17 @@
static void
present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc);
+static int
+present_wnmd_queue_vblank(ScreenPtr screen,
+ WindowPtr window,
+ RRCrtcPtr crtc,
+ uint64_t event_id,
+ uint64_t msc)
+{
+ present_screen_priv_ptr screen_priv = present_screen_priv(screen);
+ return (*screen_priv->wnmd_info->queue_vblank) (window, crtc, event_id, msc);
+}
+
static void
present_wnmd_create_event_id(present_window_priv_ptr window_priv, present_vblank_ptr vblank)
{
@@ -511,17 +522,6 @@ present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
present_execute_post(vblank, ust, crtc_msc);
}
-static int
-present_wnmd_queue_vblank(ScreenPtr screen,
- WindowPtr window,
- RRCrtcPtr crtc,
- uint64_t event_id,
- uint64_t msc)
-{
- present_screen_priv_ptr screen_priv = present_screen_priv(screen);
- return (*screen_priv->wnmd_info->queue_vblank) (window, crtc, event_id, msc);
-}
-
static uint64_t
present_wnmd_window_to_crtc_msc(WindowPtr window, RRCrtcPtr crtc, uint64_t window_msc, uint64_t new_msc)
{
--
2.28.0

View File

@ -1,7 +1,7 @@
From e4d8f7770e27ed56e23e0ef2a87bed8cb4fa28e0 Mon Sep 17 00:00:00 2001
From 5448ffeb9b06d20e821174c04d2280933e3ca993 Mon Sep 17 00:00:00 2001
From: Roman Gilg <subdiff@gmail.com>
Date: Fri, 3 Jan 2020 17:12:14 +0100
Subject: [PATCH xserver 15/24] xwayland: Reuse viewport instead of recreating
Subject: [PATCH xserver 15/25] xwayland: Reuse viewport instead of recreating
When a viewport is already created we can reuse this object instead of
destroying it and getting a new one for updating the source rectangle and
@ -17,10 +17,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 7 insertions(+), 11 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index c16da330c..ac301ae4a 100644
index f99cdf81f..8de3dd36b 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -552,17 +552,13 @@ xwl_window_enable_viewport(struct xwl_window *xwl_window,
@@ -539,17 +539,13 @@ xwl_window_enable_viewport(struct xwl_window *xwl_window,
struct xwl_output *xwl_output,
struct xwl_emulated_mode *emulated_mode)
{
@ -46,5 +46,5 @@ index c16da330c..ac301ae4a 100644
wp_viewport_set_source(xwl_window->viewport,
wl_fixed_from_int(0),
--
2.26.2
2.28.0

View File

@ -1,139 +0,0 @@
From c3e4c1a0fd5d4d6015e9e6317b758018317e56d1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Tue, 28 Jul 2020 18:40:47 +0200
Subject: [PATCH xserver 16/16] present/wnmd: Execute copies at target_msc-1
already
It always takes one update cycle for the copy to become visible on the
host windowing system, so waiting for the target MSC resulted in 1 cycle
delay.
We re-use the idle list for copies which were executed but need their
completion event sent.
Fixes black seams when resizing the "Builder" sub-window of
GDK_BACKEND=x11 gtk4-demo
on Xwayland (see
https://gitlab.gnome.org/GNOME/mutter/-/issues/1290#note_873557).
Unfortunately, this cannot completely fix the seams with apps which
queue up multiple frames in advance, since there's always at least one
queued frame corresponding to the old window size. But it should at
least help a little in that case as well.
v2:
* Bug fix: Don't update exec_msc in present_wnmd_check_flip_window.
(Roman Gilg)
* Use exec_msc = target_msc - 1 instead of exec_msc--, and add a
comment, for clarity.
v3:
* Drop exec_msc = target_msc again in present_wnmd_execute.
* present_execute_copy should never set vblank->queued in
present_wnmd_execute now, so replace that branch with an assertion.
(Roman Gilg)
Reviewed-by: Roman Gilg <subdiff@gmail.com>
Tested-by: Roman Gilg <subdiff@gmail.com>
(cherry picked from commit 1cccb486d48a5d2e7649836b993805bb65dc09e3)
[Since present_wnmd_event_notify hasn't been split up on the 1.20
branch, it needs to check vblank->flip. Doing the same in
present_wnmd_free_idle_vblanks to be safe, though I'm not sure it's
actually possible to hit non-flips there.]
---
present/present_wnmd.c | 28 ++++++++++++++++++----------
1 file changed, 18 insertions(+), 10 deletions(-)
diff --git a/present/present_wnmd.c b/present/present_wnmd.c
index 2c11e53f5..8c31619a2 100644
--- a/present/present_wnmd.c
+++ b/present/present_wnmd.c
@@ -122,7 +122,8 @@ present_wnmd_free_idle_vblanks(WindowPtr window)
present_vblank_ptr vblank, tmp;
xorg_list_for_each_entry_safe(vblank, tmp, &window_priv->idle_queue, event_queue) {
- present_wnmd_free_idle_vblank(vblank);
+ if (vblank->flip)
+ present_wnmd_free_idle_vblank(vblank);
}
if (window_priv->flip_active) {
@@ -245,7 +246,12 @@ present_wnmd_event_notify(WindowPtr window, uint64_t event_id, uint64_t ust, uin
xorg_list_for_each_entry(vblank, &window_priv->idle_queue, event_queue) {
if (vblank->event_id == event_id) {
- present_wnmd_free_idle_vblank(vblank);
+ if (vblank->flip)
+ present_wnmd_free_idle_vblank(vblank);
+ else
+ /* Copies which were executed but need their completion event sent */
+ present_execute_post(vblank, ust, msc);
+
return;
}
}
@@ -353,8 +359,6 @@ present_wnmd_check_flip_window (WindowPtr window)
vblank->sync_flip, vblank->valid, 0, 0, &reason)) {
vblank->flip = FALSE;
vblank->reason = reason;
- if (vblank->sync_flip)
- vblank->exec_msc = vblank->target_msc;
}
}
}
@@ -454,6 +458,7 @@ present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
vblank->queued = FALSE;
if (vblank->pixmap && vblank->window) {
+ ScreenPtr screen = window->drawable.pScreen;
if (vblank->flip) {
RegionPtr damage;
@@ -479,7 +484,6 @@ present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
// ask the driver
if (present_wnmd_flip(vblank->window, vblank->crtc, vblank->event_id,
vblank->target_msc, vblank->pixmap, vblank->sync_flip, damage)) {
- ScreenPtr screen = window->drawable.pScreen;
WindowPtr toplvl_window = present_wnmd_toplvl_pixmap_window(vblank->window);
PixmapPtr old_pixmap = screen->GetWindowPixmap(window);
@@ -502,7 +506,6 @@ present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
*/
window_priv->flip_pending = NULL;
vblank->flip = FALSE;
- vblank->exec_msc = vblank->target_msc;
}
DebugPresent(("\tc %p %" PRIu64 ": %08" PRIx32 " -> %08" PRIx32 "\n",
vblank, crtc_msc, vblank->pixmap->drawable.id, vblank->window->drawable.id));
@@ -510,9 +513,12 @@ present_wnmd_execute(present_vblank_ptr vblank, uint64_t ust, uint64_t crtc_msc)
present_wnmd_cancel_flip(window);
present_execute_copy(vblank, crtc_msc);
+ assert(!vblank->queued);
- if (vblank->queued) {
- xorg_list_add(&vblank->event_queue, &window_priv->exec_queue);
+ if (present_wnmd_queue_vblank(screen, window, vblank->crtc,
+ vblank->event_id, crtc_msc + 1)
+ == Success) {
+ xorg_list_add(&vblank->event_queue, &window_priv->idle_queue);
xorg_list_append(&vblank->window_list, &window_priv->vblank);
return;
@@ -632,8 +638,10 @@ present_wnmd_pixmap(WindowPtr window,
if (!vblank)
return BadAlloc;
- if (vblank->flip && vblank->sync_flip)
- vblank->exec_msc--;
+ /* WNMD presentations always complete (at least) one frame after they
+ * are executed
+ */
+ vblank->exec_msc = vblank->target_msc - 1;
xorg_list_append(&vblank->event_queue, &window_priv->exec_queue);
vblank->queued = TRUE;
--
2.28.0

View File

@ -1,7 +1,7 @@
From 66a026eeaa49e1042d4d2ec655e78771e1acd9df Mon Sep 17 00:00:00 2001
From 2896f732af4c74f124d767808a24005342d8f125 Mon Sep 17 00:00:00 2001
From: Roman Gilg <subdiff@gmail.com>
Date: Fri, 3 Jan 2020 17:27:28 +0100
Subject: [PATCH xserver 16/24] xwayland: Recurse on finding the none-wm owner
Subject: [PATCH xserver 16/25] xwayland: Recurse on finding the none-wm owner
An X11 window manager might add a chain of parent windows when reparenting to a
decoration window.
@ -28,10 +28,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index ac301ae4a..94e3a18fa 100644
index 8de3dd36b..c38c4180b 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -582,19 +582,18 @@ window_is_wm_window(WindowPtr window)
@@ -569,19 +569,18 @@ window_is_wm_window(WindowPtr window)
}
static ClientPtr
@ -56,7 +56,7 @@ index ac301ae4a..94e3a18fa 100644
else
return NULL; /* Should never happen, skip resolution emulation */
}
@@ -615,7 +614,7 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -602,7 +601,7 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
if (!xwl_screen_has_resolution_change_emulation(xwl_screen))
return FALSE;
@ -65,7 +65,7 @@ index ac301ae4a..94e3a18fa 100644
if (!owner)
return FALSE;
@@ -694,8 +693,8 @@ xwl_window_is_toplevel(WindowPtr window)
@@ -681,8 +680,8 @@ xwl_window_is_toplevel(WindowPtr window)
if (window_get_damage(window))
return TRUE;
@ -77,5 +77,5 @@ index ac301ae4a..94e3a18fa 100644
static void
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 8b9a66212bacd780f1a8ac37cbb490b650843c28 Mon Sep 17 00:00:00 2001
From dd83985179b4a3c2613c96922eafeea40e21b7d2 Mon Sep 17 00:00:00 2001
From: Roman Gilg <subdiff@gmail.com>
Date: Wed, 15 Jan 2020 10:07:58 +0100
Subject: [PATCH xserver 17/24] xwayland: Make window_get_none_wm_owner return
Subject: [PATCH xserver 17/25] xwayland: Make window_get_none_wm_owner return
a Window instead of a Client
Make window_get_none_wm_owner return the first non-wm-window instead of the
@ -25,10 +25,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 94e3a18fa..c60a2ce67 100644
index c38c4180b..b3b80beae 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -581,10 +581,10 @@ window_is_wm_window(WindowPtr window)
@@ -568,10 +568,10 @@ window_is_wm_window(WindowPtr window)
return CLIENT_ID(window->drawable.id) == xwl_screen->wm_client_id;
}
@ -42,7 +42,7 @@ index 94e3a18fa..c60a2ce67 100644
/* If the toplevel window is owned by the window-manager, then the
* actual client toplevel window has been reparented to some window-manager
@@ -593,12 +593,12 @@ window_get_none_wm_owner(WindowPtr window)
@@ -580,12 +580,12 @@ window_get_none_wm_owner(WindowPtr window)
*/
if (window_is_wm_window(window)) {
if (window->firstChild && window->firstChild == window->lastChild)
@ -57,7 +57,7 @@ index 94e3a18fa..c60a2ce67 100644
}
static Bool
@@ -610,14 +610,17 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -597,14 +597,17 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
struct xwl_emulated_mode *emulated_mode;
struct xwl_output *xwl_output;
ClientPtr owner;
@ -78,5 +78,5 @@ index 94e3a18fa..c60a2ce67 100644
* This path gets hit by most games / libs (e.g. SDL, SFML, OGRE)
*/
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From da3e06f4bed7fa60838ce89a0b45ea73c7d9615c Mon Sep 17 00:00:00 2001
From be8c65e84dc4bee97bd0115a89c037fb47053d4c Mon Sep 17 00:00:00 2001
From: Roman Gilg <subdiff@gmail.com>
Date: Fri, 3 Jan 2020 17:55:28 +0100
Subject: [PATCH xserver 18/24] xwayland: Check emulation on client toplevel
Subject: [PATCH xserver 18/25] xwayland: Check emulation on client toplevel
resize
When a reparented window is resized directly check the emulation instead of
@ -25,10 +25,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2 files changed, 11 insertions(+), 17 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index c60a2ce67..898a291fd 100644
index b3b80beae..b2e46336c 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -611,6 +611,7 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -598,6 +598,7 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
struct xwl_output *xwl_output;
ClientPtr owner;
WindowPtr window;
@ -36,7 +36,7 @@ index c60a2ce67..898a291fd 100644
if (!xwl_screen_has_resolution_change_emulation(xwl_screen))
return FALSE;
@@ -620,6 +621,7 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -607,6 +608,7 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
return FALSE;
owner = wClient(window);
@ -44,7 +44,7 @@ index c60a2ce67..898a291fd 100644
/* 1. Test if the window matches the emulated mode on one of the outputs
* This path gets hit by most games / libs (e.g. SDL, SFML, OGRE)
@@ -629,10 +631,10 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -616,10 +618,10 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
if (!emulated_mode)
continue;
@ -59,7 +59,7 @@ index c60a2ce67..898a291fd 100644
*emulated_mode_ret = emulated_mode;
*xwl_output_ret = xwl_output;
@@ -648,9 +650,9 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
@@ -635,9 +637,9 @@ xwl_window_should_enable_viewport(struct xwl_window *xwl_window,
emulated_mode = xwl_output_get_emulated_mode_for_client(xwl_output, owner);
if (xwl_output && xwl_window->window->overrideRedirect &&
emulated_mode && emulated_mode->from_vidmode &&
@ -72,7 +72,7 @@ index c60a2ce67..898a291fd 100644
*emulated_mode_ret = emulated_mode;
*xwl_output_ret = xwl_output;
@@ -770,8 +772,6 @@ ensure_surface_for_window(WindowPtr window)
@@ -757,8 +759,6 @@ ensure_surface_for_window(WindowPtr window)
xwl_window->xwl_screen = xwl_screen;
xwl_window->window = window;
@ -81,7 +81,7 @@ index c60a2ce67..898a291fd 100644
xwl_window->surface = wl_compositor_create_surface(xwl_screen->compositor);
if (xwl_window->surface == NULL) {
ErrorF("wl_display_create_surface failed\n");
@@ -999,20 +999,15 @@ xwl_resize_window(WindowPtr window,
@@ -986,20 +986,15 @@ xwl_resize_window(WindowPtr window,
struct xwl_window *xwl_window;
xwl_screen = xwl_screen_get(screen);
@ -117,5 +117,5 @@ index f5ffadfcc..0d0baac9b 100644
struct wl_shell_surface *shell_surface;
WindowPtr window;
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 09eb525863ab6c08fd743a637f7da9d10c0c01eb Mon Sep 17 00:00:00 2001
From 555e00dbf71d7c5b792bacd789cdde9c42203ff1 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Wed, 15 Jan 2020 14:36:45 +0100
Subject: [PATCH xserver 19/24] xwayland: Also check
Subject: [PATCH xserver 19/25] xwayland: Also check
resolution-change-emulation when the xwl_window itself moves
The recent change to use the top-level non-window-manager Window drawable
@ -28,10 +28,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 898a291fd..b40502dad 100644
index b2e46336c..e07dabcfa 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -1006,7 +1006,7 @@ xwl_resize_window(WindowPtr window,
@@ -993,7 +993,7 @@ xwl_resize_window(WindowPtr window,
xwl_screen->ResizeWindow = screen->ResizeWindow;
screen->ResizeWindow = xwl_resize_window;
@ -41,5 +41,5 @@ index 898a291fd..b40502dad 100644
}
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 9f2ebb5f07dc3fff8e061b21fa175d3d958d0ee4 Mon Sep 17 00:00:00 2001
From 46ccf740dc5e81d84b2e8c19f6211eaf1d8d06de Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Thu, 9 Jan 2020 11:00:36 +0100
Subject: [PATCH xserver 20/24] xwayland: Also hook screen's MoveWindow method
Subject: [PATCH xserver 20/25] xwayland: Also hook screen's MoveWindow method
Not only hook the ResizeWindow method of the screen (which really is
MoveAndResize) but also hook the MoveWindow method for checking if we
@ -24,10 +24,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2 files changed, 26 insertions(+)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index b40502dad..7111e20ae 100644
index e07dabcfa..4f19f3710 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -1010,6 +1010,28 @@ xwl_resize_window(WindowPtr window,
@@ -997,6 +997,28 @@ xwl_resize_window(WindowPtr window,
xwl_window_check_resolution_change_emulation(xwl_window);
}
@ -56,7 +56,7 @@ index b40502dad..7111e20ae 100644
static void
frame_callback(void *data,
struct wl_callback *callback,
@@ -1588,6 +1610,9 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
@@ -1580,6 +1602,9 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
xwl_screen->ResizeWindow = pScreen->ResizeWindow;
pScreen->ResizeWindow = xwl_resize_window;
@ -79,5 +79,5 @@ index 0d0baac9b..451c08e23 100644
struct xorg_list output_list;
struct xorg_list seat_list;
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 958b34ce3cab02219457d5dcc25217e7c9a0beba Mon Sep 17 00:00:00 2001
From d64f12d119e4abe3ef337741bf7b38f8de2f9da9 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 7 Oct 2019 14:27:49 +0200
Subject: [PATCH xserver 21/24] xwayland: Fix emulated modes not being removed
Subject: [PATCH xserver 21/25] xwayland: Fix emulated modes not being removed
when screen rotation is used
The code building the mode-list does the following to deal with screen
@ -59,5 +59,5 @@ index 0d6b9ac9f..4bc9cd6b8 100644
else
xwl_output_add_emulated_mode_for_client(xwl_output, client, mode, from_vidmode);
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 12a9c05a3088480bc7ab80902e384053f10e51a6 Mon Sep 17 00:00:00 2001
From 677fd1ade4547008b0d67eec460770e002595c3c Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 4 Nov 2019 11:46:49 +0100
Subject: [PATCH xserver 22/24] xwayland: Call
Subject: [PATCH xserver 22/25] xwayland: Call
xwl_window_check_resolution_change_emulation() on newly created O-R windows
Some clients, which use vidmode to change the resolution when going fullscreen,
@ -28,10 +28,10 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 5 insertions(+)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 7111e20ae..734e76b2e 100644
index 4f19f3710..5bb7a68e9 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -821,6 +821,11 @@ ensure_surface_for_window(WindowPtr window)
@@ -808,6 +808,11 @@ ensure_surface_for_window(WindowPtr window)
xwl_window_init_allow_commits(xwl_window);
@ -44,5 +44,5 @@ index 7111e20ae..734e76b2e 100644
err_surf:
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 94fc11313b34e3b35aa275dad1c3bc2455a24ec3 Mon Sep 17 00:00:00 2001
From 049333a0ecf8574a0612bf27850f9682f0f70533 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 4 Nov 2019 14:32:29 +0100
Subject: [PATCH xserver 23/24] xwayland: Fix setting of
Subject: [PATCH xserver 23/25] xwayland: Fix setting of
_XWAYLAND_RANDR_EMU_MONITOR_RECTS prop on new windows
For window-manager managed windows, xwl_realize_window is only called for
@ -35,18 +35,18 @@ Signed-off-by: Hans de Goede <hdegoede@redhat.com>
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 734e76b2e..a7c4f82df 100644
index 5bb7a68e9..1600c00cd 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -751,6 +751,7 @@ ensure_surface_for_window(WindowPtr window)
@@ -738,6 +738,7 @@ ensure_surface_for_window(WindowPtr window)
struct xwl_screen *xwl_screen;
struct xwl_window *xwl_window;
struct wl_region *region;
+ WindowPtr toplevel;
if (xwl_window_get(window))
if (xwl_window_from_window(window))
return TRUE;
@@ -821,7 +822,14 @@ ensure_surface_for_window(WindowPtr window)
@@ -808,7 +809,14 @@ ensure_surface_for_window(WindowPtr window)
xwl_window_init_allow_commits(xwl_window);
@ -62,7 +62,7 @@ index 734e76b2e..a7c4f82df 100644
/* CSD or O-R toplevel window, check viewport on creation */
xwl_window_check_resolution_change_emulation(xwl_window);
}
@@ -870,8 +878,6 @@ xwl_realize_window(WindowPtr window)
@@ -857,8 +865,6 @@ xwl_realize_window(WindowPtr window)
return FALSE;
}
@ -72,5 +72,5 @@ index 734e76b2e..a7c4f82df 100644
}
--
2.26.2
2.28.0

View File

@ -1,7 +1,7 @@
From 2d078b3372e26278e687399a39699c495bfe16d4 Mon Sep 17 00:00:00 2001
From f1d77ed7ac9ee9bc2f0cf60b0e4604bae092ebd0 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 4 Nov 2019 15:01:18 +0100
Subject: [PATCH xserver 24/24] xwayland: Remove unnecessary
Subject: [PATCH xserver 24/25] xwayland: Remove unnecessary
xwl_window_is_toplevel() check from xwl_output_set_window_randr_emu_props()
Since the recent fix to call xwl_output_set_window_randr_emu_props() from
@ -45,5 +45,5 @@ index 4bc9cd6b8..9d3372c8e 100644
static void
--
2.26.2
2.28.0

View File

@ -0,0 +1,37 @@
From b5c62ae463101712a2ed91e976b28af5d1e73064 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <mdaenzer@redhat.com>
Date: Fri, 6 Nov 2020 10:14:19 +0100
Subject: [PATCH xserver 25/25] xwayland: Make window_get_client_toplevel
non-recursive
Noticed while reading the code.
Reviewed-by: Olivier Fourdan <ofourdan@redhat.com>
(cherry picked from commit df3aa4922fd7e256169e541188b724f67ca948e1)
---
hw/xwayland/xwayland.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/hw/xwayland/xwayland.c b/hw/xwayland/xwayland.c
index 1600c00cd..a5756ea14 100644
--- a/hw/xwayland/xwayland.c
+++ b/hw/xwayland/xwayland.c
@@ -578,11 +578,11 @@ window_get_client_toplevel(WindowPtr window)
* decoration/wrapper windows. In that case recurse by checking the client
* of the first *and only* child of the decoration/wrapper window.
*/
- if (window_is_wm_window(window)) {
- if (window->firstChild && window->firstChild == window->lastChild)
- return window_get_client_toplevel(window->firstChild);
- else
+ while (window_is_wm_window(window)) {
+ if (!window->firstChild || window->firstChild != window->lastChild)
return NULL; /* Should never happen, skip resolution emulation */
+
+ window = window->firstChild;
}
return window;
--
2.28.0

View File

@ -1 +1 @@
SHA512 (xorg-server-1.20.9.tar.bz2) = d9b5f93e1b9763a89187d8b272aa7d4ce9709641b8539f4536708af153310e5a4931bffd4229c51a3b0e3b12da7838750aa71b635751fb4c0bb27438cce4e5e6
SHA512 (xorg-server-1.20.10.tar.bz2) = a07bee380bb72f2117fe6f831a6e4aded19bea1f2b36e42a019a30348e98d6fe65c0617cf819be9c6b405502f88cafb829df30aab32393774b71f1418a4cefae

View File

@ -45,8 +45,8 @@
Summary: X.Org X11 X server
Name: xorg-x11-server
Version: 1.20.9
Release: 3%{?gitdate:.%{gitdate}}%{?dist}
Version: 1.20.10
Release: 1%{?gitdate:.%{gitdate}}%{?dist}
URL: http://www.x.org
License: MIT
@ -93,24 +93,10 @@ Patch5: 0001-autobind-GPUs-to-the-screen.patch
Patch6: 0001-Fedora-hack-Make-the-suid-root-wrapper-always-start-.patch
# Backports from current stable "server-1.20-branch":
Patch101: 0001-Revert-linux-Fix-platform-device-probe-for-DT-based-.patch
Patch102: 0002-Revert-linux-Fix-platform-device-PCI-detection-for-c.patch
Patch103: 0003-Revert-linux-Make-platform-device-probe-less-fragile.patch
Patch104: 0004-include-Increase-the-number-of-max.-input-devices-to.patch
Patch105: 0005-glamor-Fix-glamor_poly_fill_rect_gl-xRectangle-width.patch
Patch106: 0006-xfree86-Take-second-reference-for-SavedCursor-in-xf8.patch
Patch107: 0007-present-wnmd-Can-t-use-page-flipping-for-windows-cli.patch
Patch108: 0008-xwayland-Check-window-pixmap-in-xwl_present_check_fl.patch
Patch109: 0009-present-wnmd-Remove-dead-check-from-present_wnmd_che.patch
Patch110: 0010-xwayland-Do-not-discard-frame-callbacks-on-allow-com.patch
Patch111: 0011-xwayland-use-drmGetNodeTypeFromFd-for-checking-if-a-.patch
Patch112: 0012-xwayland-Remove-pending-stream-reference-when-freein.patch
Patch113: 0013-present-Move-flip-target_msc-adjustment-out-of-prese.patch
Patch114: 0014-present-Add-present_vblank-exec_msc-field.patch
Patch115: 0015-present-wnmd-Move-up-present_wnmd_queue_vblank.patch
Patch116: 0016-present-wnmd-Execute-copies-at-target_msc-1-already.patch
# <empty>
# Backports from "master" upstream:
# <empty>
# Backported Xwayland randr resolution change emulation support
Patch501: 0001-dix-Add-GetCurrentClient-helper.patch
@ -137,6 +123,7 @@ Patch521: 0021-xwayland-Fix-emulated-modes-not-being-removed-when-s.patch
Patch522: 0022-xwayland-Call-xwl_window_check_resolution_change_emu.patch
Patch523: 0023-xwayland-Fix-setting-of-_XWAYLAND_RANDR_EMU_MONITOR_.patch
Patch524: 0024-xwayland-Remove-unnecessary-xwl_window_is_toplevel-c.patch
Patch525: 0025-xwayland-Make-window_get_client_toplevel-non-recursi.patch
BuildRequires: make
BuildRequires: systemtap-sdt-devel
@ -564,6 +551,9 @@ find %{inst_srcdir}/hw/xfree86 -name \*.c -delete
%changelog
* Wed Dec 2 2020 Olivier Fourdan <ofourdan@redhat.com> - 1.20.10-1
- xserver 1.20.10 (CVE-2020-14360, CVE-2020-25712)
* Thu Nov 5 10:35:09 AEST 2020 Peter Hutterer <peter.hutterer@redhat.com> - 1.20.9-3
- Add BuildRequires for make