From 56f85843828906bf283439177175ee8fbfd71f52 Mon Sep 17 00:00:00 2001 From: Aleksei Bavshin Date: Jul 09 2021 01:30:03 +0000 Subject: Update to 0.14.1 --- diff --git a/sources b/sources index 8710f49..1ea256b 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (wlroots-0.14.0.tar.gz) = 83f001133cb4b11a72bb9532b7321655428826662848f67de8e3220a33d9dff4d37c859602bdc319929949d387d014a257b0347039a6649944d7b084c76bb611 -SHA512 (wlroots-0.14.0.tar.gz.sig) = bf329b0a70fd71c0183416d0ffd58b1433ff9b7a0494ce65fd6211085cb71fae44cb0ca2397e53f735e62f48f6fee8f7590f240845b76aa1b56a790ca3b9a7f0 +SHA512 (wlroots-0.14.1.tar.gz) = 4f557c827f9673eccf208a3644954de80e7355b95cc374cc5e851a47087b227f196e0936c0913d21a6c776c29b74de2d028a100931264e41934c747568d8ebe0 +SHA512 (wlroots-0.14.1.tar.gz.sig) = 42b3942737db33de60a4d78df706a490c510ff462d8a15139c6d63c85cc9d1a85843654a3b17c32fb7ceffef160b17bac20a64b5ee8b37720f3c3748f971f2fd diff --git a/wlroots-0.14.0-backend-drm-dont-clear-pending-cursor-FB-on-failed-commit.patch b/wlroots-0.14.0-backend-drm-dont-clear-pending-cursor-FB-on-failed-commit.patch deleted file mode 100644 index be8380d..0000000 --- a/wlroots-0.14.0-backend-drm-dont-clear-pending-cursor-FB-on-failed-commit.patch +++ /dev/null @@ -1,65 +0,0 @@ -From 28f738ed10bf67bdaf340f9438d7fac25a5d7f8f Mon Sep 17 00:00:00 2001 -From: Simon Ser -Date: Mon, 5 Jul 2021 10:57:33 +0200 -Subject: [PATCH 1/2] Revert "backend/drm: populate cursor plane's current_fb" - -This reverts commit 6c3d080e25e56404228ad7704eed43e40fa0c623. - -Populating wlr_drm_plane.current_fb messes up the buffer's locking. -The previous buffer is released while it's still being displayed -on-screen. ---- - backend/drm/drm.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/backend/drm/drm.c b/backend/drm/drm.c -index 6cfdb64889..7700bd2d59 100644 ---- a/backend/drm/drm.c -+++ b/backend/drm/drm.c -@@ -933,7 +933,7 @@ static bool drm_connector_set_cursor(struct wlr_output *output, - local_buf = wlr_buffer_lock(buffer); - } - -- bool ok = drm_fb_import(&plane->current_fb, drm, local_buf, -+ bool ok = drm_fb_import(&plane->pending_fb, drm, local_buf, - &plane->formats); - wlr_buffer_unlock(local_buf); - if (!ok) { - -From fd21b0d4328fb4f4cc0aafe1ec8b2f3d6125011f Mon Sep 17 00:00:00 2001 -From: Simon Ser -Date: Mon, 5 Jul 2021 11:04:02 +0200 -Subject: [PATCH 2/2] backend/drm: don't clear pending cursor FB on failed - commit - -The previous fix tried to side-step cursor->pending_fb completely. -However that messes up our buffer locking mechanism. - -Instead, stop clearing the pending cursor FB on a failed commit. The -pending cursor FB will remain for the next commit. - -Fixes: 6c3d080e25e5 ("backend/drm: populate cursor plane's current_fb") ---- - backend/drm/drm.c | 9 ++++++--- - 1 file changed, 6 insertions(+), 3 deletions(-) - -diff --git a/backend/drm/drm.c b/backend/drm/drm.c -index 7700bd2d59..b6b4baf6a2 100644 ---- a/backend/drm/drm.c -+++ b/backend/drm/drm.c -@@ -355,9 +355,12 @@ static bool drm_crtc_commit(struct wlr_drm_connector *conn, - } - } else { - drm_fb_clear(&crtc->primary->pending_fb); -- if (crtc->cursor != NULL) { -- drm_fb_clear(&crtc->cursor->pending_fb); -- } -+ // The set_cursor() hook is a bit special: it's not really synchronized -+ // to commit() or test(). Once set_cursor() returns true, the new -+ // cursor is effectively committed. So don't roll it back here, or we -+ // risk ending up in a state where we don't have a cursor FB but -+ // wlr_drm_connector.cursor_enabled is true. -+ // TODO: fix our output interface to avoid this issue. - } - return ok; - } diff --git a/wlroots-0.14.0-surface-accept-commits-with-buffer-size-not-divisibl.patch b/wlroots-0.14.0-surface-accept-commits-with-buffer-size-not-divisibl.patch deleted file mode 100644 index acea2c5..0000000 --- a/wlroots-0.14.0-surface-accept-commits-with-buffer-size-not-divisibl.patch +++ /dev/null @@ -1,57 +0,0 @@ -From 1c4b5bcab3aa1ca7b2c40fd64f77f90b8dde11d7 Mon Sep 17 00:00:00 2001 -From: Simon Ser -Date: Wed, 30 Jun 2021 09:48:31 +0200 -Subject: [PATCH] surface: accept commits with buffer size not divisible by - scale - -There are still many situations where the buffer scale is not -divisible by scale. The fix will require a tad more work, so -let's just log the client error for now and continue handling -the surface commit as usual. - -Closes: https://github.com/swaywm/sway/issues/6352 ---- - types/wlr_surface.c | 9 ++------- - 1 file changed, 2 insertions(+), 7 deletions(-) - -diff --git a/types/wlr_surface.c b/types/wlr_surface.c -index 969645eba7..512449f239 100644 ---- a/types/wlr_surface.c -+++ b/types/wlr_surface.c -@@ -167,7 +167,7 @@ static void surface_state_viewport_src_size(struct wlr_surface_state *state, - } - } - --static bool surface_state_finalize(struct wlr_surface *surface, -+static void surface_state_finalize(struct wlr_surface *surface, - struct wlr_surface_state *state) { - if ((state->committed & WLR_SURFACE_STATE_BUFFER)) { - if (state->buffer_resource != NULL) { -@@ -187,7 +187,6 @@ static bool surface_state_finalize(struct wlr_surface *surface, - wlr_log(WLR_DEBUG, "Client bug: submitted a buffer whose size (%dx%d) " - "is not divisible by scale (%d)", state->buffer_width, - state->buffer_height, state->scale); -- return false; - } - - if (state->viewport.has_dst) { -@@ -207,8 +206,6 @@ static bool surface_state_finalize(struct wlr_surface *surface, - pixman_region32_intersect_rect(&state->buffer_damage, - &state->buffer_damage, 0, 0, state->buffer_width, - state->buffer_height); -- -- return true; - } - - static void surface_update_damage(pixman_region32_t *buffer_damage, -@@ -470,9 +467,7 @@ static void surface_commit_state(struct wlr_surface *surface, - } - - static void surface_commit_pending(struct wlr_surface *surface) { -- if (!surface_state_finalize(surface, &surface->pending)) { -- return; -- } -+ surface_state_finalize(surface, &surface->pending); - - if (surface->role && surface->role->precommit) { - surface->role->precommit(surface); diff --git a/wlroots.spec b/wlroots.spec index 78abd8c..9df2b6f 100644 --- a/wlroots.spec +++ b/wlroots.spec @@ -2,8 +2,8 @@ %global abi_ver 9 Name: wlroots -Version: 0.14.0 -Release: 2%{?dist} +Version: 0.14.1 +Release: 1%{?dist} Summary: A modular Wayland compositor library # Source files/overall project licensed as MIT, but @@ -25,10 +25,6 @@ Source2: https://emersion.fr/.well-known/openpgpkey/hu/dj3498u4hyyarh35rk # - make it self-contained # - only has targets for examples known to compile well (cf. "examples) global) Source3: examples.meson.build -# Disappearing cursor on scaled outputs, swaywm/sway#6352 -Patch0: %{url}/commit/1c4b5bc.patch#/wlroots-0.14.0-surface-accept-commits-with-buffer-size-not-divisibl.patch -# Fixes multiple issues with cursors and multi-GPU setups -Patch1: %{url}/pull/3021.patch#/wlroots-0.14.0-backend-drm-dont-clear-pending-cursor-FB-on-failed-commit.patch BuildRequires: gcc BuildRequires: gnupg2 @@ -125,6 +121,9 @@ install -pm0644 -D '%{SOURCE3}' '%{buildroot}/%{_pkgdocdir}/examples/meson.build %changelog +* Thu Jul 08 2021 Aleksei Bavshin - 0.14.1-1 +- Update to wlroots 0.14.1 + * Wed Jul 07 2021 Aleksei Bavshin - 0.14.0-2 - Add patch for a few more issues with cursors, multi-GPUs and nouveau