public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-qt/qtwayland/files/
@ 2022-12-10 12:25 Andreas Sturmlechner
  0 siblings, 0 replies; 3+ messages in thread
From: Andreas Sturmlechner @ 2022-12-10 12:25 UTC (permalink / raw
  To: gentoo-commits

commit:     e5f894c7eb7213211e97a6f714dd04c947166a87
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sat Dec 10 12:22:47 2022 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sat Dec 10 12:23:52 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e5f894c7

dev-qt/qtwayland: Drop obsolete patches

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 .../qtwayland-5.15.2-QTBUG-90037-QTBUG-91264.patch | 131 ---------------------
 .../qtwayland/files/qtwayland-5.15.3-clang.patch   |  12 --
 2 files changed, 143 deletions(-)

diff --git a/dev-qt/qtwayland/files/qtwayland-5.15.2-QTBUG-90037-QTBUG-91264.patch b/dev-qt/qtwayland/files/qtwayland-5.15.2-QTBUG-90037-QTBUG-91264.patch
deleted file mode 100644
index 8bffa3e08b3e..000000000000
--- a/dev-qt/qtwayland/files/qtwayland-5.15.2-QTBUG-90037-QTBUG-91264.patch
+++ /dev/null
@@ -1,131 +0,0 @@
-From d7b34dbf072236cdfb3b64e5ad26d1ff29dfec5f Mon Sep 17 00:00:00 2001
-From: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
-Date: Thu, 22 Apr 2021 08:42:33 +0200
-Subject: client: Gracefully handle shutdown and window hiding
-
-When a window is hidden or destroyed, the render thread may already
-be rendering. We need to properly read-lock the surface pointer
-when it is in use and exit when it becomes null.
-
-Note that there is also a potential crash in the Mesa GL driver
-where it keeps a proxy to the wl_surface, so if we delete this
-while we are still rendering, it can crash inside the driver.
-This is not addressed by this patch, and has not been reproduced
-on any other drivers so far.
-
-[ChangeLog][Client] Fixed a crash that could happen when hiding
-or closing windows while Qt Quick was actively rendering on
-a different thread.
-
-Pick-to: 6.0 6.1 5.15
-Fixes: QTBUG-91264
-Fixes: QTBUG-90037
-Task-number: QTBUG-92249
-Change-Id: I029b123b83c58740321e8b90a463ced748d8bcf4
-Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
-Reviewed-by: David Edmundson <davidedmundson@kde.org>
-(cherry picked from commit b19b0fbaf775e8b8eda1e03c265a5393d618c6c0)
----
- src/client/qwaylandwindow.cpp                   | 17 ++++++++++++++++-
- src/client/qwaylandwindow_p.h                   |  2 +-
- .../client/wayland-egl/qwaylandglcontext.cpp    |  1 -
- 3 files changed, 17 insertions(+), 3 deletions(-)
-
-diff --git a/src/client/qwaylandwindow.cpp b/src/client/qwaylandwindow.cpp
-index 494911b3..0d849b57 100644
---- a/src/client/qwaylandwindow.cpp
-+++ b/src/client/qwaylandwindow.cpp
-@@ -414,6 +414,7 @@ void QWaylandWindow::closePopups(QWaylandWindow *parent)
- 
- QPlatformScreen *QWaylandWindow::calculateScreenFromSurfaceEvents() const
- {
-+    QReadLocker lock(&mSurfaceLock);
-     if (mSurface) {
-         if (auto *screen = mSurface->oldestEnteredScreen())
-             return screen;
-@@ -552,6 +553,10 @@ void QWaylandWindow::sendRecursiveExposeEvent()
- 
- void QWaylandWindow::attach(QWaylandBuffer *buffer, int x, int y)
- {
-+    QReadLocker locker(&mSurfaceLock);
-+    if (mSurface == nullptr)
-+        return;
-+
-     if (buffer) {
-         Q_ASSERT(!buffer->committed());
-         handleUpdate();
-@@ -571,6 +576,10 @@ void QWaylandWindow::attachOffset(QWaylandBuffer *buffer)
- 
- void QWaylandWindow::damage(const QRect &rect)
- {
-+    QReadLocker locker(&mSurfaceLock);
-+    if (mSurface == nullptr)
-+        return;
-+
-     const int s = scale();
-     if (mDisplay->compositorVersion() >= 4)
-         mSurface->damage_buffer(s * rect.x(), s * rect.y(), s * rect.width(), s * rect.height());
-@@ -605,6 +614,8 @@ void QWaylandWindow::commit(QWaylandBuffer *buffer, const QRegion &damage)
-         qCDebug(lcWaylandBackingstore) << "Buffer already committed, ignoring.";
-         return;
-     }
-+
-+    QReadLocker locker(&mSurfaceLock);
-     if (!mSurface)
-         return;
- 
-@@ -624,7 +635,9 @@ void QWaylandWindow::commit(QWaylandBuffer *buffer, const QRegion &damage)
- 
- void QWaylandWindow::commit()
- {
--    mSurface->commit();
-+    QReadLocker locker(&mSurfaceLock);
-+    if (mSurface != nullptr)
-+        mSurface->commit();
- }
- 
- const wl_callback_listener QWaylandWindow::callbackListener = {
-@@ -725,6 +738,7 @@ QPointF QWaylandWindow::mapFromWlSurface(const QPointF &surfacePosition) const
- 
- wl_surface *QWaylandWindow::wlSurface()
- {
-+    QReadLocker locker(&mSurfaceLock);
-     return mSurface ? mSurface->object() : nullptr;
- }
- 
-@@ -749,6 +763,7 @@ QWaylandScreen *QWaylandWindow::waylandScreen() const
- 
- void QWaylandWindow::handleContentOrientationChange(Qt::ScreenOrientation orientation)
- {
-+    QReadLocker locker(&mSurfaceLock);
-     if (mDisplay->compositorVersion() < 2)
-         return;
- 
-diff --git a/src/client/qwaylandwindow_p.h b/src/client/qwaylandwindow_p.h
-index d45980a8..54ac67a9 100644
---- a/src/client/qwaylandwindow_p.h
-+++ b/src/client/qwaylandwindow_p.h
-@@ -288,7 +288,7 @@ private:
- 
-     static QWaylandWindow *mMouseGrab;
- 
--    QReadWriteLock mSurfaceLock;
-+    mutable QReadWriteLock mSurfaceLock;
- 
-     friend class QWaylandSubSurface;
- };
-diff --git a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
-index 683fe123..8f12736d 100644
---- a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
-+++ b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
-@@ -192,7 +192,6 @@ public:
-     }
-     void blit(QWaylandEglWindow *window)
-     {
--        Q_ASSERT(window->wlSurface());
-         QOpenGLTextureCache *cache = QOpenGLTextureCache::cacheForContext(m_context->context());
- 
-         QSize surfaceSize = window->surfaceSize();
--- 
-2.35.0
-

diff --git a/dev-qt/qtwayland/files/qtwayland-5.15.3-clang.patch b/dev-qt/qtwayland/files/qtwayland-5.15.3-clang.patch
deleted file mode 100644
index 4ad80127f516..000000000000
--- a/dev-qt/qtwayland/files/qtwayland-5.15.3-clang.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-https://bugs.gentoo.org/833488
---- a/src/hardwareintegration/compositor/linux-dmabuf-unstable-v1/linuxdmabuf.h
-+++ b/src/hardwareintegration/compositor/linux-dmabuf-unstable-v1/linuxdmabuf.h
-@@ -44,6 +44,8 @@
- #include <EGL/egl.h>
- #include <EGL/eglext.h>
- 
-+#include <array>
-+
- // compatibility with libdrm <= 2.4.74
- #ifndef DRM_FORMAT_RESERVED
- #define DRM_FORMAT_RESERVED           ((1ULL << 56) - 1)


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-qt/qtwayland/files/
@ 2023-07-14  7:31 Sam James
  0 siblings, 0 replies; 3+ messages in thread
From: Sam James @ 2023-07-14  7:31 UTC (permalink / raw
  To: gentoo-commits

commit:     a7f4aecbf52c48a09536a13e85122ddae60613e4
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Jul 14 07:31:09 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Jul 14 07:31:09 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a7f4aecb

dev-qt/qtwayland: throw in some more detail to patch description

I've put this in the MR but not in the commit message for the MR because
I'm not sure they want commentary there.

Bug: https://bugs.gentoo.org/910315
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../qtwayland-5.15.10-Destroy-frame-queue-before-display.patch   | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/dev-qt/qtwayland/files/qtwayland-5.15.10-Destroy-frame-queue-before-display.patch b/dev-qt/qtwayland/files/qtwayland-5.15.10-Destroy-frame-queue-before-display.patch
index 9844d25dbebf..1fdf08dc7487 100644
--- a/dev-qt/qtwayland/files/qtwayland-5.15.10-Destroy-frame-queue-before-display.patch
+++ b/dev-qt/qtwayland/files/qtwayland-5.15.10-Destroy-frame-queue-before-display.patch
@@ -1,6 +1,15 @@
 https://bugs.gentoo.org/910315
 https://invent.kde.org/qt/qt/qtwayland/-/merge_requests/73
 
+Reported downstream in Gentoo at https://bugs.gentoo.org/910315.
+
+`kde/5.15` has b981fc82eb37700353949c72d3fd6d0887c8c107 ('[PATCH 27/51] Reduce memory leakage')
+backported but this introduces a use-after-free because `wl_event_queue_destroy` must be called
+before `wl_display_disconnect`. So, just backport the upstream fix which sorts out the order.
+
+Upstream review: https://codereview.qt-project.org/c/qt/qtwayland/+/471416
+Upstream review (6.x): https://codereview.qt-project.org/c/qt/qtwayland/+/471528
+
 From 3a8613b91d2239aebc73b43562f929aa71af0de5 Mon Sep 17 00:00:00 2001
 From: David Redondo <qt@david-redondo.de>
 Date: Tue, 11 Apr 2023 14:27:27 +0200


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-qt/qtwayland/files/
@ 2025-02-27  9:31 Ionen Wolkens
  0 siblings, 0 replies; 3+ messages in thread
From: Ionen Wolkens @ 2025-02-27  9:31 UTC (permalink / raw
  To: gentoo-commits

commit:     b61a919c9d37c4147ace83feb11bb670e3e702bf
Author:     Michael Mair-Keimberger <mmk <AT> levelnine <DOT> at>
AuthorDate: Thu Feb 27 08:55:05 2025 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Thu Feb 27 09:31:24 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b61a919c

dev-qt/qtwayland: remove unused patch

Signed-off-by: Michael Mair-Keimberger <mmk <AT> levelnine.at>
Closes: https://github.com/gentoo/gentoo/pull/40786
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 .../files/qtwayland-6.8.1-tablet-crash.patch       | 201 ---------------------
 1 file changed, 201 deletions(-)

diff --git a/dev-qt/qtwayland/files/qtwayland-6.8.1-tablet-crash.patch b/dev-qt/qtwayland/files/qtwayland-6.8.1-tablet-crash.patch
deleted file mode 100644
index 8d2a5c89dd4c..000000000000
--- a/dev-qt/qtwayland/files/qtwayland-6.8.1-tablet-crash.patch
+++ /dev/null
@@ -1,201 +0,0 @@
-Recommended backport of [1] by the kde community[2] to avoid several crashes
-when unplugging a tablet (missed the 6.8.1 window, will be in 6.8.2).
-
-[1] https://github.com/qt/qtwayland/commit/24002ac6cbd01dbde4944b63c1f7c87ed2bd72b5
-[2] https://mail.kde.org/pipermail/distributions/2024-November/001550.html
---- a/src/client/qwaylandtabletv2.cpp
-+++ b/src/client/qwaylandtabletv2.cpp
-@@ -188,10 +188,4 @@
- QWaylandTabletSeatV2::~QWaylandTabletSeatV2()
- {
--    for (auto *tablet : m_tablets)
--        tablet->destroy();
--    for (auto *tool : m_tools)
--        tool->destroy();
--    for (auto *pad : m_pads)
--        pad->destroy();
-     qDeleteAll(m_tablets);
-     qDeleteAll(m_tools);
-@@ -255,4 +249,9 @@
- }
- 
-+QWaylandTabletV2::~QWaylandTabletV2()
-+{
-+    destroy();
-+}
-+
- void QWaylandTabletV2::zwp_tablet_v2_name(const QString &name)
- {
-@@ -293,5 +292,4 @@
- void QWaylandTabletV2::zwp_tablet_v2_removed()
- {
--    destroy();
-     deleteLater();
- }
-@@ -317,5 +315,8 @@
- }
- 
--QWaylandTabletToolV2::~QWaylandTabletToolV2() = default;
-+QWaylandTabletToolV2::~QWaylandTabletToolV2()
-+{
-+    destroy();
-+}
- 
- void QWaylandTabletToolV2::zwp_tablet_tool_v2_type(uint32_t tool_type)
-@@ -411,5 +412,4 @@
- void QWaylandTabletToolV2::zwp_tablet_tool_v2_removed()
- {
--    destroy();
-     m_tabletSeat->toolRemoved(this);
- }
-@@ -603,4 +603,9 @@
- }
- 
-+QWaylandTabletPadV2::~QWaylandTabletPadV2()
-+{
-+    destroy();
-+}
-+
- void QWaylandTabletPadV2::zwp_tablet_pad_v2_path(const QString &path)
- {
-@@ -622,5 +627,4 @@
- void QWaylandTabletPadV2::zwp_tablet_pad_v2_removed()
- {
--    destroy();
-     delete this;
- }
---- a/src/client/qwaylandtabletv2_p.h
-+++ b/src/client/qwaylandtabletv2_p.h
-@@ -84,4 +84,5 @@
- public:
-     explicit QWaylandTabletV2(::zwp_tablet_v2 *tablet, const QString &seatName);
-+    ~QWaylandTabletV2();
- 
- protected:
-@@ -99,5 +100,5 @@
- public:
-     QWaylandTabletToolV2(QWaylandTabletSeatV2 *tabletSeat, ::zwp_tablet_tool_v2 *tool);
--    ~QWaylandTabletToolV2() override;
-+    ~QWaylandTabletToolV2();
- 
-     void updateCursor();
-@@ -182,4 +183,5 @@
- public:
-     explicit QWaylandTabletPadV2(::zwp_tablet_pad_v2 *pad);
-+    ~QWaylandTabletPadV2();
- 
- protected:
---- a/tests/auto/client/tabletv2/tst_tabletv2.cpp
-+++ b/tests/auto/client/tabletv2/tst_tabletv2.cpp
-@@ -187,7 +187,7 @@
-     QList<TabletV2 *> m_tabletsWaitingForDestroy;
-     QList<TabletToolV2 *> m_tools;
--    QList<TabletToolV2 *> m_toolsWaitingForDestroy;
-+    QList<TabletToolV2::Resource *> m_toolsWaitingForDestroy;
-     QList<TabletPadV2 *> m_pads;
--    QList<TabletPadV2 *> m_padsWaitingForDestroy;
-+    QList<TabletPadV2::Resource *> m_padsWaitingForDestroy;
- 
- protected:
-@@ -275,9 +275,10 @@
- void TabletToolV2::sendRemoved()
- {
--    for (auto *resource : resourceMap())
-+    for (auto *resource : resourceMap()) {
-         zwp_tablet_tool_v2_send_removed(resource->handle);
-+        m_tabletSeat->m_toolsWaitingForDestroy.append(resource);
-+    }
-     bool removed = m_tabletSeat->m_tools.removeOne(this);
-     QVERIFY(removed);
--    m_tabletSeat->m_toolsWaitingForDestroy.append(this);
- }
- 
-@@ -334,6 +335,5 @@
- {
-     if (m_tabletSeat) {
--        bool removed = m_tabletSeat->m_toolsWaitingForDestroy.removeOne(this);
--        QVERIFY(removed);
-+        m_tabletSeat->m_toolsWaitingForDestroy.removeOne(resource);
-     }
-     wl_resource_destroy(resource->handle);
-@@ -342,9 +342,10 @@
- void TabletPadV2::sendRemoved()
- {
--    for (auto *resource : resourceMap())
-+    for (auto *resource : resourceMap()) {
-         zwp_tablet_pad_v2_send_removed(resource->handle);
-+        m_tabletSeat->m_padsWaitingForDestroy.append(resource);
-+    }
-     bool removed = m_tabletSeat->m_pads.removeOne(this);
-     QVERIFY(removed);
--    m_tabletSeat->m_padsWaitingForDestroy.append(this);
- }
- 
-@@ -352,6 +353,5 @@
- {
-     if (m_tabletSeat) {
--        bool removed = m_tabletSeat->m_padsWaitingForDestroy.removeOne(this);
--        QVERIFY(removed);
-+        m_tabletSeat->m_padsWaitingForDestroy.removeOne(resource);
-     }
-     wl_resource_destroy(resource->handle);
-@@ -406,4 +406,6 @@
-     void destroysTool();
-     void destroysPad();
-+    void removeTabletBeforeTool();
-+    void removeTabletBeforePad();
-     void proximityEvents();
-     void moveEvent();
-@@ -503,4 +505,5 @@
-     QCOMPOSITOR_TRY_VERIFY(tabletSeat());
-     exec([&] {
-+        tabletSeat()->addTablet();
-         tabletSeat()->addTool();
-     });
-@@ -509,4 +512,5 @@
-     exec([&] {
-         tabletTool()->sendRemoved();
-+        tablet()->sendRemoved();
-     });
- 
-@@ -529,4 +533,40 @@
-     QCOMPOSITOR_TRY_VERIFY(!tabletPad());
-     QCOMPOSITOR_TRY_VERIFY(tabletSeat()->m_padsWaitingForDestroy.empty());
-+}
-+
-+void tst_tabletv2::removeTabletBeforeTool()
-+{
-+    QCOMPOSITOR_TRY_VERIFY(tabletSeat());
-+    exec([&] {
-+        tabletSeat()->addTablet();
-+        tabletSeat()->addTool();
-+    });
-+    QCOMPOSITOR_TRY_VERIFY(tablet());
-+    QCOMPOSITOR_TRY_VERIFY(tabletTool());
-+
-+    exec([&] { tablet()->sendRemoved(); });
-+    QCOMPOSITOR_TRY_VERIFY(tabletSeat()->m_tabletsWaitingForDestroy.empty());
-+
-+    exec([&] { tabletTool()->sendRemoved(); });
-+    QCOMPOSITOR_TRY_VERIFY(!tabletTool());
-+    QCOMPOSITOR_TRY_VERIFY(tabletSeat()->m_toolsWaitingForDestroy.empty());
-+}
-+
-+void tst_tabletv2::removeTabletBeforePad()
-+{
-+    QCOMPOSITOR_TRY_VERIFY(tabletSeat());
-+    exec([&] {
-+        tabletSeat()->addTablet();
-+        tabletSeat()->addPad();
-+    });
-+    QCOMPOSITOR_TRY_VERIFY(tablet());
-+    QCOMPOSITOR_TRY_VERIFY(tabletPad());
-+
-+    exec([&] { tablet()->sendRemoved(); });
-+    QCOMPOSITOR_TRY_VERIFY(tabletSeat()->m_tabletsWaitingForDestroy.empty());
-+
-+    exec([&] { tabletPad()->sendRemoved(); });
-+    QCOMPOSITOR_TRY_VERIFY(!tabletPad());
-+    QCOMPOSITOR_TRY_VERIFY(tabletSeat()->m_padsWaitingForDestroy.empty());
- }
- 


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-02-27  9:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-27  9:31 [gentoo-commits] repo/gentoo:master commit in: dev-qt/qtwayland/files/ Ionen Wolkens
  -- strict thread matches above, loose matches on Subject: below --
2023-07-14  7:31 Sam James
2022-12-10 12:25 Andreas Sturmlechner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox