Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package libnvidia-egl-wayland2 for 
openSUSE:Factory checked in at 2026-09-02 17:02:42
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/libnvidia-egl-wayland2 (Old)
 and      /work/SRC/openSUSE:Factory/.libnvidia-egl-wayland2.new.1265 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "libnvidia-egl-wayland2"

Wed Sep  2 17:02:42 2026 rev:3 rq:1375251 version:1.0.2~20260716gitMACRO

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/libnvidia-egl-wayland2/libnvidia-egl-wayland2.changes
    2026-02-04 21:10:39.532062076 +0100
+++ 
/work/SRC/openSUSE:Factory/.libnvidia-egl-wayland2.new.1265/libnvidia-egl-wayland2.changes
  2026-09-02 17:02:44.594318174 +0200
@@ -1,0 +2,23 @@
+Tue Sep  1 11:51:48 UTC 2026 - Stefan Dirsch <[email protected]>
+
+- added latest patches from git
+  * 0022-Remove-the-still-in-development-line-from-the-readme.patch
+  * 0023-Increment-version-number-to-1.0.2.patch
+  * 0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch
+  * 0025-wayland-Update-to-match-the-base-library.patch
+  * 0026-fix-parameter-validation.patch
+  * 0027-Return-invalid-fd-on-syncobj-creation-failure.patch
+  * 0028-Clean-up-Wayland-display-globals.patch
+  * 0029-Use-common-cleanup-for-render-device-open-failures.patch
+  * 0030-Store-presentation-timestamps-in-nanoseconds.patch
+  * 0031-Accept-surface-feedback-tranches-whose-target-matche.patch
+  * 0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch
+  * 0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch
+  * 0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch
+  * 0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch
+  * 0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch
+  * 0037-Use-wl_array_init-instead-of-.size-0.patch
+  * 0038-wayland-Bound-protocol-override-separator-search.patch
+- bump version to 1.0.2
+
+-------------------------------------------------------------------

New:
----
  0022-Remove-the-still-in-development-line-from-the-readme.patch
  0023-Increment-version-number-to-1.0.2.patch
  0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch
  0025-wayland-Update-to-match-the-base-library.patch
  0026-fix-parameter-validation.patch
  0027-Return-invalid-fd-on-syncobj-creation-failure.patch
  0028-Clean-up-Wayland-display-globals.patch
  0029-Use-common-cleanup-for-render-device-open-failures.patch
  0030-Store-presentation-timestamps-in-nanoseconds.patch
  0031-Accept-surface-feedback-tranches-whose-target-matche.patch
  0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch
  0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch
  0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch
  0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch
  0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch
  0037-Use-wl_array_init-instead-of-.size-0.patch
  0038-wayland-Bound-protocol-override-separator-search.patch

----------(New B)----------
  New:- added latest patches from git
  * 0022-Remove-the-still-in-development-line-from-the-readme.patch
  * 0023-Increment-version-number-to-1.0.2.patch
  New:  * 0022-Remove-the-still-in-development-line-from-the-readme.patch
  * 0023-Increment-version-number-to-1.0.2.patch
  * 0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch
  New:  * 0023-Increment-version-number-to-1.0.2.patch
  * 0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch
  * 0025-wayland-Update-to-match-the-base-library.patch
  New:  * 0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch
  * 0025-wayland-Update-to-match-the-base-library.patch
  * 0026-fix-parameter-validation.patch
  New:  * 0025-wayland-Update-to-match-the-base-library.patch
  * 0026-fix-parameter-validation.patch
  * 0027-Return-invalid-fd-on-syncobj-creation-failure.patch
  New:  * 0026-fix-parameter-validation.patch
  * 0027-Return-invalid-fd-on-syncobj-creation-failure.patch
  * 0028-Clean-up-Wayland-display-globals.patch
  New:  * 0027-Return-invalid-fd-on-syncobj-creation-failure.patch
  * 0028-Clean-up-Wayland-display-globals.patch
  * 0029-Use-common-cleanup-for-render-device-open-failures.patch
  New:  * 0028-Clean-up-Wayland-display-globals.patch
  * 0029-Use-common-cleanup-for-render-device-open-failures.patch
  * 0030-Store-presentation-timestamps-in-nanoseconds.patch
  New:  * 0029-Use-common-cleanup-for-render-device-open-failures.patch
  * 0030-Store-presentation-timestamps-in-nanoseconds.patch
  * 0031-Accept-surface-feedback-tranches-whose-target-matche.patch
  New:  * 0030-Store-presentation-timestamps-in-nanoseconds.patch
  * 0031-Accept-surface-feedback-tranches-whose-target-matche.patch
  * 0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch
  New:  * 0031-Accept-surface-feedback-tranches-whose-target-matche.patch
  * 0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch
  * 0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch
  New:  * 0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch
  * 0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch
  * 0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch
  New:  * 0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch
  * 0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch
  * 0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch
  New:  * 0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch
  * 0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch
  * 0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch
  New:  * 0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch
  * 0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch
  * 0037-Use-wl_array_init-instead-of-.size-0.patch
  New:  * 0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch
  * 0037-Use-wl_array_init-instead-of-.size-0.patch
  * 0038-wayland-Bound-protocol-override-separator-search.patch
  New:  * 0037-Use-wl_array_init-instead-of-.size-0.patch
  * 0038-wayland-Bound-protocol-override-separator-search.patch
- bump version to 1.0.2
----------(New E)----------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ libnvidia-egl-wayland2.spec ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.221374643 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.224374747 +0200
@@ -20,8 +20,8 @@
 %define meson_install /usr/bin/meson install -C %{_vpath_builddir} 
--no-rebuild --destdir=%{buildroot}
 %endif
 
-%global commit0 ada1c37041002f4f009a33d6d285eae39bf9ad02
-%global date 20251213
+%global commit0 2023f59ba02af9cbdb3ad26678ccc95ffc777c5a
+%global date 20260716
 %global shortcommit0 %(c=%{commit0}; echo ${c:0:7})
 #global tag %%{version}
 
@@ -30,8 +30,8 @@
 %define rname egl-wayland2
 
 Name:           libnvidia-egl-wayland2
-Version:        1.0.1%{!?tag:~%{date}git%{shortcommit0}}
-Release:        1
+Version:        1.0.2%{!?tag:~%{date}git%{shortcommit0}}
+Release:        0
 Summary:        Dma-buf-based Wayland external platform library
 # src/wayland/dma-buf.h is GPL 2, rest is Apache 2.0
 License:        Apache-2.0 and GPL-2.0
@@ -62,6 +62,23 @@
 Patch19:        0019-Don-t-use-the-wl_display-during-teardown.patch
 Patch20:        0020-Fix-building-on-FreeBSD.patch
 Patch21:        0021-Fix-NULL-pointer-passed-to-wl_event_queue_destroy.patch
+Patch22:        0022-Remove-the-still-in-development-line-from-the-readme.patch
+Patch23:        0023-Increment-version-number-to-1.0.2.patch
+Patch24:        0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch
+Patch25:        0025-wayland-Update-to-match-the-base-library.patch
+Patch26:        0026-fix-parameter-validation.patch
+Patch27:        0027-Return-invalid-fd-on-syncobj-creation-failure.patch
+Patch28:        0028-Clean-up-Wayland-display-globals.patch
+Patch29:        0029-Use-common-cleanup-for-render-device-open-failures.patch
+Patch30:        0030-Store-presentation-timestamps-in-nanoseconds.patch
+Patch31:        0031-Accept-surface-feedback-tranches-whose-target-matche.patch
+Patch32:        0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch
+Patch33:        0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch
+Patch34:        0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch
+Patch35:        0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch
+Patch36:        0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch
+Patch37:        0037-Use-wl_array_init-instead-of-.size-0.patch
+Patch38:        0038-wayland-Bound-protocol-override-separator-search.patch
 BuildRequires:  Mesa-libGL-devel
 BuildRequires:  gcc-c++
 BuildRequires:  meson >= 0.50

++++++ 0001-egl-wayland2-close-dmabuf-format-table-fd.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.271376379 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.274376483 +0200
@@ -1,7 +1,7 @@
 From 9ae4f1daf3c9f1a30ef0870d74db7196c3fe8ebf Mon Sep 17 00:00:00 2001
 From: Austin Shafer <[email protected]>
 Date: Tue, 5 Aug 2025 13:02:45 -0400
-Subject: [PATCH 01/21] egl-wayland2: close dmabuf format table fd
+Subject: [PATCH 01/38] egl-wayland2: close dmabuf format table fd
 
 The compositor sends us a memfd for the format table, we need to
 actually close it once we are done. This is causing an fd leak on

++++++ 0002-Update-the-wl_egl_window-attached-size.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.306377593 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.319378044 +0200
@@ -1,7 +1,7 @@
 From ab4d5af9899d05ccbc363c4ec0e4f02d6525bf3e Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 5 Aug 2025 16:41:23 -0600
-Subject: [PATCH 02/21] Update the wl_egl_window attached size.
+Subject: [PATCH 02/38] Update the wl_egl_window attached size.
 
 In eglSwapBuffers, after sending the wl_surface::commit request, update
 wl_egl_window::attached_width and attached_height to the size of the

++++++ 0003-egl-wayland2-Fix-libdrm-loading-when-wl_drm-is-not-a.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.359379433 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.369379780 +0200
@@ -1,7 +1,7 @@
 From eb31eb3674829a12e8b49dee17b5f3d3ab92d31d Mon Sep 17 00:00:00 2001
 From: Austin Shafer <[email protected]>
 Date: Fri, 5 Sep 2025 15:14:27 -0400
-Subject: [PATCH 03/21] egl-wayland2: Fix libdrm loading when wl_drm is not
+Subject: [PATCH 03/38] egl-wayland2: Fix libdrm loading when wl_drm is not
  available
 
 If the compositor does not support wl_drm and we fail to get the

++++++ 0004-Remove-a-stray-abort-in-eplWlCreateWindowSurface.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.400380856 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.408381133 +0200
@@ -1,7 +1,7 @@
 From fa3c994af319e265f3ff3da2bb2d76e0b993128a Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 14 Oct 2025 15:11:57 -0600
-Subject: [PATCH 04/21] Remove a stray abort() in eplWlCreateWindowSurface.
+Subject: [PATCH 04/38] Remove a stray abort() in eplWlCreateWindowSurface.
 
 ---
  src/wayland/wayland-surface.c | 1 -

++++++ 0005-Increment-version-number-to-1.0.1.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.435382071 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.439382209 +0200
@@ -1,7 +1,7 @@
 From bdf038ba6e2b31014ca232c849dd8610c2cb4b3f Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Thu, 16 Oct 2025 11:38:03 -0600
-Subject: [PATCH 05/21] Increment version number to 1.0.1.
+Subject: [PATCH 05/38] Increment version number to 1.0.1.
 
 ---
  meson.build | 2 +-

++++++ 0006-base-Add-basic-support-for-EGL_KHR_partial_update.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.476383494 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.488383910 +0200
@@ -1,7 +1,7 @@
 From dcbb123f1804572889d2dc45af00e89ee9e5ff4f Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 14 Oct 2025 16:33:47 -0600
-Subject: [PATCH 06/21] base: Add basic support for EGL_KHR_partial_update.
+Subject: [PATCH 06/38] base: Add basic support for EGL_KHR_partial_update.
 
 Add the necessary bookkeeping to handle EGL_KHR_partial_update and
 EGL_EXT_buffer_age.

++++++ 0007-base-Add-an-EplImplFuncs-function-for-EGL_BUFFER_AGE.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.526385229 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.533385472 +0200
@@ -1,7 +1,7 @@
 From 94f578e48cbcde2468385b7187b71d22b2bb9ba2 Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 14 Oct 2025 16:42:08 -0600
-Subject: [PATCH 07/21] base: Add an EplImplFuncs function for EGL_BUFFER_AGE.
+Subject: [PATCH 07/38] base: Add an EplImplFuncs function for EGL_BUFFER_AGE.
 
 Add a new function, EplImplFuncs::QueryBufferAge, which is used to check
 the value of EGL_BUFFER_AGE for a surface.

++++++ 0008-base-Add-an-EplImplFuncs-function-for-eglSetDamageRe.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.564386548 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.572386825 +0200
@@ -1,7 +1,7 @@
 From 83c95316e8758ae46232d78d7425fdefcedb603c Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 14 Oct 2025 16:49:33 -0600
-Subject: [PATCH 08/21] base: Add an EplImplFuncs function for
+Subject: [PATCH 08/38] base: Add an EplImplFuncs function for
  eglSetDamageRegionKHR
 
 Add an optional EplImplFuncs::SetDamageRegion function to implement

++++++ 0009-wayland-Implement-EplImplFuncs-QueryBufferAge.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.598387728 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.611388179 +0200
@@ -1,7 +1,7 @@
 From 40d205187661699d96d2e27ece56af9bf61295aa Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 14 Oct 2025 17:00:07 -0600
-Subject: [PATCH 09/21] wayland: Implement EplImplFuncs::QueryBufferAge.
+Subject: [PATCH 09/38] wayland: Implement EplImplFuncs::QueryBufferAge.
 
 Add a buffer_age field to WlPresentBuffer, and add a new
 eplWlSwapChainUpdateBufferAge function to increment the ages of the

++++++ 0010-Fix-the-version-check-for-wl_surface.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.641389220 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.654389671 +0200
@@ -1,7 +1,7 @@
 From d1f80ea8ab4d3b808854673975dbf1e1ea9dac9d Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Tue, 21 Oct 2025 12:00:27 -0600
-Subject: [PATCH 10/21] Fix the version check for wl_surface.
+Subject: [PATCH 10/38] Fix the version check for wl_surface.
 
 In eplWlSwapBuffers, fix the version check for whether
 wl_surface::damage_buffer is available. It was checking against version

++++++ 0011-wayland-Flip-the-damage-rectangles-in-wl_surface_dam.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.678390504 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.686390782 +0200
@@ -1,7 +1,7 @@
 From 4b95dc9879a812a812f1e77d31f63220e378b5a7 Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Fri, 7 Nov 2025 11:47:29 -0700
-Subject: [PATCH 11/21] wayland: Flip the damage rectangles in
+Subject: [PATCH 11/38] wayland: Flip the damage rectangles in
  wl_surface_damage_buffer
 
 Flip the Y coordinate for the damage rectangles.

++++++ 0012-egl-wayland2-add-FP16-DRM-format.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.719391927 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.729392275 +0200
@@ -1,7 +1,7 @@
 From 4f027414b95d358c8f088b7631a5755f1639e10e Mon Sep 17 00:00:00 2001
 From: Austin Shafer <[email protected]>
 Date: Mon, 27 Oct 2025 14:03:55 -0400
-Subject: [PATCH 12/21] egl-wayland2: add FP16 DRM format
+Subject: [PATCH 12/38] egl-wayland2: add FP16 DRM format
 
 ---
  src/base/config-list.c | 1 +

++++++ 0014-Fix-multisampled-windows.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.755393177 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.762393420 +0200
@@ -1,7 +1,7 @@
 From d67240ab29f0dd4af4320fc3288842b24b3c8777 Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Mon, 10 Nov 2025 14:34:04 -0700
-Subject: [PATCH 14/21] Fix multisampled windows.
+Subject: [PATCH 14/38] Fix multisampled windows.
 
 Multisampling requires the driver to downsample the image before
 presentation, which wasn't getting called.

++++++ 0015-Disable-multisampled-windows-on-older-drivers.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.792394461 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.802394808 +0200
@@ -1,7 +1,7 @@
 From 0c15809fcfb3fcf4b2eb2422fdd1dae4f9aea6ae Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Mon, 10 Nov 2025 14:41:53 -0700
-Subject: [PATCH 15/21] Disable multisampled windows on older drivers.
+Subject: [PATCH 15/38] Disable multisampled windows on older drivers.
 
 Multisampled windows require additional driver support that was added in
 version 0.2 of the platform surface interface.

++++++ 0016-Don-t-pass-EGL_RENDER_BUFFER-to-the-driver.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.836395988 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.844396266 +0200
@@ -1,7 +1,7 @@
 From 14c013b12ef4cccdabaa7df5269939a563d51898 Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Mon, 24 Nov 2025 11:25:15 -0700
-Subject: [PATCH 16/21] Don't pass EGL_RENDER_BUFFER to the driver.
+Subject: [PATCH 16/38] Don't pass EGL_RENDER_BUFFER to the driver.
 
 In eplWlCreateWindowSurface, if the application passes the
 EGL_RENDER_BUFFER attribute, then consume it locally instead of passing

++++++ 0017-Fix-an-incorrect-return-statement-in-eplWlSwapBuffer.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.870397168 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.876397376 +0200
@@ -1,7 +1,7 @@
 From 797026638f234a4a178c5ca6be8939df6ebd5afd Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Wed, 10 Dec 2025 08:31:56 -0700
-Subject: [PATCH 17/21] Fix an incorrect return statement in eplWlSwapBuffers.
+Subject: [PATCH 17/38] Fix an incorrect return statement in eplWlSwapBuffers.
 
 In eplWlSwapBuffers, if WaitForPreviousFrames fails, then do all the
 necessary cleanup before returning.

++++++ 0018-Replace-SurfaceFeedbackState-modifiers_changed-with-.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.909398522 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.913398661 +0200
@@ -1,7 +1,7 @@
 From a6d6523b6b7ec9e5649a0dd13d417586d814e209 Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Wed, 10 Dec 2025 08:19:14 -0700
-Subject: [PATCH 18/21] Replace SurfaceFeedbackState::modifiers_changed with a
+Subject: [PATCH 18/38] Replace SurfaceFeedbackState::modifiers_changed with a
  counter
 
 Currently, we set the modifiers_changed flag upon receiving new surface

++++++ 0019-Don-t-use-the-wl_display-during-teardown.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.939399563 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.954400084 +0200
@@ -1,7 +1,7 @@
 From 744774943caf4ff0ab95687ae0f6d3e11ea7c44d Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Mon, 15 Dec 2025 15:46:18 -0700
-Subject: [PATCH 19/21] Don't use the wl_display during teardown.
+Subject: [PATCH 19/38] Don't use the wl_display during teardown.
 
 Some applications will call wl_display_disconnect but not eglTerminate
 before exiting, which leads to segfaults or hangs when we try to clean

++++++ 0020-Fix-building-on-FreeBSD.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:46.981401021 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:46.995401507 +0200
@@ -1,7 +1,7 @@
 From 3bda68accb174e112e21f37b348cbab3da912afd Mon Sep 17 00:00:00 2001
 From: Kyle Brenneman <[email protected]>
 Date: Mon, 22 Dec 2025 07:49:35 -0700
-Subject: [PATCH 20/21] Fix building on FreeBSD.
+Subject: [PATCH 20/38] Fix building on FreeBSD.
 
 FreeBSD doesn't have ETIME, so if drmSyncobjTimelineWait times out, it
 will fail with ETIMEDOUT instead.

++++++ 0021-Fix-NULL-pointer-passed-to-wl_event_queue_destroy.patch ++++++
--- /var/tmp/diff_new_pack.CPvYmj/_old  2026-09-02 17:02:47.019402340 +0200
+++ /var/tmp/diff_new_pack.CPvYmj/_new  2026-09-02 17:02:47.031402756 +0200
@@ -1,7 +1,7 @@
 From f7b4c68f62efc15e6f25517a6ce370e2b0d6f48f Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
 Date: Fri, 9 Jan 2026 08:46:25 -0500
-Subject: [PATCH 21/21] Fix NULL pointer passed to wl_event_queue_destroy
+Subject: [PATCH 21/38] Fix NULL pointer passed to wl_event_queue_destroy
 
 In eplWlDisplayInstanceCreate, the queue variable may remain NULL if an
 error occurs before an event queue is successfully created. The cleanup

++++++ 0022-Remove-the-still-in-development-line-from-the-readme.patch ++++++
>From c757f0fce6f88f36a9a8c03d897ae43796b6989f Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <[email protected]>
Date: Fri, 6 Mar 2026 09:05:44 -0700
Subject: [PATCH 22/38] Remove the "still in development" line from the readme
 file.

---
 README.md | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/README.md b/README.md
index e25c07f..60ed70b 100644
--- a/README.md
+++ b/README.md
@@ -1,8 +1,5 @@
 # Wayland EGL External Platform library, Version 2
 
-> [!warning]
-> This library is still in development.
-
 This is a new implementation of the EGL External Platform Library for Wayland
 (`EGL_KHR_platform_wayland`), using the NVIDIA driver's new platform surface
 interface, which simplifies a lot of the library and improves window resizing.
-- 
2.51.0


++++++ 0023-Increment-version-number-to-1.0.2.patch ++++++
>From 8bc038de0ab707a3a46e87a09209f59a80de2333 Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <[email protected]>
Date: Fri, 6 Mar 2026 09:18:56 -0700
Subject: [PATCH 23/38] Increment version number to 1.0.2.

---
 meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meson.build b/meson.build
index 7de161d..beb95db 100644
--- a/meson.build
+++ b/meson.build
@@ -14,7 +14,7 @@
 # limitations under the License.
 
 project('nvidia-egl-wayland2', 'c',
-  version : '1.0.1',
+  version : '1.0.2',
   default_options : ['c_std=gnu99'],
 )
 
-- 
2.51.0


++++++ 0024-base-Replace-EplImplFuncs-QueryBufferAge-with-QueryS.patch ++++++
>From 7429b9f95fe81a20a4ae9617f461634b0fbc3ca5 Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <[email protected]>
Date: Tue, 10 Mar 2026 11:03:47 -0600
Subject: [PATCH 24/38] base: Replace EplImplFuncs::QueryBufferAge with
 QuerySurface

Remove EplImplFuncs::QueryBufferAge and replace it with a more general
QuerySurface function.

This allows adding platform-specific attributes, but keeps the
bookkeeping for EGL_BUFFER_AGE_KHR.

Since having the platform code pass the call through to the driver won't
work for EGL_BUFFER_AGE_KHR, this change also adds a new EplQueryResult
enum to distinguish between success, failure, and an attribute that the
platform simply doesn't recognize.

For consistency, also change QueryDisplayAttrib to return an
EplQueryResult.
---
 src/base/platform-base.c | 62 ++++++++++++++++++++++++++--------------
 src/base/platform-impl.h | 44 ++++++++++++++++++++++++----
 2 files changed, 78 insertions(+), 28 deletions(-)

diff --git a/src/base/platform-base.c b/src/base/platform-base.c
index 18196bd..1f86ffc 100644
--- a/src/base/platform-base.c
+++ b/src/base/platform-base.c
@@ -1233,13 +1233,22 @@ static EGLBoolean HookQueryDisplayAttrib(EGLDisplay 
edpy, EGLint attribute, EGLA
         *value = (EGLAttrib) pdpy->track_references;
         ret = EGL_TRUE;
     }
-    else if (pdpy->platform->impl->QueryDisplayAttrib != NULL)
-    {
-        ret = pdpy->platform->impl->QueryDisplayAttrib(pdpy, attribute, value);
-    }
     else
     {
-        ret = 
pdpy->platform->egl.QueryDisplayAttribEXT(pdpy->internal_display, attribute, 
value);
+        EplQueryResult result = EPL_QUERY_RESULT_UNKNOWN;
+        if (pdpy->platform->impl->QueryDisplayAttrib != NULL)
+        {
+            result = pdpy->platform->impl->QueryDisplayAttrib(pdpy, attribute, 
value);
+        }
+
+        if (result == EPL_QUERY_RESULT_UNKNOWN)
+        {
+            ret = 
pdpy->platform->egl.QueryDisplayAttribEXT(pdpy->internal_display, attribute, 
value);
+        }
+        else
+        {
+            ret = (result == EPL_QUERY_RESULT_SUCCESS);
+        }
     }
 
     eplDisplayRelease(pdpy);
@@ -1321,25 +1330,27 @@ static EGLBoolean HookQuerySurface(EGLDisplay edpy, 
EGLSurface esurf, EGLint att
 
     if (psurf != NULL)
     {
+        EplQueryResult result = EPL_QUERY_RESULT_UNKNOWN;
+
         if (attribute == EGL_BUFFER_AGE_KHR)
         {
+            // Querying EGL_BUFFER_AGE_KHR is only valid for the current
+            // EGLSurface.
             if (pdpy->platform->egl.GetCurrentSurface(EGL_DRAW) != esurf)
             {
                 eplSetError(pdpy->platform, EGL_BAD_SURFACE, "EGLSurface %p is 
not current", esurf);
                 goto done;
             }
+        }
 
-            if (pdpy->platform->impl->QueryBufferAge != NULL)
-            {
-                EGLint age = pdpy->platform->impl->QueryBufferAge(pdpy, psurf);
-                if (age < 0)
-                {
-                    goto done;
-                }
+        if (pdpy->platform->impl->QuerySurface != NULL)
+        {
+            result = pdpy->platform->impl->QuerySurface(pdpy, psurf, 
attribute, value);
+        }
 
-                *value = age;
-            }
-            else
+        if (result == EPL_QUERY_RESULT_UNKNOWN)
+        {
+            if (attribute == EGL_BUFFER_AGE_KHR)
             {
                 /*
                  * If the platform code doesn't implement this, then just 
return
@@ -1347,17 +1358,24 @@ static EGLBoolean HookQuerySurface(EGLDisplay edpy, 
EGLSurface esurf, EGLint att
                  * make any assumptions about the buffer's contents.
                  */
                 *value = 0;
+                ret = EGL_TRUE;
+            }
+            else
+            {
+                // If it's not an attribute that we recognize, then pass the 
query
+                // through to the driver.
+                ret = pdpy->platform->egl.QuerySurface(pdpy->internal_display,
+                        psurf->internal_surface, attribute, value);
             }
-
-            psurf->bufferAgeCalled = EGL_TRUE;
-            ret = EGL_TRUE;
         }
         else
         {
-            // If it's not an attribute that we recognize, then pass the query
-            // through to the driver.
-            ret = pdpy->platform->egl.QuerySurface(pdpy->internal_display,
-                    psurf->internal_surface, attribute, value);
+            ret = (result == EPL_QUERY_RESULT_SUCCESS);
+        }
+
+        if (ret && attribute == EGL_BUFFER_AGE_KHR)
+        {
+            psurf->bufferAgeCalled = EGL_TRUE;
         }
     }
     else
diff --git a/src/base/platform-impl.h b/src/base/platform-impl.h
index b6f5dad..527dded 100644
--- a/src/base/platform-impl.h
+++ b/src/base/platform-impl.h
@@ -35,6 +35,31 @@
 extern "C" {
 #endif
 
+/**
+ * This is the return value used for EplImplFuncs::QuerySurface.
+ */
+typedef enum
+{
+    /**
+     * The platform library doesn't recognize the attribute. In this case, the
+     * base library will pass the query through to the driver.
+     */
+    EPL_QUERY_RESULT_UNKNOWN,
+
+    /**
+     * The platform library recognized and returned the attribute.
+     */
+    EPL_QUERY_RESULT_SUCCESS,
+
+    /**
+     * The platform library recognized the attribute, but there was some error
+     * returning the value.
+     *
+     * The platform library should set the EGL error code before returning.
+     */
+    EPL_QUERY_RESULT_ERROR,
+} EplQueryResult;
+
 /**
  * A table of functions for the platform-specific implementation.
  */
@@ -287,9 +312,9 @@ typedef struct _EplImplFuncs
      * \param pdpy The EplDisplay struct
      * \param attrib The attribute to look up.
      * \param[out] value Returns the value of the attribute.
-     * \return EGL_TRUE on success, EGL_FALSE on failure.
+     * \return An \c EplQueryResult value.
      */
-    EGLBoolean (*QueryDisplayAttrib) (EplDisplay *pdpy, EGLint attrib, 
EGLAttrib *ret_value);
+    EplQueryResult (*QueryDisplayAttrib) (EplDisplay *pdpy, EGLint attrib, 
EGLAttrib *ret_value);
 
     /**
      * Implements eglSwapInterval.
@@ -311,16 +336,23 @@ typedef struct _EplImplFuncs
     EGLBoolean (* SwapInterval) (EplDisplay *pdpy, EplSurface *psurf, EGLint 
interval);
 
     /**
-     * Returns the value of EGL_BUFFER_AGE_KHR.
+     * Implements eglQuerySurface for any platform-specific attributes.
      *
      * This function is optional. If it's NULL, then the base library will just
-     * return zero.
+     * act as if the platform returned EPL_QUERY_RESULT_UNKNOWN.
+     *
+     * Note that the base library handles the error checking for
+     * EGL_EXT_buffer_age and EGL_KHR_partial_update internally. If \p attrib
+     * is \c EGL_BUFFER_AGE_KHR, then the platform can assume that the surface
+     * is current.
      *
      * \param pdpy The current display.
      * \param psurf The current draw surface. This will never be NULL.
-     * \return The buffer age, or -1 on error.
+     * \param attrib The attribute to look up.
+     * \param[out] value Returns the value of the attribute.
+     * \return An \c EplQueryResult value.
      */
-    EGLint (* QueryBufferAge) (EplDisplay *pdpy, EplSurface *psurf);
+    EplQueryResult (* QuerySurface) (EplDisplay *pdpy, EplSurface *psurf, 
EGLint attrib, EGLint *ret_value);
 
     /**
      * Implements eglSetDamageRegionKHR.
-- 
2.51.0


++++++ 0025-wayland-Update-to-match-the-base-library.patch ++++++
>From 57ef1265daaff3409342266db3b0c843cbd95e74 Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <[email protected]>
Date: Tue, 10 Mar 2026 11:07:57 -0600
Subject: [PATCH 25/38] wayland: Update to match the base library.

Replaced eplWlQueryBufferAge with eplWlQuerySurface, to match the base
library changes.
---
 src/wayland/wayland-platform.c |  2 +-
 src/wayland/wayland-platform.h |  2 +-
 src/wayland/wayland-surface.c  | 16 ++++++++++++----
 3 files changed, 14 insertions(+), 6 deletions(-)

diff --git a/src/wayland/wayland-platform.c b/src/wayland/wayland-platform.c
index b3d32f4..7b909d9 100644
--- a/src/wayland/wayland-platform.c
+++ b/src/wayland/wayland-platform.c
@@ -59,7 +59,7 @@ static const EplImplFuncs WL_IMPL_FUNCS =
     .SwapBuffers = eplWlSwapBuffers,
     .WaitGL = eplWlWaitGL,
     .SwapInterval = eplWlSwapInterval,
-    .QueryBufferAge = eplWlQueryBufferAge,
+    .QuerySurface = eplWlQuerySurface,
 };
 
 static EGLBoolean LoadProcHelper(EplPlatformData *plat, void *handle, void 
**ptr, const char *name)
diff --git a/src/wayland/wayland-platform.h b/src/wayland/wayland-platform.h
index 2ed5745..0d4503d 100644
--- a/src/wayland/wayland-platform.h
+++ b/src/wayland/wayland-platform.h
@@ -142,6 +142,6 @@ EGLBoolean eplWlSwapInterval(EplDisplay *pdpy, EplSurface 
*psurf, EGLint interva
 
 EGLBoolean eplWlWaitGL(EplDisplay *pdpy, EplSurface *psurf);
 
-EGLint eplWlQueryBufferAge(EplDisplay *pdpy, EplSurface *psurf);
+EplQueryResult eplWlQuerySurface(EplDisplay *pdpy, EplSurface *psurf, EGLint 
attrib, EGLint *ret_value);
 
 #endif // WAYLAND_PLATFORM_H
diff --git a/src/wayland/wayland-surface.c b/src/wayland/wayland-surface.c
index 0a66c46..8481c67 100644
--- a/src/wayland/wayland-surface.c
+++ b/src/wayland/wayland-surface.c
@@ -1648,14 +1648,22 @@ EGLBoolean eplWlWaitGL(EplDisplay *pdpy, EplSurface 
*psurf)
     return ret;
 }
 
-EGLint eplWlQueryBufferAge(EplDisplay *pdpy, EplSurface *psurf)
+EplQueryResult eplWlQuerySurface(EplDisplay *pdpy, EplSurface *psurf, EGLint 
attrib, EGLint *ret_value)
 {
-    if (psurf->priv->current.swapchain->prime)
+    if (attrib == EGL_BUFFER_AGE_KHR)
     {
-        return 0;
+        if (psurf->priv->current.swapchain->prime)
+        {
+            *ret_value = 0;
+        }
+        else
+        {
+            *ret_value = 
psurf->priv->current.swapchain->current_back->buffer_age;
+        }
+        return EPL_QUERY_RESULT_SUCCESS;
     }
     else
     {
-        return psurf->priv->current.swapchain->current_back->buffer_age;
+        return EPL_QUERY_RESULT_UNKNOWN;
     }
 }
-- 
2.51.0


++++++ 0026-fix-parameter-validation.patch ++++++
>From ce455738b9887fb518efe217dfda5615f9bdd45f Mon Sep 17 00:00:00 2001
From: Riku Salminen <[email protected]>
Date: Tue, 14 Apr 2026 14:43:35 +0000
Subject: [PATCH 26/38] fix parameter validation

Add missing validation for EGL_NATIVE_RENDERABLE to eglChooseConfig.

Fixes dEQP-EGL.functional.negative_api.*
---
 src/base/config-list.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/base/config-list.c b/src/base/config-list.c
index ce4095c..19299e7 100644
--- a/src/base/config-list.c
+++ b/src/base/config-list.c
@@ -258,6 +258,14 @@ EplConfig **eplConfigListChooseConfigs(EplPlatformData 
*platform, EGLDisplay edp
             }
             else if (attribs[i] == EGL_NATIVE_RENDERABLE)
             {
+                if (attribs[i + 1] != EGL_TRUE && attribs[i + 1] != EGL_FALSE
+                        && attribs[i + 1] != EGL_DONT_CARE)
+                {
+                    eplSetError(platform, EGL_BAD_ATTRIBUTE,
+                            "Invalid value 0x%04x for EGL_NATIVE_RENDERABLE", 
attribs[i + 1]);
+                    goto done;
+                }
+
                 nativeRenderable = attribs[i + 1];
             }
             else if (attribs[i] == EGL_NATIVE_VISUAL_TYPE)
-- 
2.51.0


++++++ 0027-Return-invalid-fd-on-syncobj-creation-failure.patch ++++++
>From aebd8761519a7592af1a5c0c60df576b803688ee Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Tue, 28 Apr 2026 11:31:21 -0400
Subject: [PATCH 27/38] Return invalid fd on syncobj creation failure

eplWlTimelinePointToSyncFD returns a file descriptor, where negative
values indicate failure. Returning EGL_FALSE from the drmSyncobjCreate
failure path produced integer 0, which is a valid file descriptor and
could be treated as a valid sync fd by callers.

Return -1 instead so a failure would correctly return an invalid fd.
---
 src/wayland/wayland-timeline.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wayland/wayland-timeline.c b/src/wayland/wayland-timeline.c
index 4b87c30..263554e 100644
--- a/src/wayland/wayland-timeline.c
+++ b/src/wayland/wayland-timeline.c
@@ -106,7 +106,7 @@ int eplWlTimelinePointToSyncFD(WlDisplayInstance *inst, 
WlTimeline *timeline)
                 gbm_device_get_fd(inst->gbmdev),
                 0, &tempobj) != 0)
     {
-        return EGL_FALSE;
+        return -1;
     }
 
     if 
(inst->platform->priv->drm.SyncobjTransfer(gbm_device_get_fd(inst->gbmdev),
-- 
2.51.0


++++++ 0028-Clean-up-Wayland-display-globals.patch ++++++
>From 42c2c5a36ee23020ff39ec8902da85573911861a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Tue, 28 Apr 2026 11:44:40 -0400
Subject: [PATCH 28/38] Clean up Wayland display globals

Display initialization creates presentation-time, fifo, and
commit-timing globals when frame pacing protocols are available, and it
duplicates the display extension string. The display-instance teardown
path only destroyed the dmabuf and syncobj globals, so those additional
globals and the extension string leaked for each initialized display.

Destroy all Wayland globals while the native display is still valid,
using reverse creation order, and free the duplicated extension string
with the rest of the display-owned heap data.
---
 src/wayland/wayland-display.c | 17 +++++++++++++++--
 1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/src/wayland/wayland-display.c b/src/wayland/wayland-display.c
index 0907003..6cd953e 100644
--- a/src/wayland/wayland-display.c
+++ b/src/wayland/wayland-display.c
@@ -1163,14 +1163,26 @@ static void eplWlDisplayInstanceFree(WlDisplayInstance 
*inst)
          */
         if (eplWlDisplayInstanceIsNativeValid(inst))
         {
-            if (inst->globals.dmabuf != NULL)
+            if (inst->globals.commit_timing != NULL)
             {
-                zwp_linux_dmabuf_v1_destroy(inst->globals.dmabuf);
+                
wp_commit_timing_manager_v1_destroy(inst->globals.commit_timing);
+            }
+            if (inst->globals.fifo != NULL)
+            {
+                wp_fifo_manager_v1_destroy(inst->globals.fifo);
+            }
+            if (inst->globals.presentation_time != NULL)
+            {
+                wp_presentation_destroy(inst->globals.presentation_time);
             }
             if (inst->globals.syncobj != NULL)
             {
                 wp_linux_drm_syncobj_manager_v1_destroy(inst->globals.syncobj);
             }
+            if (inst->globals.dmabuf != NULL)
+            {
+                zwp_linux_dmabuf_v1_destroy(inst->globals.dmabuf);
+            }
         }
 
         if (inst->own_display && inst->wdpy != NULL)
@@ -1191,6 +1203,7 @@ static void eplWlDisplayInstanceFree(WlDisplayInstance 
*inst)
         eplWlFormatListFree(inst->default_feedback);
         eplWlFormatListFree(inst->driver_formats);
         eplConfigListFree(inst->configs);
+        free(inst->extension_string);
 
         if (inst->platform != NULL)
         {
-- 
2.51.0


++++++ 0029-Use-common-cleanup-for-render-device-open-failures.patch ++++++
>From b2d8caf98ea38432863ddf1f0e0b15e772f2e4c2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Tue, 28 Apr 2026 11:54:28 -0400
Subject: [PATCH 29/38] Use common cleanup for render device open failures

When creating a display instance for an alternate render device, two
failure paths directly unrefed the partially initialized instance and
returned NULL. That bypassed the function's shared cleanup block,
leaving local resources such as the registry object, event queue, DRM
node string, or open fd to be skipped depending on where the failure
occurred.

Route those errors through the existing done label instead. The common
cleanup path now handles local resources and releases the partial
display instance consistently with the rest of
eplWlDisplayInstanceCreate.
---
 src/wayland/wayland-display.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/wayland/wayland-display.c b/src/wayland/wayland-display.c
index 6cd953e..d1347f8 100644
--- a/src/wayland/wayland-display.c
+++ b/src/wayland/wayland-display.c
@@ -996,16 +996,14 @@ WlDisplayInstance *eplWlDisplayInstanceCreate(EplDisplay 
*pdpy, EGLBoolean from_
             if (node == NULL)
             {
                 eplSetError(pdpy->platform, EGL_BAD_ACCESS, "Driver error: 
Can't find device node");
-                eplWlDisplayInstanceUnref(inst);
-                return NULL;
+                goto done;
             }
 
             drmFd = open(node, O_RDWR);
             if (drmFd < 0)
             {
                 eplSetError(pdpy->platform, EGL_BAD_ACCESS, "Can't open device 
node %s: %s", node, strerror(errno));
-                eplWlDisplayInstanceUnref(inst);
-                return NULL;
+                goto done;
             }
         }
 
-- 
2.51.0


++++++ 0030-Store-presentation-timestamps-in-nanoseconds.patch ++++++
>From 8cdf00aa4d304d0b65b5dada80052f36afbb4ae7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Tue, 28 Apr 2026 11:58:37 -0400
Subject: [PATCH 30/38] Store presentation timestamps in nanoseconds

The wp_presentation_feedback::presented handler combined the seconds and
nanoseconds fields with simple addition. last_present_timestamp is later
used as a nanosecond timestamp for commit timing, so storing seconds
plus nanoseconds produced values in mixed units and could schedule
future commits with incorrect timing.

Convert the 64-bit presentation seconds value to nanoseconds before
adding tv_nsec. This matches the discard path and keeps
last_present_timestamp in the units expected by the commit-timing
calculation.

Co-authored-by: Codex <[email protected]>
---
 src/wayland/wayland-surface.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/wayland/wayland-surface.c b/src/wayland/wayland-surface.c
index 8481c67..543ba34 100644
--- a/src/wayland/wayland-surface.c
+++ b/src/wayland/wayland-surface.c
@@ -1182,7 +1182,8 @@ static void on_wp_presentation_feedback_presented(void 
*userdata,
 
     assert(wfeedback == psurf->priv->current.presentation_feedback);
 
-    psurf->priv->current.last_present_timestamp = (((uint64_t) tv_sec_hi) << 
32 | tv_sec_lo) + tv_nsec;
+    psurf->priv->current.last_present_timestamp =
+        ((((uint64_t) tv_sec_hi) << 32) | tv_sec_lo) * 1000000000 + tv_nsec;
     psurf->priv->current.last_present_refresh = refresh;
 
     
wp_presentation_feedback_destroy(psurf->priv->current.presentation_feedback);
-- 
2.51.0


++++++ 0031-Accept-surface-feedback-tranches-whose-target-matche.patch ++++++
>From 18dcd8cec53ccebb273f2688fa7911ca9a4be4f8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Fri, 15 May 2026 07:50:54 -0400
Subject: [PATCH 31/38] Accept surface feedback tranches whose target matches
 our render device

OnSurfaceFeedbackTrancheDone is meant to keep the per-surface modifier
set from a tranche only when the tranche's target device is one of the
render devices the platform instance is rendering on. The condition was
inverted (`!=` instead of `==`), so a tranche whose target_device
matched our render device was rejected, and a tranche that did not
match was kept.

The end result was that per-surface tranches were dropped, and we fell
back to PickDefaultModifiers.

Flip the comparison so we keep tranches whose target_device matches one
of our render device ids, as the surrounding logic and the comments in
the function assume.
---
 src/wayland/wayland-surface.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wayland/wayland-surface.c b/src/wayland/wayland-surface.c
index 543ba34..fa4ffcd 100644
--- a/src/wayland/wayland-surface.c
+++ b/src/wayland/wayland-surface.c
@@ -368,7 +368,7 @@ static void OnSurfaceFeedbackTrancheDone(void *userdata,
     {
         for (i=0; i<psurf->priv->inst->render_device_id_count; i++)
         {
-            if (state->base.tranche_target_device != 
psurf->priv->inst->render_device_id[i])
+            if (state->base.tranche_target_device == 
psurf->priv->inst->render_device_id[i])
             {
                 use_tranche = EGL_TRUE;
                 break;
-- 
2.51.0


++++++ 0032-Always-reset-per-tranche-modifier-state-in-OnSurface.patch ++++++
>From 6ce955d008ee7abeca7881334b7e8c84cc6653cf Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Fri, 15 May 2026 10:41:13 -0400
Subject: [PATCH 32/38] Always reset per-tranche modifier state in
 OnSurfaceFeedbackTrancheDone

The per-tranche scratch arrays were only cleared inside the
`if (use_tranche)` branch, so a rejected tranche's TRUE entries survived
into the next tranche.

OnSurfaceFeedbackTrancheFormats only flips entries from FALSE to TRUE
for what the current tranche advertises, and it never clears entries
the tranche does not mention, so those leftover TRUE entries persisted.

If the next tranche was accepted, the leftover entries were copied into
modifiers_supported[] alongside its own modifiers, telling the driver
the surface accepts modifiers that only the rejected tranche had
advertised.

Clear the tranche arrays unconditionally after every tranche_done.
---
 src/wayland/wayland-surface.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/wayland/wayland-surface.c b/src/wayland/wayland-surface.c
index fa4ffcd..4e71e04 100644
--- a/src/wayland/wayland-surface.c
+++ b/src/wayland/wayland-surface.c
@@ -381,12 +381,16 @@ static void OnSurfaceFeedbackTrancheDone(void *userdata,
         for (i=0; i<psurf->priv->driver_format->num_modifiers; i++)
         {
             state->modifiers_supported[i] = 
state->tranche_modifiers_supported[i];
-            state->tranche_modifiers_supported[i] = EGL_FALSE;
         }
         state->linear_supported = state->tranche_linear_supported;
-        state->tranche_linear_supported = EGL_FALSE;
     }
 
+    for (i=0; i<psurf->priv->driver_format->num_modifiers; i++)
+    {
+        state->tranche_modifiers_supported[i] = EGL_FALSE;
+    }
+    state->tranche_linear_supported = EGL_FALSE;
+
     eplWlDmaBufFeedbackCommonTrancheDone(&state->base);
 }
 
-- 
2.51.0


++++++ 0033-Close-dma-buf-fd-on-swapchain-creation-failure.patch ++++++
>From d3fc2d3d5c01ef1daaed6335a4e6580e8461ba3b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Fri, 15 May 2026 07:51:44 -0400
Subject: [PATCH 33/38] Close dma-buf fd on swapchain creation failure

eplWlSwapChainCreate obtains a dma-buf fd from gbm_bo_get_fd() and then
hands it to PlatformImportColorBufferNVX, which does not take ownership
of the fd. If that import failed, the function jumped to the cleanup
label without closing the fd, leaking one file descriptor per failed
swapchain creation.

Track ownership explicitly and clear `dmabuf` once it has been handed
off, and close it at the cleanup label if it is still owned by this
function.
---
 src/wayland/wayland-swapchain.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/wayland/wayland-swapchain.c b/src/wayland/wayland-swapchain.c
index ee6f7b6..134fd08 100644
--- a/src/wayland/wayland-swapchain.c
+++ b/src/wayland/wayland-swapchain.c
@@ -398,7 +398,6 @@ WlSwapChain *eplWlSwapChainCreate(WlDisplayInstance *inst, 
struct wl_surface *ws
         // linear present buffers. We don't need to create any present buffers
         // yet -- we can do that in the first call to eglSwapBuffers.
         swapchain->modifier = DRM_FORMAT_MOD_LINEAR;
-        close(dmabuf);
     }
     else
     {
@@ -407,6 +406,9 @@ WlSwapChain *eplWlSwapChainCreate(WlDisplayInstance *inst, 
struct wl_surface *ws
         swapchain->modifier = gbm_bo_get_modifier(gbo);
         swapchain->current_back = SwapChainAppendPresentBuffer(inst, swapchain,
                 dmabuf, gbm_bo_get_stride(gbo), gbm_bo_get_offset(gbo, 0));
+        // SwapChainAppendPresentBuffer takes ownership of the fd in both the
+        // success and failure cases.
+        dmabuf = -1;
         if (swapchain->current_back == NULL)
         {
             goto done;
@@ -422,6 +424,10 @@ done:
         eplWlSwapChainDestroy(inst, swapchain);
         swapchain = NULL;
     }
+    if (dmabuf >= 0)
+    {
+        close(dmabuf);
+    }
     if (gbo != NULL)
     {
         gbm_bo_destroy(gbo);
-- 
2.51.0


++++++ 0034-Return-NULL-not-EGL_FALSE-from-eplWlHookQueryString.patch ++++++
>From 99cefc522fa4b331d7b5148f3e1b649db83776a2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Do=C4=9Fukan=20Korkmazt=C3=BCrk?= <[email protected]>
Date: Fri, 15 May 2026 07:53:51 -0400
Subject: [PATCH 34/38] Return NULL, not EGL_FALSE, from eplWlHookQueryString

eplWlHookQueryString returns `const char *`, but the
display-acquire-failure path returned `EGL_FALSE`. EGL_FALSE is 0 and
implicitly converts to a null pointer, so behavior is unchanged, but
the return value is misleading to readers and to static analysis.
Return NULL to match the declared type.
---
 src/wayland/wayland-display.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wayland/wayland-display.c b/src/wayland/wayland-display.c
index d1347f8..2058650 100644
--- a/src/wayland/wayland-display.c
+++ b/src/wayland/wayland-display.c
@@ -1219,7 +1219,7 @@ const char *eplWlHookQueryString(EGLDisplay edpy, EGLint 
name)
 
     if (pdpy == NULL)
     {
-        return EGL_FALSE;
+        return NULL;
     }
 
     if (name == EGL_EXTENSIONS)
-- 
2.51.0


++++++ 0035-Don-t-send-a-wl_surface-frame-request-if-the-swap-in.patch ++++++
>From c3d496d4971d78eb2c72fb7a841cce2741213484 Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <[email protected]>
Date: Mon, 18 May 2026 11:22:10 -0600
Subject: [PATCH 35/38] Don't send a wl_surface::frame request if the swap
 interval is zero

If the current swap interval is zero, then don't send a
wl_surface::frame request, and don't wait for or destroy the callback
from any previous frame.

Because the server can wait indefinitely before sending the callback
event, sending a wl_surface::frame request every frame can cause an
unbounded number of wl_callback objects to pile up in the server.
Destroying the wl_callback proxy in the client doesn't help with that,
because the server object still exists -- the protocol doesn't have a
request to tell the server that the client is no longer interested in
the callback.

In addition, if the swap interval is zero but there's still a pending
frame callback (which could happen if the previous swap had a nonzero
interval), then don't destroy the wl_callback, but don't wait on it
either.

That ensures that we never have more than one outstanding
wl_surface::frame callback. If the interval is nonzero, then we'll wait
for the callback before sending the next wl_surface::frame request. If
the swap interval is zero, then we don't wait for it, but we don't send
another wl_surface::frame request.

This should always give the correct result when the interval is zero,
because we'll never wait for the callback before committing the next
frame.

If the swap interval is always nonzero, then it'll also be correct,
because we'll always wait for the previous frame callback before
committing the next frame.

The one case that's slightly less correct is if the application changes
the swap interval from 1 to 0 and then back to 1. In that case, the
third frame will wait on the first frame to be presented, instead of the
second.

Still, that's better than risking resource exhaustion, and we can't get
proper FIFO semantics without wp_fifo anyway.
---
 src/wayland/wayland-surface.c | 25 ++++++++++++++++---------
 1 file changed, 16 insertions(+), 9 deletions(-)

diff --git a/src/wayland/wayland-surface.c b/src/wayland/wayland-surface.c
index 543ba34..6e8d55e 100644
--- a/src/wayland/wayland-surface.c
+++ b/src/wayland/wayland-surface.c
@@ -1387,11 +1387,7 @@ EGLBoolean eplWlSwapBuffers(EplPlatformData *plat, 
EplDisplay *pdpy,
             // presentation time.
             DiscardPresentationFeedback(psurf);
         }
-        if (psurf->priv->current.frame_callback != NULL)
-        {
-            wl_callback_destroy(psurf->priv->current.frame_callback);
-            psurf->priv->current.frame_callback = NULL;
-        }
+
         if (psurf->priv->current.last_swap_sync != NULL)
         {
             wl_callback_destroy(psurf->priv->current.last_swap_sync);
@@ -1400,7 +1396,6 @@ EGLBoolean eplWlSwapBuffers(EplPlatformData *plat, 
EplDisplay *pdpy,
     }
 
     assert(psurf->priv->current.presentation_feedback == NULL);
-    assert(psurf->priv->current.frame_callback == NULL);
     assert(psurf->priv->current.last_swap_sync == NULL);
 
     if (rects != NULL && n_rects > 0
@@ -1499,10 +1494,22 @@ EGLBoolean eplWlSwapBuffers(EplPlatformData *plat, 
EplDisplay *pdpy,
             wp_fifo_v1_wait_barrier(psurf->priv->current.fifo);
         }
     }
-    else
+    else if (swap_interval > 0)
     {
-        // If we don't have FIFO or presentation time support, then just
-        // request a frame callback.
+        /*
+         * If we don't have FIFO or presentation time support, then just
+         * request a frame callback.
+         *
+         * Only send that request if the swap interval is non-zero, though.
+         * Since the server can wait indefinitely before sending the response,
+         * and since wl_callback doesn't have a destroy request, sending a
+         * wl_surface::frame request every frame without waiting for them could
+         * create an unbounded number of pending wl_callbacks in the server.
+         */
+
+        // If swap_interval is nonzero, then we should have called
+        // WaitForPreviousFrames above, which would clear frame_callback.
+        assert(psurf->priv->current.frame_callback == NULL);
         psurf->priv->current.frame_callback = 
wl_surface_frame(psurf->priv->current.wsurf);
         if (psurf->priv->current.frame_callback != NULL)
         {
-- 
2.51.0


++++++ 0036-base-Add-DRM_FORMAT_XBGR16161616F-to-the-format-list.patch ++++++
>From 7e4484e8fa8fc1965cdd1a0b6ffabbefad8d9a9a Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <[email protected]>
Date: Tue, 23 Jun 2026 10:18:59 -0600
Subject: [PATCH 36/38] base: Add DRM_FORMAT_XBGR16161616F to the format list.

Add an EplFormatInfo entry for DRM_FORMAT_XBGR16161616F, so that
EGL_PRESENT_OPAQUE_EXT can work with DRM_FORMAT_ABGR16161616F.
---
 src/base/config-list.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/base/config-list.c b/src/base/config-list.c
index 19299e7..c132f50 100644
--- a/src/base/config-list.c
+++ b/src/base/config-list.c
@@ -42,6 +42,7 @@ const EplFormatInfo FORMAT_INFO_LIST[] =
     { DRM_FORMAT_ARGB2101010, 32, { 10, 10, 10, 2 }, { 20, 10, 0, 30 } },
     { DRM_FORMAT_ABGR2101010, 32, { 10, 10, 10, 2 }, { 0, 10, 20, 30 } },
     { DRM_FORMAT_ABGR16161616F, 64, { 16, 16, 16, 16 }, {  0, 16, 32, 48 } },
+    { DRM_FORMAT_XBGR16161616F, 64, { 16, 16, 16,  0 }, {  0, 16, 32,  0 } },
 
     /* 8 bpp RGB */
     { DRM_FORMAT_RGB332, 8, { 3, 3, 2, 0 }, { 5, 2, 0, 0 } },
-- 
2.51.0


++++++ 0037-Use-wl_array_init-instead-of-.size-0.patch ++++++
>From bb913bfb4146b31c5add9880521aa073295d3137 Mon Sep 17 00:00:00 2001
From: Ian Douglas Scott <[email protected]>
Date: Mon, 6 Jul 2026 08:11:37 -0700
Subject: [PATCH 37/38] Use `wl_array_init` instead of `.size = 0`

`wl_array_release` does not check `size` before calling `free`, so if
the `ptr` field is not also set to `0`, `wl_array_release` will
segfault in `FinishDefaultFeedback` freeing `WL_ARRAY_POISON_PTR`.

Signed-off-by: Ian Douglas Scott <[email protected]>
---
 src/wayland/wayland-dmabuf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wayland/wayland-dmabuf.c b/src/wayland/wayland-dmabuf.c
index 2f90880..90962a9 100644
--- a/src/wayland/wayland-dmabuf.c
+++ b/src/wayland/wayland-dmabuf.c
@@ -169,7 +169,7 @@ static WlFormatList 
*FinishDefaultFeedback(DefaultFeedbackState *state, dev_t *r
         if (tranche->target_device != state->base.main_device)
         {
             wl_array_release(&tranche->formats);
-            tranche->formats.size = 0;
+            wl_array_init(&tranche->formats);
             continue;
         }
 
-- 
2.51.0


++++++ 0038-wayland-Bound-protocol-override-separator-search.patch ++++++
>From 2023f59ba02af9cbdb3ad26678ccc95ffc777c5a Mon Sep 17 00:00:00 2001
From: Emre Cecanpunar <[email protected]>
Date: Thu, 16 Jul 2026 19:23:04 +0300
Subject: [PATCH 38/38] wayland: Bound protocol override separator search

FindNextStringToken returns a pointer and length for each comma-delimited 
token, but strchr can locate an equals sign in a later token. That makes the 
computed name length exceed the allocation accounted for during the first pass 
and can cause a heap buffer overflow in memcpy.

Limit the separator search to the current token length.

Signed-off-by: Emre Cecanpunar <[email protected]>
---
 src/wayland/wayland-display.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wayland/wayland-display.c b/src/wayland/wayland-display.c
index 2058650..fe23811 100644
--- a/src/wayland/wayland-display.c
+++ b/src/wayland/wayland-display.c
@@ -334,7 +334,7 @@ static ProtocolVersionOverride 
*ParseProtocolOverrideString(const char *str)
     num_tokens = 0;
     while (FindNextStringToken(&tok, &len, ","))
     {
-        const char *sep = strchr(tok, '=');
+        const char *sep = memchr(tok, '=', len);
         if (sep != NULL)
         {
             size_t namelen = (sep - tok);
-- 
2.51.0

Reply via email to