From b0e644cf2dbb0d97ac7885dd29297e7d2717915f5da43bb3e7a698ee2d8808ea Mon Sep 17 00:00:00 2001 From: Stefan Dirsch Date: Fri, 14 Jun 2024 13:57:58 +0000 Subject: [PATCH] Accepting request 1180929 from home:sndirsch:branches:X11:XOrg - Update to new feature release 24.1.0 --> https://docs.mesa3d.org/relnotes/24.1.0 - Some interesting highlights include: * NVIDIA Vulkan driver NVK is now considered ready for prime time. Distro packagers are now recommended to include `nouveau` in the `vulkan-drivers` list so that their users can have the option of using it instead of the proprietary NVIDIA driver. * Intel Vulkan driver Anv switched to truly asynchronous VM bind, and Xe support for error dump to debug GPU hangs was added. * Apple OpenGL driver Asahi has reached OpenGL 4.6 and OpenGL ES 3.2 support. * Broadcom Vulkan driver V3DV gained support for VK_KHR_dynamic_rendering. * Arm Mali OpenGL driver Panfrost was prepared for Gen10 (Gxxx), and Vulkan driver PanVK was modernised for better Midgard (Txxx) and Bifrost (Gxxx) support. * All Vulkan drivers have gained support for explicit synchronisation on Wayland and X11. - adjusted patches: * n_stop-iris-flicker.patch * python36-buildfix1.patch - supersedes patches: * 0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch * 0002-glx-fix-some-indentation.patch * 0003-glx-add-an-implicit-param-to-createScreen.patch * 0004-glx-pass-implicit-load-param-through-allocation.patch * 0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch * 0006-gbm-plumb-an-implicit-param-through-device-creation.patch * 0007-frontends-dri-plumb-an-implicit-param-through-screen.patch * 0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch * 0009-zink-don-t-print-error-messages-when-failing-an-impl.patch * 0010-glx-silence-more-implicit-load-zink-errors.patch - added libvdpau_d3d12 package - small cleanup in specfile OBS-URL: https://build.opensuse.org/request/show/1180929 OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/Mesa?expand=0&rev=1295 --- ...used-param-from-pipe_loader_sw_probe.patch | 61 -- 0002-glx-fix-some-indentation.patch | 34 -- ...dd-an-implicit-param-to-createScreen.patch | 107 ---- ...plicit-load-param-through-allocation.patch | 76 --- ...icit-param-through-createNewScreen-i.patch | 575 ------------------ ...plicit-param-through-device-creation.patch | 82 --- ...umb-an-implicit-param-through-screen.patch | 88 --- ...b-a-flag-for-implicit-driver-load-th.patch | 281 --------- ...-error-messages-when-failing-an-impl.patch | 327 ---------- ...lence-more-implicit-load-zink-errors.patch | 23 - Mesa.changes | 37 ++ Mesa.spec | 52 +- mesa-24.0.9.tar.xz | 3 - mesa-24.0.9.tar.xz.sig | Bin 310 -> 0 bytes mesa-24.1.0.tar.xz | 3 + mesa-24.1.0.tar.xz.sig | Bin 0 -> 310 bytes n_stop-iris-flicker.patch | 24 +- python36-buildfix1.patch | 20 +- 18 files changed, 89 insertions(+), 1704 deletions(-) delete mode 100644 0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch delete mode 100644 0002-glx-fix-some-indentation.patch delete mode 100644 0003-glx-add-an-implicit-param-to-createScreen.patch delete mode 100644 0004-glx-pass-implicit-load-param-through-allocation.patch delete mode 100644 0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch delete mode 100644 0006-gbm-plumb-an-implicit-param-through-device-creation.patch delete mode 100644 0007-frontends-dri-plumb-an-implicit-param-through-screen.patch delete mode 100644 0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch delete mode 100644 0009-zink-don-t-print-error-messages-when-failing-an-impl.patch delete mode 100644 0010-glx-silence-more-implicit-load-zink-errors.patch delete mode 100644 mesa-24.0.9.tar.xz delete mode 100644 mesa-24.0.9.tar.xz.sig create mode 100644 mesa-24.1.0.tar.xz create mode 100644 mesa-24.1.0.tar.xz.sig diff --git a/0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch b/0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch deleted file mode 100644 index 337d204..0000000 --- a/0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch +++ /dev/null @@ -1,61 +0,0 @@ -From 1b1ebd90a5b0edd70e2c548b64aeded9cac3e570 Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 09:15:11 -0400 -Subject: [PATCH 1/9] loader: delete unused param from - pipe_loader_sw_probe_dri() - ---- - src/gallium/auxiliary/pipe-loader/pipe_loader.h | 3 +-- - src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c | 4 ++-- - src/gallium/frontends/dri/kopper.c | 2 +- - 3 files changed, 4 insertions(+), 5 deletions(-) - -Index: mesa-24.0.3/src/gallium/auxiliary/pipe-loader/pipe_loader.h -=================================================================== ---- mesa-24.0.3.orig/src/gallium/auxiliary/pipe-loader/pipe_loader.h -+++ mesa-24.0.3/src/gallium/auxiliary/pipe-loader/pipe_loader.h -@@ -155,8 +155,7 @@ pipe_loader_sw_probe_dri(struct pipe_loa - * \sa pipe_loader_probe - */ - bool --pipe_loader_vk_probe_dri(struct pipe_loader_device **devs, -- const struct drisw_loader_funcs *drisw_lf); -+pipe_loader_vk_probe_dri(struct pipe_loader_device **devs); - - #ifdef HAVE_DRISW_KMS - /** -Index: mesa-24.0.3/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c -+++ mesa-24.0.3/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c -@@ -233,7 +233,7 @@ fail: - } - #ifdef HAVE_ZINK - bool --pipe_loader_vk_probe_dri(struct pipe_loader_device **devs, const struct drisw_loader_funcs *drisw_lf) -+pipe_loader_vk_probe_dri(struct pipe_loader_device **devs) - { - struct pipe_loader_sw_device *sdev = CALLOC_STRUCT(pipe_loader_sw_device); - int i; -@@ -246,7 +246,7 @@ pipe_loader_vk_probe_dri(struct pipe_loa - - for (i = 0; sdev->dd->winsys[i].name; i++) { - if (strcmp(sdev->dd->winsys[i].name, "dri") == 0) { -- sdev->ws = sdev->dd->winsys[i].create_winsys_dri(drisw_lf); -+ sdev->ws = sdev->dd->winsys[i].create_winsys_dri(NULL); - break; - } - } -Index: mesa-24.0.3/src/gallium/frontends/dri/kopper.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/kopper.c -+++ mesa-24.0.3/src/gallium/frontends/dri/kopper.c -@@ -128,7 +128,7 @@ kopper_init_screen(struct dri_screen *sc - if (screen->fd != -1) - success = pipe_loader_drm_probe_fd(&screen->dev, screen->fd, false); - else -- success = pipe_loader_vk_probe_dri(&screen->dev, NULL); -+ success = pipe_loader_vk_probe_dri(&screen->dev); - - if (success) - pscreen = pipe_loader_create_screen(screen->dev); diff --git a/0002-glx-fix-some-indentation.patch b/0002-glx-fix-some-indentation.patch deleted file mode 100644 index cace36e..0000000 --- a/0002-glx-fix-some-indentation.patch +++ /dev/null @@ -1,34 +0,0 @@ -From 647f6a7e123726d306440d54a22880e67ab31aa8 Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 09:20:25 -0400 -Subject: [PATCH 2/9] glx: fix some indentation - -ifdefs are hard ---- - src/glx/glxext.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -Index: mesa-24.0.3/src/glx/glxext.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/glxext.c -+++ mesa-24.0.3/src/glx/glxext.c -@@ -786,16 +786,16 @@ AllocAndFetchScreenConfigs(Display * dpy - psc = priv->dri3Display->createScreen(i, priv); - #endif /* HAVE_DRI3 */ - if (psc == NULL && priv->dri2Display) -- psc = priv->dri2Display->createScreen(i, priv); -+ psc = priv->dri2Display->createScreen(i, priv); - #endif /* GLX_USE_DRM */ - - #ifdef GLX_USE_WINDOWSGL - if (psc == NULL && priv->windowsdriDisplay) -- psc = priv->windowsdriDisplay->createScreen(i, priv); -+ psc = priv->windowsdriDisplay->createScreen(i, priv); - #endif - - if (psc == NULL && priv->driswDisplay) -- psc = priv->driswDisplay->createScreen(i, priv); -+ psc = priv->driswDisplay->createScreen(i, priv); - #endif /* GLX_DIRECT_RENDERING && !GLX_USE_APPLEGL */ - - bool indirect = false; diff --git a/0003-glx-add-an-implicit-param-to-createScreen.patch b/0003-glx-add-an-implicit-param-to-createScreen.patch deleted file mode 100644 index 9a14ba3..0000000 --- a/0003-glx-add-an-implicit-param-to-createScreen.patch +++ /dev/null @@ -1,107 +0,0 @@ -From 2dedd2e26dce587e1efe8250f8f2da60db906071 Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 09:36:57 -0400 -Subject: [PATCH 3/9] glx: add an 'implicit' param to createScreen - ---- - src/glx/dri2_glx.c | 2 +- - src/glx/dri3_glx.c | 2 +- - src/glx/drisw_glx.c | 2 +- - src/glx/driwindows_glx.c | 2 +- - src/glx/glxclient.h | 2 +- - src/glx/glxext.c | 8 ++++---- - 6 files changed, 9 insertions(+), 9 deletions(-) - -Index: mesa-24.0.3/src/glx/dri2_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/dri2_glx.c -+++ mesa-24.0.3/src/glx/dri2_glx.c -@@ -1001,7 +1001,7 @@ static const struct glx_screen_vtable dr - }; - - static struct glx_screen * --dri2CreateScreen(int screen, struct glx_display * priv) -+dri2CreateScreen(int screen, struct glx_display * priv, bool implicit) - { - const __DRIconfig **driver_configs; - const __DRIextension **extensions; -Index: mesa-24.0.3/src/glx/dri3_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/dri3_glx.c -+++ mesa-24.0.3/src/glx/dri3_glx.c -@@ -789,7 +789,7 @@ static const struct glx_screen_vtable dr - */ - - static struct glx_screen * --dri3_create_screen(int screen, struct glx_display * priv) -+dri3_create_screen(int screen, struct glx_display * priv, bool implicit) - { - xcb_connection_t *c = XGetXCBConnection(priv->dpy); - const __DRIconfig **driver_configs; -Index: mesa-24.0.3/src/glx/drisw_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/drisw_glx.c -+++ mesa-24.0.3/src/glx/drisw_glx.c -@@ -1055,7 +1055,7 @@ driswCreateScreenDriver(int screen, stru - } - - static struct glx_screen * --driswCreateScreen(int screen, struct glx_display *priv) -+driswCreateScreen(int screen, struct glx_display *priv, bool implicit) - { - const struct drisw_display *pdpyp = (struct drisw_display *)priv->driswDisplay; - if (pdpyp->zink && !debug_get_bool_option("LIBGL_KOPPER_DISABLE", false)) { -Index: mesa-24.0.3/src/glx/driwindows_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/driwindows_glx.c -+++ mesa-24.0.3/src/glx/driwindows_glx.c -@@ -461,7 +461,7 @@ driwindowsMapConfigs(struct glx_display - } - - static struct glx_screen * --driwindowsCreateScreen(int screen, struct glx_display *priv) -+driwindowsCreateScreen(int screen, struct glx_display *priv, bool implicit) - { - __GLXDRIscreen *psp; - struct driwindows_screen *psc; -Index: mesa-24.0.3/src/glx/glxclient.h -=================================================================== ---- mesa-24.0.3.orig/src/glx/glxclient.h -+++ mesa-24.0.3/src/glx/glxclient.h -@@ -85,7 +85,7 @@ struct __GLXDRIdisplayRec - */ - void (*destroyDisplay) (__GLXDRIdisplay * display); - -- struct glx_screen *(*createScreen)(int screen, struct glx_display * priv); -+ struct glx_screen *(*createScreen)(int screen, struct glx_display * priv, bool implicit); - }; - - struct __GLXDRIscreenRec { -Index: mesa-24.0.3/src/glx/glxext.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/glxext.c -+++ mesa-24.0.3/src/glx/glxext.c -@@ -783,19 +783,19 @@ AllocAndFetchScreenConfigs(Display * dpy - #if defined(GLX_USE_DRM) - #if defined(HAVE_DRI3) - if (priv->dri3Display) -- psc = priv->dri3Display->createScreen(i, priv); -+ psc = priv->dri3Display->createScreen(i, priv, false); - #endif /* HAVE_DRI3 */ - if (psc == NULL && priv->dri2Display) -- psc = priv->dri2Display->createScreen(i, priv); -+ psc = priv->dri2Display->createScreen(i, priv, false); - #endif /* GLX_USE_DRM */ - - #ifdef GLX_USE_WINDOWSGL - if (psc == NULL && priv->windowsdriDisplay) -- psc = priv->windowsdriDisplay->createScreen(i, priv); -+ psc = priv->windowsdriDisplay->createScreen(i, priv, false); - #endif - - if (psc == NULL && priv->driswDisplay) -- psc = priv->driswDisplay->createScreen(i, priv); -+ psc = priv->driswDisplay->createScreen(i, priv, false); - #endif /* GLX_DIRECT_RENDERING && !GLX_USE_APPLEGL */ - - bool indirect = false; diff --git a/0004-glx-pass-implicit-load-param-through-allocation.patch b/0004-glx-pass-implicit-load-param-through-allocation.patch deleted file mode 100644 index 667fb79..0000000 --- a/0004-glx-pass-implicit-load-param-through-allocation.patch +++ /dev/null @@ -1,76 +0,0 @@ -From e7c5f94a79ff0e545dfdc95703a541a0d43d739f Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 09:42:06 -0400 -Subject: [PATCH 4/9] glx: pass implicit load param through allocation - ---- - src/glx/glxext.c | 14 +++++++------- - 1 file changed, 7 insertions(+), 7 deletions(-) - -Index: mesa-24.0.5/src/glx/glxext.c -=================================================================== ---- mesa-24.0.5.orig/src/glx/glxext.c -+++ mesa-24.0.5/src/glx/glxext.c -@@ -763,7 +763,7 @@ glx_screen_cleanup(struct glx_screen *ps - ** If that works then fetch the per screen configs data. - */ - static Bool --AllocAndFetchScreenConfigs(Display * dpy, struct glx_display * priv, Bool zink) -+AllocAndFetchScreenConfigs(Display * dpy, struct glx_display * priv, Bool zink, Bool implicit) - { - struct glx_screen *psc; - GLint i, screens; -@@ -783,19 +783,19 @@ AllocAndFetchScreenConfigs(Display * dpy - #if defined(GLX_USE_DRM) - #if defined(HAVE_DRI3) - if (priv->dri3Display) -- psc = priv->dri3Display->createScreen(i, priv, false); -+ psc = priv->dri3Display->createScreen(i, priv, implicit); - #endif /* HAVE_DRI3 */ - if (psc == NULL && priv->dri2Display) -- psc = priv->dri2Display->createScreen(i, priv, false); -+ psc = priv->dri2Display->createScreen(i, priv, implicit); - #endif /* GLX_USE_DRM */ - - #ifdef GLX_USE_WINDOWSGL - if (psc == NULL && priv->windowsdriDisplay) -- psc = priv->windowsdriDisplay->createScreen(i, priv, false); -+ psc = priv->windowsdriDisplay->createScreen(i, priv, implicit); - #endif - - if (psc == NULL && priv->driswDisplay) -- psc = priv->driswDisplay->createScreen(i, priv, false); -+ psc = priv->driswDisplay->createScreen(i, priv, psc == GLX_LOADER_USE_ZINK ? false : implicit); - #endif /* GLX_DIRECT_RENDERING && !GLX_USE_APPLEGL */ - - bool indirect = false; -@@ -930,14 +930,14 @@ __glXInitialize(Display * dpy) - } - #endif - -- if (!AllocAndFetchScreenConfigs(dpy, dpyPriv, zink | try_zink)) { -+ if (!AllocAndFetchScreenConfigs(dpy, dpyPriv, zink | try_zink, zink || try_zink ? try_zink : !env)) { - Bool fail = True; - #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL) - if (try_zink) { - free(dpyPriv->screens); - dpyPriv->driswDisplay->destroyDisplay(dpyPriv->driswDisplay); - dpyPriv->driswDisplay = driswCreateDisplay(dpy, TRY_ZINK_NO); -- fail = !AllocAndFetchScreenConfigs(dpy, dpyPriv, False); -+ fail = !AllocAndFetchScreenConfigs(dpy, dpyPriv, False, true); - } - #endif - if (fail) { -Index: mesa-24.0.5/src/glx/glxclient.h -=================================================================== ---- mesa-24.0.5.orig/src/glx/glxclient.h -+++ mesa-24.0.5/src/glx/glxclient.h -@@ -78,6 +78,8 @@ typedef struct __GLXDRIdisplayRec __GLXD - typedef struct __GLXDRIscreenRec __GLXDRIscreen; - typedef struct __GLXDRIdrawableRec __GLXDRIdrawable; - -+#define GLX_LOADER_USE_ZINK ((struct glx_screen *)(uintptr_t)-1) -+ - struct __GLXDRIdisplayRec - { - /** diff --git a/0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch b/0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch deleted file mode 100644 index f84652a..0000000 --- a/0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch +++ /dev/null @@ -1,575 +0,0 @@ -From 6b3f6a6e0b1e2cba749f8c38b087a59eee3f4efa Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 10:00:54 -0400 -Subject: [PATCH 5/9] dri: plumb a 'implicit' param through createNewScreen - interfaces - ---- - include/GL/internal/dri_interface.h | 33 ++++++++++++++++-- - include/GL/internal/mesa_interface.h | 5 ++- - src/egl/drivers/dri2/egl_dri2.c | 20 +++++------ - src/gallium/frontends/dri/dri2.c | 6 ++-- - src/gallium/frontends/dri/dri_util.c | 52 ++++++++++++++++++++-------- - src/gallium/frontends/dri/dri_util.h | 5 +++ - src/gallium/frontends/dri/drisw.c | 3 +- - src/gallium/frontends/dri/kopper.c | 3 +- - src/gbm/backends/dri/gbm_dri.c | 16 ++++----- - src/glx/dri2_glx.c | 8 ++--- - src/glx/dri3_glx.c | 12 +++---- - src/glx/drisw_glx.c | 14 ++++---- - 12 files changed, 120 insertions(+), 57 deletions(-) - -Index: mesa-24.0.3/include/GL/internal/dri_interface.h -=================================================================== ---- mesa-24.0.3.orig/include/GL/internal/dri_interface.h -+++ mesa-24.0.3/include/GL/internal/dri_interface.h -@@ -913,7 +913,7 @@ struct __DRIframebufferRec { - * extension. Version 1 is required by the X server, and version 3 is used. - */ - #define __DRI_SWRAST "DRI_SWRast" --#define __DRI_SWRAST_VERSION 4 -+#define __DRI_SWRAST_VERSION 5 - - struct __DRIswrastExtensionRec { - __DRIextension base; -@@ -961,6 +961,18 @@ struct __DRIswrastExtensionRec { - const __DRIconfig ***driver_configs, - void *loaderPrivate); - -+ /** -+ * createNewScreen() with the driver extensions passed in and implicit load flag. -+ * -+ * \since version 6 -+ */ -+ __DRIscreen *(*createNewScreen3)(int screen, -+ const __DRIextension **loader_extensions, -+ const __DRIextension **driver_extensions, -+ const __DRIconfig ***driver_configs, -+ bool implicit, -+ void *loaderPrivate); -+ - }; - - /** Common DRI function definitions, shared among DRI2 and Image extensions -@@ -972,6 +984,13 @@ typedef __DRIscreen * - const __DRIextension **driver_extensions, - const __DRIconfig ***driver_configs, - void *loaderPrivate); -+typedef __DRIscreen * -+(*__DRIcreateNewScreen3Func)(int screen, int fd, -+ const __DRIextension **extensions, -+ const __DRIextension **driver_extensions, -+ const __DRIconfig ***driver_configs, -+ bool implicit, -+ void *loaderPrivate); - - typedef __DRIdrawable * - (*__DRIcreateNewDrawableFunc)(__DRIscreen *screen, -@@ -1107,7 +1126,7 @@ struct __DRIdri2LoaderExtensionRec { - * constructors for DRI2. The X server uses up to version 4. - */ - #define __DRI_DRI2 "DRI_DRI2" --#define __DRI_DRI2_VERSION 4 -+#define __DRI_DRI2_VERSION 5 - - #define __DRI_API_OPENGL 0 /**< OpenGL compatibility profile */ - #define __DRI_API_GLES 1 /**< OpenGL ES 1.x */ -@@ -1226,6 +1245,13 @@ struct __DRIdri2ExtensionRec { - * \since version 4 - */ - __DRIcreateNewScreen2Func createNewScreen2; -+ -+ /** -+ * createNewScreen with the driver's extension list passed in and implicit load flag. -+ * -+ * \since version 5 -+ */ -+ __DRIcreateNewScreen3Func createNewScreen3; - }; - - -@@ -2083,7 +2109,7 @@ struct __DRIimageLoaderExtensionRec { - */ - - #define __DRI_IMAGE_DRIVER "DRI_IMAGE_DRIVER" --#define __DRI_IMAGE_DRIVER_VERSION 1 -+#define __DRI_IMAGE_DRIVER_VERSION 2 - - struct __DRIimageDriverExtensionRec { - __DRIextension base; -@@ -2093,6 +2119,7 @@ struct __DRIimageDriverExtensionRec { - __DRIcreateNewDrawableFunc createNewDrawable; - __DRIcreateContextAttribsFunc createContextAttribs; - __DRIgetAPIMaskFunc getAPIMask; -+ __DRIcreateNewScreen3Func createNewScreen3; - }; - - /** -Index: mesa-24.0.3/include/GL/internal/mesa_interface.h -=================================================================== ---- mesa-24.0.3.orig/include/GL/internal/mesa_interface.h -+++ mesa-24.0.3/include/GL/internal/mesa_interface.h -@@ -33,7 +33,7 @@ - typedef struct __DRImesaCoreExtensionRec __DRImesaCoreExtension; - - #define __DRI_MESA "DRI_Mesa" --#define __DRI_MESA_VERSION 1 -+#define __DRI_MESA_VERSION 2 - - struct dri_screen; - -@@ -63,6 +63,9 @@ struct __DRImesaCoreExtensionRec { - const __DRIconfig **(*initScreen)(struct dri_screen *screen); - - int (*queryCompatibleRenderOnlyDeviceFd)(int kms_only_fd); -+ -+ /* version 2 */ -+ __DRIcreateNewScreen3Func createNewScreen3; - }; - - #endif /* MESA_INTERFACE_H */ -Index: mesa-24.0.3/src/egl/drivers/dri2/egl_dri2.c -=================================================================== ---- mesa-24.0.3.orig/src/egl/drivers/dri2/egl_dri2.c -+++ mesa-24.0.3/src/egl/drivers/dri2/egl_dri2.c -@@ -701,8 +701,8 @@ const __DRIimageLookupExtension image_lo - - static const struct dri_extension_match dri3_driver_extensions[] = { - {__DRI_CORE, 1, offsetof(struct dri2_egl_display, core), false}, -- {__DRI_MESA, 1, offsetof(struct dri2_egl_display, mesa), false}, -- {__DRI_IMAGE_DRIVER, 1, offsetof(struct dri2_egl_display, image_driver), -+ {__DRI_MESA, 2, offsetof(struct dri2_egl_display, mesa), false}, -+ {__DRI_IMAGE_DRIVER, 2, offsetof(struct dri2_egl_display, image_driver), - false}, - {__DRI_CONFIG_OPTIONS, 2, offsetof(struct dri2_egl_display, configOptions), - true}, -@@ -710,8 +710,8 @@ static const struct dri_extension_match - - static const struct dri_extension_match dri2_driver_extensions[] = { - {__DRI_CORE, 1, offsetof(struct dri2_egl_display, core), false}, -- {__DRI_MESA, 1, offsetof(struct dri2_egl_display, mesa), false}, -- {__DRI_DRI2, 4, offsetof(struct dri2_egl_display, dri2), false}, -+ {__DRI_MESA, 2, offsetof(struct dri2_egl_display, mesa), false}, -+ {__DRI_DRI2, 5, offsetof(struct dri2_egl_display, dri2), false}, - {__DRI_CONFIG_OPTIONS, 2, offsetof(struct dri2_egl_display, configOptions), - true}, - }; -@@ -724,8 +724,8 @@ static const struct dri_extension_match - - static const struct dri_extension_match swrast_driver_extensions[] = { - {__DRI_CORE, 1, offsetof(struct dri2_egl_display, core), false}, -- {__DRI_MESA, 1, offsetof(struct dri2_egl_display, mesa), false}, -- {__DRI_SWRAST, 4, offsetof(struct dri2_egl_display, swrast), false}, -+ {__DRI_MESA, 2, offsetof(struct dri2_egl_display, mesa), false}, -+ {__DRI_SWRAST, 5, offsetof(struct dri2_egl_display, swrast), false}, - {__DRI_CONFIG_OPTIONS, 2, offsetof(struct dri2_egl_display, configOptions), - true}, - }; -@@ -1013,18 +1013,18 @@ dri2_create_screen(_EGLDisplay *disp) - * will not crash. - */ - if (strcmp(dri2_dpy->driver_name, driver_name_display_gpu) == 0) { -- dri2_dpy->dri_screen_display_gpu = dri2_dpy->mesa->createNewScreen( -+ dri2_dpy->dri_screen_display_gpu = dri2_dpy->mesa->createNewScreen3( - 0, dri2_dpy->fd_display_gpu, dri2_dpy->loader_extensions, -- dri2_dpy->driver_extensions, &dri2_dpy->driver_configs, disp); -+ dri2_dpy->driver_extensions, &dri2_dpy->driver_configs, false, disp); - } - free(driver_name_display_gpu); - } - } - - int screen_fd = dri2_dpy->swrast ? -1 : dri2_dpy->fd_render_gpu; -- dri2_dpy->dri_screen_render_gpu = dri2_dpy->mesa->createNewScreen( -+ dri2_dpy->dri_screen_render_gpu = dri2_dpy->mesa->createNewScreen3( - 0, screen_fd, dri2_dpy->loader_extensions, dri2_dpy->driver_extensions, -- &dri2_dpy->driver_configs, disp); -+ &dri2_dpy->driver_configs, false, disp); - - if (dri2_dpy->dri_screen_render_gpu == NULL) { - _eglLog(_EGL_WARNING, "egl: failed to create dri2 screen"); -Index: mesa-24.0.3/src/gallium/frontends/dri/dri2.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/dri2.c -+++ mesa-24.0.3/src/gallium/frontends/dri/dri2.c -@@ -2484,12 +2484,13 @@ dri_query_compatible_render_only_device_ - } - - static const struct __DRImesaCoreExtensionRec mesaCoreExtension = { -- .base = { __DRI_MESA, 1 }, -+ .base = { __DRI_MESA, 2 }, - .version_string = MESA_INTERFACE_VERSION_STRING, - .createNewScreen = driCreateNewScreen2, - .createContext = driCreateContextAttribs, - .initScreen = dri2_init_screen, - .queryCompatibleRenderOnlyDeviceFd = dri_query_compatible_render_only_device_fd, -+ .createNewScreen3 = driCreateNewScreen3, - }; - - /* This is the table of extensions that the loader will dlsym() for. */ -@@ -2503,11 +2504,12 @@ const __DRIextension *galliumdrm_driver_ - }; - - static const struct __DRImesaCoreExtensionRec swkmsMesaCoreExtension = { -- .base = { __DRI_MESA, 1 }, -+ .base = { __DRI_MESA, 2 }, - .version_string = MESA_INTERFACE_VERSION_STRING, - .createNewScreen = driCreateNewScreen2, - .createContext = driCreateContextAttribs, - .initScreen = dri_swrast_kms_init_screen, -+ .createNewScreen3 = driCreateNewScreen3, - }; - - const __DRIextension *dri_swrast_kms_driver_extensions[] = { -Index: mesa-24.0.3/src/gallium/frontends/dri/dri_util.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/dri_util.c -+++ mesa-24.0.3/src/gallium/frontends/dri/dri_util.c -@@ -96,10 +96,10 @@ setupLoaderExtensions(struct dri_screen - * Display. - */ - __DRIscreen * --driCreateNewScreen2(int scrn, int fd, -+driCreateNewScreen3(int scrn, int fd, - const __DRIextension **loader_extensions, - const __DRIextension **driver_extensions, -- const __DRIconfig ***driver_configs, void *data) -+ const __DRIconfig ***driver_configs, bool implicit, void *data) - { - static const __DRIextension *emptyExtensionList[] = { NULL }; - struct dri_screen *screen; -@@ -172,14 +172,25 @@ driCreateNewScreen2(int scrn, int fd, - return opaque_dri_screen(screen); - } - -+__DRIscreen * -+driCreateNewScreen2(int scrn, int fd, -+ const __DRIextension **loader_extensions, -+ const __DRIextension **driver_extensions, -+ const __DRIconfig ***driver_configs, void *data) -+{ -+ return driCreateNewScreen3(scrn, fd, loader_extensions, -+ driver_extensions, -+ driver_configs, false, data); -+} -+ - static __DRIscreen * - dri2CreateNewScreen(int scrn, int fd, - const __DRIextension **extensions, - const __DRIconfig ***driver_configs, void *data) - { -- return driCreateNewScreen2(scrn, fd, extensions, -+ return driCreateNewScreen3(scrn, fd, extensions, - galliumdrm_driver_extensions, -- driver_configs, data); -+ driver_configs, false, data); - } - - static __DRIscreen * -@@ -187,9 +198,9 @@ swkmsCreateNewScreen(int scrn, int fd, - const __DRIextension **extensions, - const __DRIconfig ***driver_configs, void *data) - { -- return driCreateNewScreen2(scrn, fd, extensions, -+ return driCreateNewScreen3(scrn, fd, extensions, - dri_swrast_kms_driver_extensions, -- driver_configs, data); -+ driver_configs, false, data); - } - - /** swrast driver createNewScreen entrypoint. */ -@@ -197,9 +208,9 @@ static __DRIscreen * - driSWRastCreateNewScreen(int scrn, const __DRIextension **extensions, - const __DRIconfig ***driver_configs, void *data) - { -- return driCreateNewScreen2(scrn, -1, extensions, -+ return driCreateNewScreen3(scrn, -1, extensions, - galliumsw_driver_extensions, -- driver_configs, data); -+ driver_configs, false, data); - } - - static __DRIscreen * -@@ -207,8 +218,17 @@ driSWRastCreateNewScreen2(int scrn, cons - const __DRIextension **driver_extensions, - const __DRIconfig ***driver_configs, void *data) - { -- return driCreateNewScreen2(scrn, -1, extensions, driver_extensions, -- driver_configs, data); -+ return driCreateNewScreen3(scrn, -1, extensions, driver_extensions, -+ driver_configs, false, data); -+} -+ -+static __DRIscreen * -+driSWRastCreateNewScreen3(int scrn, const __DRIextension **extensions, -+ const __DRIextension **driver_extensions, -+ const __DRIconfig ***driver_configs, bool implicit, void *data) -+{ -+ return driCreateNewScreen3(scrn, -1, extensions, driver_extensions, -+ driver_configs, implicit, data); - } - - /** -@@ -878,7 +898,7 @@ const __DRIcoreExtension driCoreExtensio - - /** DRI2 interface */ - const __DRIdri2Extension driDRI2Extension = { -- .base = { __DRI_DRI2, 4 }, -+ .base = { __DRI_DRI2, 5 }, - - .createNewScreen = dri2CreateNewScreen, - .createNewDrawable = driCreateNewDrawable, -@@ -889,10 +909,11 @@ const __DRIdri2Extension driDRI2Extensio - .releaseBuffer = dri2ReleaseBuffer, - .createContextAttribs = driCreateContextAttribs, - .createNewScreen2 = driCreateNewScreen2, -+ .createNewScreen3 = driCreateNewScreen3, - }; - - const __DRIdri2Extension swkmsDRI2Extension = { -- .base = { __DRI_DRI2, 4 }, -+ .base = { __DRI_DRI2, 5 }, - - .createNewScreen = swkmsCreateNewScreen, - .createNewDrawable = driCreateNewDrawable, -@@ -903,18 +924,20 @@ const __DRIdri2Extension swkmsDRI2Extens - .releaseBuffer = dri2ReleaseBuffer, - .createContextAttribs = driCreateContextAttribs, - .createNewScreen2 = driCreateNewScreen2, -+ .createNewScreen3 = driCreateNewScreen3, - }; - - #endif - - const __DRIswrastExtension driSWRastExtension = { -- .base = { __DRI_SWRAST, 4 }, -+ .base = { __DRI_SWRAST, 5 }, - - .createNewScreen = driSWRastCreateNewScreen, - .createNewDrawable = driCreateNewDrawable, - .createNewContextForAPI = driCreateNewContextForAPI, - .createContextAttribs = driCreateContextAttribs, - .createNewScreen2 = driSWRastCreateNewScreen2, -+ .createNewScreen3 = driSWRastCreateNewScreen3, - }; - - const __DRI2configQueryExtension dri2ConfigQueryExtension = { -@@ -1117,10 +1140,11 @@ driImageFormatToGLFormat(uint32_t image_ - - /** Image driver interface */ - const __DRIimageDriverExtension driImageDriverExtension = { -- .base = { __DRI_IMAGE_DRIVER, 1 }, -+ .base = { __DRI_IMAGE_DRIVER, 2 }, - - .createNewScreen2 = driCreateNewScreen2, - .createNewDrawable = driCreateNewDrawable, - .getAPIMask = driGetAPIMask, - .createContextAttribs = driCreateContextAttribs, -+ .createNewScreen3 = driCreateNewScreen3, - }; -Index: mesa-24.0.3/src/gallium/frontends/dri/dri_util.h -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/dri_util.h -+++ mesa-24.0.3/src/gallium/frontends/dri/dri_util.h -@@ -104,6 +104,11 @@ struct __DriverContextConfig { - #define __DRIVER_CONTEXT_ATTRIB_PROTECTED (1 << 4) - - __DRIscreen * -+driCreateNewScreen3(int scrn, int fd, -+ const __DRIextension **loader_extensions, -+ const __DRIextension **driver_extensions, -+ const __DRIconfig ***driver_configs, bool implicit, void *data); -+__DRIscreen * - driCreateNewScreen2(int scrn, int fd, - const __DRIextension **loader_extensions, - const __DRIextension **driver_extensions, -Index: mesa-24.0.3/src/gallium/frontends/dri/drisw.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/drisw.c -+++ mesa-24.0.3/src/gallium/frontends/dri/drisw.c -@@ -616,11 +616,12 @@ const __DRIcopySubBufferExtension driSWC - }; - - static const struct __DRImesaCoreExtensionRec mesaCoreExtension = { -- .base = { __DRI_MESA, 1 }, -+ .base = { __DRI_MESA, 2 }, - .version_string = MESA_INTERFACE_VERSION_STRING, - .createNewScreen = driCreateNewScreen2, - .createContext = driCreateContextAttribs, - .initScreen = drisw_init_screen, -+ .createNewScreen3 = driCreateNewScreen3, - }; - - /* This is the table of extensions that the loader will dlsym() for. */ -Index: mesa-24.0.3/src/gallium/frontends/dri/kopper.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/kopper.c -+++ mesa-24.0.3/src/gallium/frontends/dri/kopper.c -@@ -963,11 +963,12 @@ const __DRIkopperExtension driKopperExte - }; - - static const struct __DRImesaCoreExtensionRec mesaCoreExtension = { -- .base = { __DRI_MESA, 1 }, -+ .base = { __DRI_MESA, 2 }, - .version_string = MESA_INTERFACE_VERSION_STRING, - .createNewScreen = driCreateNewScreen2, - .createContext = driCreateContextAttribs, - .initScreen = kopper_init_screen, -+ .createNewScreen3 = driCreateNewScreen3, - }; - - const __DRIextension *galliumvk_driver_extensions[] = { -Index: mesa-24.0.3/src/gbm/backends/dri/gbm_dri.c -=================================================================== ---- mesa-24.0.3.orig/src/gbm/backends/dri/gbm_dri.c -+++ mesa-24.0.3/src/gbm/backends/dri/gbm_dri.c -@@ -250,14 +250,14 @@ static struct dri_extension_match dri_co - - static struct dri_extension_match gbm_dri_device_extensions[] = { - { __DRI_CORE, 1, offsetof(struct gbm_dri_device, core), false }, -- { __DRI_MESA, 1, offsetof(struct gbm_dri_device, mesa), false }, -- { __DRI_IMAGE_DRIVER, 1, offsetof(struct gbm_dri_device, image_driver), false }, -+ { __DRI_MESA, 2, offsetof(struct gbm_dri_device, mesa), false }, -+ { __DRI_IMAGE_DRIVER, 2, offsetof(struct gbm_dri_device, image_driver), false }, - }; - - static struct dri_extension_match gbm_swrast_device_extensions[] = { - { __DRI_CORE, 1, offsetof(struct gbm_dri_device, core), false }, -- { __DRI_MESA, 1, offsetof(struct gbm_dri_device, mesa), false }, -- { __DRI_SWRAST, 4, offsetof(struct gbm_dri_device, swrast), false }, -+ { __DRI_MESA, 2, offsetof(struct gbm_dri_device, mesa), false }, -+ { __DRI_SWRAST, 5, offsetof(struct gbm_dri_device, swrast), false }, - { __DRI_KOPPER, 1, offsetof(struct gbm_dri_device, kopper), true }, - }; - -@@ -315,10 +315,10 @@ dri_screen_create_for_driver(struct gbm_ - - dri->driver_extensions = extensions; - dri->loader_extensions = gbm_dri_screen_extensions; -- dri->screen = dri->mesa->createNewScreen(0, swrast ? -1 : dri->base.v0.fd, -- dri->loader_extensions, -- dri->driver_extensions, -- &dri->driver_configs, dri); -+ dri->screen = dri->mesa->createNewScreen3(0, swrast ? -1 : dri->base.v0.fd, -+ dri->loader_extensions, -+ dri->driver_extensions, -+ &dri->driver_configs, false, dri); - if (dri->screen == NULL) - goto close_driver; - -Index: mesa-24.0.3/src/glx/dri2_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/dri2_glx.c -+++ mesa-24.0.3/src/glx/dri2_glx.c -@@ -1064,17 +1064,17 @@ dri2CreateScreen(int screen, struct glx_ - - static const struct dri_extension_match exts[] = { - { __DRI_CORE, 1, offsetof(struct dri2_screen, core), false }, -- { __DRI_DRI2, 4, offsetof(struct dri2_screen, dri2), false }, -- { __DRI_MESA, 1, offsetof(struct dri2_screen, mesa), false }, -+ { __DRI_DRI2, 5, offsetof(struct dri2_screen, dri2), false }, -+ { __DRI_MESA, 2, offsetof(struct dri2_screen, mesa), false }, - }; - if (!loader_bind_extensions(psc, exts, ARRAY_SIZE(exts), extensions)) - goto handle_error; - - psc->driScreen = -- psc->dri2->createNewScreen2(screen, psc->fd, -+ psc->dri2->createNewScreen3(screen, psc->fd, - (const __DRIextension **)&pdp->loader_extensions[0], - extensions, -- &driver_configs, psc); -+ &driver_configs, implicit, psc); - - if (psc->driScreen == NULL) { - ErrorMessageF("glx: failed to create dri2 screen\n"); -Index: mesa-24.0.3/src/glx/dri3_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/dri3_glx.c -+++ mesa-24.0.3/src/glx/dri3_glx.c -@@ -841,8 +841,8 @@ dri3_create_screen(int screen, struct gl - - static const struct dri_extension_match exts[] = { - { __DRI_CORE, 1, offsetof(struct dri3_screen, core), false }, -- { __DRI_IMAGE_DRIVER, 1, offsetof(struct dri3_screen, image_driver), false }, -- { __DRI_MESA, 1, offsetof(struct dri3_screen, mesa), false }, -+ { __DRI_IMAGE_DRIVER, 2, offsetof(struct dri3_screen, image_driver), false }, -+ { __DRI_MESA, 2, offsetof(struct dri3_screen, mesa), false }, - }; - if (!loader_bind_extensions(psc, exts, ARRAY_SIZE(exts), extensions)) - goto handle_error; -@@ -858,10 +858,10 @@ dri3_create_screen(int screen, struct gl - */ - if (strcmp(driverName, driverNameDisplayGPU) == 0) { - psc->driScreenDisplayGPU = -- psc->image_driver->createNewScreen2(screen, psc->fd_display_gpu, -+ psc->image_driver->createNewScreen3(screen, psc->fd_display_gpu, - pdp->loader_extensions, - extensions, -- &driver_configs, psc); -+ &driver_configs, implicit, psc); - } - - free(driverNameDisplayGPU); -@@ -869,10 +869,10 @@ dri3_create_screen(int screen, struct gl - } - - psc->driScreenRenderGPU = -- psc->image_driver->createNewScreen2(screen, psc->fd_render_gpu, -+ psc->image_driver->createNewScreen3(screen, psc->fd_render_gpu, - pdp->loader_extensions, - extensions, -- &driver_configs, psc); -+ &driver_configs, implicit, psc); - - if (psc->driScreenRenderGPU == NULL) { - ErrorMessageF("glx: failed to create dri3 screen\n"); -Index: mesa-24.0.3/src/glx/drisw_glx.c -=================================================================== ---- mesa-24.0.3.orig/src/glx/drisw_glx.c -+++ mesa-24.0.3/src/glx/drisw_glx.c -@@ -934,7 +934,7 @@ kopperGetSwapInterval(__GLXDRIdrawable * - - static struct glx_screen * - driswCreateScreenDriver(int screen, struct glx_display *priv, -- const char *driver) -+ const char *driver, bool implicit) - { - __GLXDRIscreen *psp; - const __DRIconfig **driver_configs; -@@ -967,18 +967,18 @@ driswCreateScreenDriver(int screen, stru - - static const struct dri_extension_match exts[] = { - { __DRI_CORE, 1, offsetof(struct drisw_screen, core), false }, -- { __DRI_SWRAST, 4, offsetof(struct drisw_screen, swrast), false }, -+ { __DRI_SWRAST, 5, offsetof(struct drisw_screen, swrast), false }, - { __DRI_KOPPER, 1, offsetof(struct drisw_screen, kopper), true }, - { __DRI_COPY_SUB_BUFFER, 1, offsetof(struct drisw_screen, copySubBuffer), true }, -- { __DRI_MESA, 1, offsetof(struct drisw_screen, mesa), false }, -+ { __DRI_MESA, 2, offsetof(struct drisw_screen, mesa), false }, - }; - if (!loader_bind_extensions(psc, exts, ARRAY_SIZE(exts), extensions)) - goto handle_error; - - psc->driScreen = -- psc->swrast->createNewScreen2(screen, loader_extensions_local, -+ psc->swrast->createNewScreen3(screen, loader_extensions_local, - extensions, -- &driver_configs, psc); -+ &driver_configs, implicit, psc); - if (psc->driScreen == NULL) { - ErrorMessageF("glx: failed to create drisw screen\n"); - goto handle_error; -@@ -1059,10 +1059,10 @@ driswCreateScreen(int screen, struct glx - { - const struct drisw_display *pdpyp = (struct drisw_display *)priv->driswDisplay; - if (pdpyp->zink && !debug_get_bool_option("LIBGL_KOPPER_DISABLE", false)) { -- return driswCreateScreenDriver(screen, priv, "zink"); -+ return driswCreateScreenDriver(screen, priv, "zink", implicit); - } - -- return driswCreateScreenDriver(screen, priv, "swrast"); -+ return driswCreateScreenDriver(screen, priv, "swrast", implicit); - } - - /* Called from __glXFreeDisplayPrivate. diff --git a/0006-gbm-plumb-an-implicit-param-through-device-creation.patch b/0006-gbm-plumb-an-implicit-param-through-device-creation.patch deleted file mode 100644 index 79a1c84..0000000 --- a/0006-gbm-plumb-an-implicit-param-through-device-creation.patch +++ /dev/null @@ -1,82 +0,0 @@ -From 664e73e7120fbf5ad62da643a7e4aff525d38d94 Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 10:01:29 -0400 -Subject: [PATCH 6/9] gbm: plumb an 'implicit' param through device creation - -this is always true except in the software fallback ---- - src/gbm/backends/dri/gbm_dri.c | 20 ++++++++++---------- - 1 file changed, 10 insertions(+), 10 deletions(-) - -Index: mesa-24.0.3/src/gbm/backends/dri/gbm_dri.c -=================================================================== ---- mesa-24.0.3.orig/src/gbm/backends/dri/gbm_dri.c -+++ mesa-24.0.3/src/gbm/backends/dri/gbm_dri.c -@@ -287,7 +287,7 @@ dri_open_driver(struct gbm_dri_device *d - } - - static int --dri_screen_create_for_driver(struct gbm_dri_device *dri, char *driver_name) -+dri_screen_create_for_driver(struct gbm_dri_device *dri, char *driver_name, bool implicit) - { - bool swrast = driver_name == NULL; /* If it's pure swrast, not just swkms. */ - -@@ -318,7 +318,7 @@ dri_screen_create_for_driver(struct gbm_ - dri->screen = dri->mesa->createNewScreen3(0, swrast ? -1 : dri->base.v0.fd, - dri->loader_extensions, - dri->driver_extensions, -- &dri->driver_configs, false, dri); -+ &dri->driver_configs, implicit, dri); - if (dri->screen == NULL) - goto close_driver; - -@@ -348,7 +348,7 @@ fail: - } - - static int --dri_screen_create(struct gbm_dri_device *dri) -+dri_screen_create(struct gbm_dri_device *dri, bool implicit) - { - char *driver_name; - -@@ -356,11 +356,11 @@ dri_screen_create(struct gbm_dri_device - if (!driver_name) - return -1; - -- return dri_screen_create_for_driver(dri, driver_name); -+ return dri_screen_create_for_driver(dri, driver_name, implicit); - } - - static int --dri_screen_create_sw(struct gbm_dri_device *dri) -+dri_screen_create_sw(struct gbm_dri_device *dri, bool implicit) - { - char *driver_name; - int ret; -@@ -369,9 +369,9 @@ dri_screen_create_sw(struct gbm_dri_devi - if (!driver_name) - return -errno; - -- ret = dri_screen_create_for_driver(dri, driver_name); -+ ret = dri_screen_create_for_driver(dri, driver_name, implicit); - if (ret != 0) -- ret = dri_screen_create_for_driver(dri, NULL); -+ ret = dri_screen_create_for_driver(dri, NULL, implicit); - if (ret != 0) - return ret; - -@@ -1289,11 +1289,11 @@ dri_device_create(int fd, uint32_t gbm_b - - force_sw = debug_get_bool_option("GBM_ALWAYS_SOFTWARE", false); - if (!force_sw) { -- ret = dri_screen_create(dri); -+ ret = dri_screen_create(dri, false); - if (ret) -- ret = dri_screen_create_sw(dri); -+ ret = dri_screen_create_sw(dri, true); - } else { -- ret = dri_screen_create_sw(dri); -+ ret = dri_screen_create_sw(dri, false); - } - - if (ret) diff --git a/0007-frontends-dri-plumb-an-implicit-param-through-screen.patch b/0007-frontends-dri-plumb-an-implicit-param-through-screen.patch deleted file mode 100644 index 263e9fb..0000000 --- a/0007-frontends-dri-plumb-an-implicit-param-through-screen.patch +++ /dev/null @@ -1,88 +0,0 @@ -From 55236ac5349f1208356e713336276c052384e444 Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 10:05:49 -0400 -Subject: [PATCH 7/9] frontends/dri: plumb an 'implicit' param through screen - init - ---- - include/GL/internal/mesa_interface.h | 2 +- - src/gallium/frontends/dri/dri2.c | 4 ++-- - src/gallium/frontends/dri/dri_util.c | 2 +- - src/gallium/frontends/dri/drisw.c | 2 +- - src/gallium/frontends/dri/kopper.c | 2 +- - 5 files changed, 6 insertions(+), 6 deletions(-) - -Index: mesa-24.0.3/include/GL/internal/mesa_interface.h -=================================================================== ---- mesa-24.0.3.orig/include/GL/internal/mesa_interface.h -+++ mesa-24.0.3/include/GL/internal/mesa_interface.h -@@ -60,7 +60,7 @@ struct __DRImesaCoreExtensionRec { - __DRIcreateContextAttribsFunc createContext; - - /* driver function for finishing initialization inside createNewScreen(). */ -- const __DRIconfig **(*initScreen)(struct dri_screen *screen); -+ const __DRIconfig **(*initScreen)(struct dri_screen *screen, bool implicit); - - int (*queryCompatibleRenderOnlyDeviceFd)(int kms_only_fd); - -Index: mesa-24.0.3/src/gallium/frontends/dri/dri2.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/dri2.c -+++ mesa-24.0.3/src/gallium/frontends/dri/dri2.c -@@ -2374,7 +2374,7 @@ dri2_create_drawable(struct dri_screen * - * Returns the struct gl_config supported by this driver. - */ - static const __DRIconfig ** --dri2_init_screen(struct dri_screen *screen) -+dri2_init_screen(struct dri_screen *screen, bool implicit) - { - const __DRIconfig **configs; - struct pipe_screen *pscreen = NULL; -@@ -2430,7 +2430,7 @@ fail: - * Returns the struct gl_config supported by this driver. - */ - static const __DRIconfig ** --dri_swrast_kms_init_screen(struct dri_screen *screen) -+dri_swrast_kms_init_screen(struct dri_screen *screen, bool implicit) - { - #if defined(GALLIUM_SOFTPIPE) - const __DRIconfig **configs; -Index: mesa-24.0.3/src/gallium/frontends/dri/dri_util.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/dri_util.c -+++ mesa-24.0.3/src/gallium/frontends/dri/dri_util.c -@@ -136,7 +136,7 @@ driCreateNewScreen3(int scrn, int fd, - driParseConfigFiles(&screen->optionCache, &screen->optionInfo, screen->myNum, - "dri2", NULL, NULL, NULL, 0, NULL, 0); - -- *driver_configs = mesa->initScreen(screen); -+ *driver_configs = mesa->initScreen(screen, implicit); - if (*driver_configs == NULL) { - dri_destroy_screen(screen); - return NULL; -Index: mesa-24.0.3/src/gallium/frontends/dri/drisw.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/drisw.c -+++ mesa-24.0.3/src/gallium/frontends/dri/drisw.c -@@ -539,7 +539,7 @@ drisw_create_drawable(struct dri_screen - } - - static const __DRIconfig ** --drisw_init_screen(struct dri_screen *screen) -+drisw_init_screen(struct dri_screen *screen, bool implicit) - { - const __DRIswrastLoaderExtension *loader = screen->swrast_loader; - const __DRIconfig **configs; -Index: mesa-24.0.3/src/gallium/frontends/dri/kopper.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/frontends/dri/kopper.c -+++ mesa-24.0.3/src/gallium/frontends/dri/kopper.c -@@ -110,7 +110,7 @@ static const __DRIextension *drivk_sw_sc - }; - - static const __DRIconfig ** --kopper_init_screen(struct dri_screen *screen) -+kopper_init_screen(struct dri_screen *screen, bool implicit) - { - const __DRIconfig **configs; - struct pipe_screen *pscreen = NULL; diff --git a/0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch b/0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch deleted file mode 100644 index ef21342..0000000 --- a/0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch +++ /dev/null @@ -1,281 +0,0 @@ -From 4df36439ecff5a2b65e93ab36d1ebea780269b63 Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 10:13:40 -0400 -Subject: [PATCH 8/9] pipe-loader: plumb a flag for implicit driver load - through screen creation - ---- - src/gallium/auxiliary/pipe-loader/pipe_loader.c | 7 ++++--- - src/gallium/auxiliary/pipe-loader/pipe_loader.h | 6 ++++-- - src/gallium/auxiliary/vl/vl_winsys_dri.c | 2 +- - src/gallium/auxiliary/vl/vl_winsys_dri3.c | 2 +- - src/gallium/auxiliary/vl/vl_winsys_drm.c | 2 +- - src/gallium/frontends/clover/core/device.cpp | 2 +- - src/gallium/frontends/dri/dri2.c | 4 ++-- - src/gallium/frontends/dri/drisw.c | 2 +- - src/gallium/frontends/dri/kopper.c | 2 +- - src/gallium/frontends/lavapipe/lvp_device.c | 2 +- - src/gallium/frontends/rusticl/mesa/pipe/device.rs | 2 +- - src/gallium/frontends/teflon/tfl_device.c | 2 +- - src/gallium/frontends/xa/xa_tracker.c | 2 +- - src/gallium/include/pipe/p_screen.h | 1 + - src/gallium/targets/d3dadapter9/drm.c | 4 ++-- - src/gallium/tests/trivial/quad-tex.c | 2 +- - src/gallium/tests/trivial/tri.c | 2 +- - 17 files changed, 25 insertions(+), 21 deletions(-) - -Index: mesa-24.0.8/src/gallium/auxiliary/pipe-loader/pipe_loader.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/auxiliary/pipe-loader/pipe_loader.c -+++ mesa-24.0.8/src/gallium/auxiliary/pipe-loader/pipe_loader.c -@@ -169,11 +169,12 @@ pipe_loader_get_driinfo_xml(const char * - } - - struct pipe_screen * --pipe_loader_create_screen_vk(struct pipe_loader_device *dev, bool sw_vk) -+pipe_loader_create_screen_vk(struct pipe_loader_device *dev, bool sw_vk, bool implicit) - { - struct pipe_screen_config config; - - pipe_loader_load_options(dev); -+ config.implicit_driver_load = implicit; - config.options_info = &dev->option_info; - config.options = &dev->option_cache; - -@@ -181,9 +182,9 @@ pipe_loader_create_screen_vk(struct pipe - } - - struct pipe_screen * --pipe_loader_create_screen(struct pipe_loader_device *dev) -+pipe_loader_create_screen(struct pipe_loader_device *dev, bool implicit) - { -- return pipe_loader_create_screen_vk(dev, false); -+ return pipe_loader_create_screen_vk(dev, false, implicit); - } - - struct util_dl_library * -Index: mesa-24.0.8/src/gallium/auxiliary/pipe-loader/pipe_loader.h -=================================================================== ---- mesa-24.0.8.orig/src/gallium/auxiliary/pipe-loader/pipe_loader.h -+++ mesa-24.0.8/src/gallium/auxiliary/pipe-loader/pipe_loader.h -@@ -88,17 +88,19 @@ pipe_loader_probe(struct pipe_loader_dev - * - * \param dev Device the screen will be created for. - * \param sw_vk Device is for software vulkan -+ * \param implicit Whether the driver is being loaded implicitly. - */ - struct pipe_screen * --pipe_loader_create_screen_vk(struct pipe_loader_device *dev, bool sw_vk); -+pipe_loader_create_screen_vk(struct pipe_loader_device *dev, bool sw_vk, bool implicit); - - /** - * Create a pipe_screen for the specified device. - * - * \param dev Device the screen will be created for. -+ * \param implicit Whether the driver is being loaded implicitly. - */ - struct pipe_screen * --pipe_loader_create_screen(struct pipe_loader_device *dev); -+pipe_loader_create_screen(struct pipe_loader_device *dev, bool implicit); - - /** - * Ensures that the driconf option cache has been parsed for the driver. -Index: mesa-24.0.8/src/gallium/auxiliary/vl/vl_winsys_dri.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/auxiliary/vl/vl_winsys_dri.c -+++ mesa-24.0.8/src/gallium/auxiliary/vl/vl_winsys_dri.c -@@ -459,7 +459,7 @@ vl_dri2_screen_create(Display *display, - goto free_authenticate; - - if (pipe_loader_drm_probe_fd(&scrn->base.dev, fd, false)) -- scrn->base.pscreen = pipe_loader_create_screen(scrn->base.dev); -+ scrn->base.pscreen = pipe_loader_create_screen(scrn->base.dev, false); - - if (!scrn->base.pscreen) - goto release_pipe; -Index: mesa-24.0.8/src/gallium/auxiliary/vl/vl_winsys_dri3.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/auxiliary/vl/vl_winsys_dri3.c -+++ mesa-24.0.8/src/gallium/auxiliary/vl/vl_winsys_dri3.c -@@ -843,7 +843,7 @@ vl_dri3_screen_create(Display *display, - free(geom_reply); - - if (pipe_loader_drm_probe_fd(&scrn->base.dev, fd, false)) -- scrn->base.pscreen = pipe_loader_create_screen(scrn->base.dev); -+ scrn->base.pscreen = pipe_loader_create_screen(scrn->base.dev, false); - - if (!scrn->base.pscreen) - goto release_pipe; -Index: mesa-24.0.8/src/gallium/auxiliary/vl/vl_winsys_drm.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/auxiliary/vl/vl_winsys_drm.c -+++ mesa-24.0.8/src/gallium/auxiliary/vl/vl_winsys_drm.c -@@ -47,7 +47,7 @@ vl_drm_screen_create(int fd) - return NULL; - - if (pipe_loader_drm_probe_fd(&vscreen->dev, fd, false)) -- vscreen->pscreen = pipe_loader_create_screen(vscreen->dev); -+ vscreen->pscreen = pipe_loader_create_screen(vscreen->dev, false); - - if (!vscreen->pscreen) - goto release_pipe; -Index: mesa-24.0.8/src/gallium/frontends/clover/core/device.cpp -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/clover/core/device.cpp -+++ mesa-24.0.8/src/gallium/frontends/clover/core/device.cpp -@@ -163,7 +163,7 @@ namespace { - - device::device(clover::platform &platform, pipe_loader_device *ldev) : - platform(platform), clc_cache(NULL), ldev(ldev) { -- pipe = pipe_loader_create_screen(ldev); -+ pipe = pipe_loader_create_screen(ldev, false); - if (pipe && pipe->get_param(pipe, PIPE_CAP_COMPUTE)) { - const bool has_supported_ir = supports_ir(PIPE_SHADER_IR_NATIVE) || - supports_ir(PIPE_SHADER_IR_NIR_SERIALIZED); -Index: mesa-24.0.8/src/gallium/frontends/dri/dri2.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/dri/dri2.c -+++ mesa-24.0.8/src/gallium/frontends/dri/dri2.c -@@ -2382,7 +2382,7 @@ dri2_init_screen(struct dri_screen *scre - (void) mtx_init(&screen->opencl_func_mutex, mtx_plain); - - if (pipe_loader_drm_probe_fd(&screen->dev, screen->fd, false)) -- pscreen = pipe_loader_create_screen(screen->dev); -+ pscreen = pipe_loader_create_screen(screen->dev, implicit); - - if (!pscreen) - return NULL; -@@ -2438,7 +2438,7 @@ dri_swrast_kms_init_screen(struct dri_sc - - #ifdef HAVE_DRISW_KMS - if (pipe_loader_sw_probe_kms(&screen->dev, screen->fd)) -- pscreen = pipe_loader_create_screen(screen->dev); -+ pscreen = pipe_loader_create_screen(screen->dev, implicit); - #endif - - if (!pscreen) -Index: mesa-24.0.8/src/gallium/frontends/dri/drisw.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/dri/drisw.c -+++ mesa-24.0.8/src/gallium/frontends/dri/drisw.c -@@ -564,7 +564,7 @@ drisw_init_screen(struct dri_screen *scr - success = pipe_loader_sw_probe_dri(&screen->dev, lf); - - if (success) -- pscreen = pipe_loader_create_screen(screen->dev); -+ pscreen = pipe_loader_create_screen(screen->dev, implicit); - - if (!pscreen) - return NULL; -Index: mesa-24.0.8/src/gallium/frontends/dri/kopper.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/dri/kopper.c -+++ mesa-24.0.8/src/gallium/frontends/dri/kopper.c -@@ -133,7 +133,7 @@ kopper_init_screen(struct dri_screen *sc - success = pipe_loader_vk_probe_dri(&screen->dev); - - if (success) -- pscreen = pipe_loader_create_screen(screen->dev); -+ pscreen = pipe_loader_create_screen(screen->dev, implicit); - - if (!pscreen) - return NULL; -Index: mesa-24.0.8/src/gallium/frontends/lavapipe/lvp_device.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/lavapipe/lvp_device.c -+++ mesa-24.0.8/src/gallium/frontends/lavapipe/lvp_device.c -@@ -1101,7 +1101,7 @@ lvp_physical_device_init(struct lvp_phys - } - device->pld = pld; - -- device->pscreen = pipe_loader_create_screen_vk(device->pld, true); -+ device->pscreen = pipe_loader_create_screen_vk(device->pld, true, false); - if (!device->pscreen) - return vk_error(instance, VK_ERROR_OUT_OF_HOST_MEMORY); - for (unsigned i = 0; i < ARRAY_SIZE(device->drv_options); i++) -Index: mesa-24.0.8/src/gallium/frontends/xa/xa_tracker.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/xa/xa_tracker.c -+++ mesa-24.0.8/src/gallium/frontends/xa/xa_tracker.c -@@ -172,7 +172,7 @@ xa_tracker_create(int drm_fd) - return NULL; - - if (pipe_loader_drm_probe_fd(&xa->dev, drm_fd, false)) -- xa->screen = pipe_loader_create_screen(xa->dev); -+ xa->screen = pipe_loader_create_screen(xa->dev, false); - - if (!xa->screen) - goto out_no_screen; -Index: mesa-24.0.8/src/gallium/include/pipe/p_screen.h -=================================================================== ---- mesa-24.0.8.orig/src/gallium/include/pipe/p_screen.h -+++ mesa-24.0.8/src/gallium/include/pipe/p_screen.h -@@ -806,6 +806,7 @@ struct pipe_screen { - * Global configuration options for screen creation. - */ - struct pipe_screen_config { -+ bool implicit_driver_load; - struct driOptionCache *options; - const struct driOptionCache *options_info; - }; -Index: mesa-24.0.8/src/gallium/targets/d3dadapter9/drm.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/targets/d3dadapter9/drm.c -+++ mesa-24.0.8/src/gallium/targets/d3dadapter9/drm.c -@@ -242,7 +242,7 @@ drm_create_adapter( int fd, - return D3DERR_DRIVERINTERNALERROR; - } - -- ctx->base.hal = pipe_loader_create_screen(ctx->dev); -+ ctx->base.hal = pipe_loader_create_screen(ctx->dev, false); - if (!ctx->base.hal) { - ERR("Unable to load requested driver.\n"); - drm_destroy(&ctx->base); -@@ -302,7 +302,7 @@ drm_create_adapter( int fd, - sw_rendering |= debug_get_bool_option("D3D_ALWAYS_SOFTWARE", false); - /* wrap it to create a software screen that can share resources */ - if (sw_rendering && pipe_loader_sw_probe_wrapped(&ctx->swdev, ctx->base.hal)) -- ctx->base.ref = pipe_loader_create_screen(ctx->swdev); -+ ctx->base.ref = pipe_loader_create_screen(ctx->swdev, false); - else { - /* Use the hardware for sw rendering */ - ctx->swdev = ctx->dev; -Index: mesa-24.0.8/src/gallium/tests/trivial/quad-tex.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/tests/trivial/quad-tex.c -+++ mesa-24.0.8/src/gallium/tests/trivial/quad-tex.c -@@ -97,7 +97,7 @@ static void init_prog(struct program *p) - assert(ret); - - /* init a pipe screen */ -- p->screen = pipe_loader_create_screen(p->dev); -+ p->screen = pipe_loader_create_screen(p->dev, false); - assert(p->screen); - - /* create the pipe driver context and cso context */ -Index: mesa-24.0.8/src/gallium/tests/trivial/tri.c -=================================================================== ---- mesa-24.0.8.orig/src/gallium/tests/trivial/tri.c -+++ mesa-24.0.8/src/gallium/tests/trivial/tri.c -@@ -91,7 +91,7 @@ static void init_prog(struct program *p) - assert(ret); - - /* init a pipe screen */ -- p->screen = pipe_loader_create_screen(p->dev); -+ p->screen = pipe_loader_create_screen(p->dev, false); - assert(p->screen); - - /* create the pipe driver context and cso context */ -Index: mesa-24.0.8/src/gallium/frontends/rusticl/mesa/pipe/device.rs -=================================================================== ---- mesa-24.0.8.orig/src/gallium/frontends/rusticl/mesa/pipe/device.rs -+++ mesa-24.0.8/src/gallium/frontends/rusticl/mesa/pipe/device.rs -@@ -20,7 +20,7 @@ impl PipeLoaderDevice { - } - - fn load_screen(self) -> Option { -- let s = unsafe { pipe_loader_create_screen(self.ldev) }; -+ let s = unsafe { pipe_loader_create_screen(self.ldev, false) }; - PipeScreen::new(self, s) - } - diff --git a/0009-zink-don-t-print-error-messages-when-failing-an-impl.patch b/0009-zink-don-t-print-error-messages-when-failing-an-impl.patch deleted file mode 100644 index c70757b..0000000 --- a/0009-zink-don-t-print-error-messages-when-failing-an-impl.patch +++ /dev/null @@ -1,327 +0,0 @@ -From 940d9bce8ec9a1acc5065bce9d3e4c369546319b Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 12 Mar 2024 10:22:24 -0400 -Subject: [PATCH 9/9] zink: don't print error messages when failing an implicit - driver load - ---- - src/gallium/drivers/zink/zink_device_info.py | 6 +- - src/gallium/drivers/zink/zink_instance.py | 15 ++-- - src/gallium/drivers/zink/zink_screen.c | 76 +++++++++++++------- - src/gallium/drivers/zink/zink_types.h | 1 + - 4 files changed, 66 insertions(+), 32 deletions(-) - -Index: mesa-24.0.3/src/gallium/drivers/zink/zink_device_info.py -=================================================================== ---- mesa-24.0.3.orig/src/gallium/drivers/zink/zink_device_info.py -+++ mesa-24.0.3/src/gallium/drivers/zink/zink_device_info.py -@@ -463,14 +463,16 @@ zink_get_physical_device_info(struct zin - // enumerate device supported extensions - VkResult result = screen->vk.EnumerateDeviceExtensionProperties(screen->pdev, NULL, &num_extensions, NULL); - if (result != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumerateDeviceExtensionProperties failed (%s)", vk_Result_to_str(result)); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumerateDeviceExtensionProperties failed (%s)", vk_Result_to_str(result)); - } else { - if (num_extensions > 0) { - VkExtensionProperties *extensions = MALLOC(sizeof(VkExtensionProperties) * num_extensions); - if (!extensions) goto fail; - result = screen->vk.EnumerateDeviceExtensionProperties(screen->pdev, NULL, &num_extensions, extensions); - if (result != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumerateDeviceExtensionProperties failed (%s)", vk_Result_to_str(result)); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumerateDeviceExtensionProperties failed (%s)", vk_Result_to_str(result)); - } - - for (uint32_t i = 0; i < num_extensions; ++i) { -Index: mesa-24.0.3/src/gallium/drivers/zink/zink_instance.py -=================================================================== ---- mesa-24.0.3.orig/src/gallium/drivers/zink/zink_instance.py -+++ mesa-24.0.3/src/gallium/drivers/zink/zink_instance.py -@@ -156,12 +156,14 @@ zink_create_instance(struct zink_screen - // Build up the extensions from the reported ones but only for the unnamed layer - uint32_t extension_count = 0; - if (vk_EnumerateInstanceExtensionProperties(NULL, &extension_count, NULL) != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumerateInstanceExtensionProperties failed"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumerateInstanceExtensionProperties failed"); - } else { - VkExtensionProperties *extension_props = malloc(extension_count * sizeof(VkExtensionProperties)); - if (extension_props) { - if (vk_EnumerateInstanceExtensionProperties(NULL, &extension_count, extension_props) != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumerateInstanceExtensionProperties failed"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumerateInstanceExtensionProperties failed"); - } else { - for (uint32_t i = 0; i < extension_count; i++) { - %for ext in extensions: -@@ -179,12 +181,14 @@ zink_create_instance(struct zink_screen - uint32_t layer_count = 0; - - if (vk_EnumerateInstanceLayerProperties(&layer_count, NULL) != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumerateInstanceLayerProperties failed"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumerateInstanceLayerProperties failed"); - } else { - VkLayerProperties *layer_props = malloc(layer_count * sizeof(VkLayerProperties)); - if (layer_props) { - if (vk_EnumerateInstanceLayerProperties(&layer_count, layer_props) != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumerateInstanceLayerProperties failed"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumerateInstanceLayerProperties failed"); - } else { - for (uint32_t i = 0; i < layer_count; i++) { - %for layer in layers: -@@ -256,7 +260,8 @@ zink_create_instance(struct zink_screen - - VkResult err = vk_CreateInstance(&ici, NULL, &screen->instance); - if (err != VK_SUCCESS) { -- mesa_loge("ZINK: vkCreateInstance failed (%s)", vk_Result_to_str(err)); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkCreateInstance failed (%s)", vk_Result_to_str(err)); - return false; - } - -Index: mesa-24.0.3/src/gallium/drivers/zink/zink_screen.c -=================================================================== ---- mesa-24.0.3.orig/src/gallium/drivers/zink/zink_screen.c -+++ mesa-24.0.3/src/gallium/drivers/zink/zink_screen.c -@@ -1606,7 +1606,8 @@ choose_pdev(struct zink_screen *screen, - VkPhysicalDevice *pdevs; - VkResult result = VKSCR(EnumeratePhysicalDevices)(screen->instance, &pdev_count, NULL); - if (result != VK_SUCCESS) { -- mesa_loge("ZINK: vkEnumeratePhysicalDevices failed (%s)", vk_Result_to_str(result)); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumeratePhysicalDevices failed (%s)", vk_Result_to_str(result)); - return; - } - -@@ -1614,7 +1615,8 @@ choose_pdev(struct zink_screen *screen, - - pdevs = malloc(sizeof(*pdevs) * pdev_count); - if (!pdevs) { -- mesa_loge("ZINK: failed to allocate pdevs!"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to allocate pdevs!"); - return; - } - result = VKSCR(EnumeratePhysicalDevices)(screen->instance, &pdev_count, pdevs); -@@ -1641,7 +1643,8 @@ choose_pdev(struct zink_screen *screen, - unsigned pdev_count = 1; - VkResult result = VKSCR(EnumeratePhysicalDevices)(screen->instance, &pdev_count, &pdev); - if (result != VK_SUCCESS && result != VK_INCOMPLETE) { -- mesa_loge("ZINK: vkEnumeratePhysicalDevices failed (%s)", vk_Result_to_str(result)); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: vkEnumeratePhysicalDevices failed (%s)", vk_Result_to_str(result)); - return; - } - screen->pdev = pdev; -@@ -3147,10 +3150,12 @@ zink_internal_create_screen(const struct - - struct zink_screen *screen = rzalloc(NULL, struct zink_screen); - if (!screen) { -- mesa_loge("ZINK: failed to allocate screen"); -+ if (!config->implicit_driver_load) -+ mesa_loge("ZINK: failed to allocate screen"); - return NULL; - } - -+ screen->implicitly_loaded = config->implicit_driver_load; - screen->drm_fd = -1; - - glsl_type_singleton_init_or_ref(); -@@ -3170,7 +3175,8 @@ zink_internal_create_screen(const struct - - screen->loader_lib = util_dl_open(VK_LIBNAME); - if (!screen->loader_lib) { -- mesa_loge("ZINK: failed to load "VK_LIBNAME); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to load "VK_LIBNAME); - goto fail; - } - -@@ -3178,7 +3184,8 @@ zink_internal_create_screen(const struct - screen->vk_GetDeviceProcAddr = (PFN_vkGetDeviceProcAddr)util_dl_get_proc_address(screen->loader_lib, "vkGetDeviceProcAddr"); - if (!screen->vk_GetInstanceProcAddr || - !screen->vk_GetDeviceProcAddr) { -- mesa_loge("ZINK: failed to get proc address"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to get proc address"); - goto fail; - } - -@@ -3199,7 +3206,8 @@ zink_internal_create_screen(const struct - if (zink_debug & ZINK_DEBUG_VALIDATION) { - if (!screen->instance_info.have_layer_KHRONOS_validation && - !screen->instance_info.have_layer_LUNARG_standard_validation) { -- mesa_loge("Failed to load validation layer"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("Failed to load validation layer"); - goto fail; - } - } -@@ -3214,12 +3222,15 @@ zink_internal_create_screen(const struct - zink_verify_instance_extensions(screen); - - if (screen->instance_info.have_EXT_debug_utils && -- (zink_debug & ZINK_DEBUG_VALIDATION) && !create_debug(screen)) -- debug_printf("ZINK: failed to setup debug utils\n"); -+ (zink_debug & ZINK_DEBUG_VALIDATION) && !create_debug(screen)) { -+ if (!screen->implicitly_loaded) -+ debug_printf("ZINK: failed to setup debug utils\n"); -+ } - - choose_pdev(screen, dev_major, dev_minor); - if (screen->pdev == VK_NULL_HANDLE) { -- mesa_loge("ZINK: failed to choose pdev"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to choose pdev"); - goto fail; - } - screen->is_cpu = screen->info.props.deviceType == VK_PHYSICAL_DEVICE_TYPE_CPU; -@@ -3234,7 +3245,8 @@ zink_internal_create_screen(const struct - VK_FORMAT_D32_SFLOAT_S8_UINT); - - if (!zink_get_physical_device_info(screen)) { -- debug_printf("ZINK: failed to detect features\n"); -+ if (!screen->implicitly_loaded) -+ debug_printf("ZINK: failed to detect features\n"); - goto fail; - } - -@@ -3277,18 +3289,21 @@ zink_internal_create_screen(const struct - - setup_renderdoc(screen); - if (screen->threaded_submit && !util_queue_init(&screen->flush_queue, "zfq", 8, 1, UTIL_QUEUE_INIT_RESIZE_IF_FULL, screen)) { -- mesa_loge("zink: Failed to create flush queue.\n"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("zink: Failed to create flush queue.\n"); - goto fail; - } - - zink_internal_setup_moltenvk(screen); - if (!screen->info.have_KHR_timeline_semaphore && !screen->info.feats12.timelineSemaphore) { -- mesa_loge("zink: KHR_timeline_semaphore is required"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("zink: KHR_timeline_semaphore is required"); - goto fail; - } - if (zink_debug & ZINK_DEBUG_DGC) { - if (!screen->info.have_NV_device_generated_commands) { -- mesa_loge("zink: can't use DGC without NV_device_generated_commands"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("zink: can't use DGC without NV_device_generated_commands"); - goto fail; - } - } -@@ -3404,14 +3419,16 @@ zink_internal_create_screen(const struct - if (!zink_screen_resource_init(&screen->base)) - goto fail; - if (!zink_bo_init(screen)) { -- mesa_loge("ZINK: failed to initialize suballocator"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to initialize suballocator"); - goto fail; - } - zink_screen_fence_init(&screen->base); - - zink_screen_init_compiler(screen); - if (!disk_cache_init(screen)) { -- mesa_loge("ZINK: failed to initialize disk cache"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to initialize disk cache"); - goto fail; - } - if (!util_queue_init(&screen->cache_get_thread, "zcfq", 8, 4, -@@ -3426,12 +3443,14 @@ zink_internal_create_screen(const struct - screen->total_video_mem = get_video_mem(screen); - screen->clamp_video_mem = screen->total_video_mem * 0.8; - if (!os_get_total_physical_memory(&screen->total_mem)) { -- mesa_loge("ZINK: failed to get total physical memory"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to get total physical memory"); - goto fail; - } - - if (!zink_screen_init_semaphore(screen)) { -- mesa_loge("zink: failed to create timeline semaphore"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("zink: failed to create timeline semaphore"); - goto fail; - } - -@@ -3439,35 +3458,40 @@ zink_internal_create_screen(const struct - { - if (!screen->info.have_EXT_descriptor_buffer) { - if (zink_descriptor_mode == ZINK_DESCRIPTOR_MODE_DB) { -- mesa_loge("Cannot use db descriptor mode without EXT_descriptor_buffer"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("Cannot use db descriptor mode without EXT_descriptor_buffer"); - goto fail; - } - can_db = false; - } - if (!screen->resizable_bar) { - if (zink_descriptor_mode == ZINK_DESCRIPTOR_MODE_DB) { -- mesa_loge("Cannot use db descriptor mode without resizable bar"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("Cannot use db descriptor mode without resizable bar"); - goto fail; - } - can_db = false; - } - if (!screen->info.have_EXT_non_seamless_cube_map) { - if (zink_descriptor_mode == ZINK_DESCRIPTOR_MODE_DB) { -- mesa_loge("Cannot use db descriptor mode without EXT_non_seamless_cube_map"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("Cannot use db descriptor mode without EXT_non_seamless_cube_map"); - goto fail; - } - can_db = false; - } - if (!screen->info.rb2_feats.nullDescriptor) { - if (zink_descriptor_mode == ZINK_DESCRIPTOR_MODE_DB) { -- mesa_loge("Cannot use db descriptor mode without robustness2.nullDescriptor"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("Cannot use db descriptor mode without robustness2.nullDescriptor"); - goto fail; - } - can_db = false; - } - if (ZINK_FBFETCH_DESCRIPTOR_SIZE < screen->info.db_props.inputAttachmentDescriptorSize) { - if (zink_descriptor_mode == ZINK_DESCRIPTOR_MODE_DB) { -- mesa_loge("Cannot use db descriptor mode with inputAttachmentDescriptorSize(%u) > %u", (unsigned)screen->info.db_props.inputAttachmentDescriptorSize, ZINK_FBFETCH_DESCRIPTOR_SIZE); -+ if (!screen->implicitly_loaded) -+ mesa_loge("Cannot use db descriptor mode with inputAttachmentDescriptorSize(%u) > %u", (unsigned)screen->info.db_props.inputAttachmentDescriptorSize, ZINK_FBFETCH_DESCRIPTOR_SIZE); - goto fail; - } - mesa_logw("zink: bug detected: inputAttachmentDescriptorSize(%u) > %u", (unsigned)screen->info.db_props.inputAttachmentDescriptorSize, ZINK_FBFETCH_DESCRIPTOR_SIZE); -@@ -3526,12 +3550,14 @@ zink_internal_create_screen(const struct - zink_init_screen_pipeline_libs(screen); - - if (!init_layouts(screen)) { -- mesa_loge("ZINK: failed to initialize layouts"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to initialize layouts"); - goto fail; - } - - if (!zink_descriptor_layouts_init(screen)) { -- mesa_loge("ZINK: failed to initialize descriptor layouts"); -+ if (!screen->implicitly_loaded) -+ mesa_loge("ZINK: failed to initialize descriptor layouts"); - goto fail; - } - -Index: mesa-24.0.3/src/gallium/drivers/zink/zink_types.h -=================================================================== ---- mesa-24.0.3.orig/src/gallium/drivers/zink/zink_types.h -+++ mesa-24.0.3/src/gallium/drivers/zink/zink_types.h -@@ -1408,6 +1408,7 @@ struct zink_screen { - bool is_cpu; - bool abort_on_hang; - bool frame_marker_emitted; -+ bool implicitly_loaded; - uint64_t curr_batch; //the current batch id - uint32_t last_finished; - VkSemaphore sem; diff --git a/0010-glx-silence-more-implicit-load-zink-errors.patch b/0010-glx-silence-more-implicit-load-zink-errors.patch deleted file mode 100644 index 832393f..0000000 --- a/0010-glx-silence-more-implicit-load-zink-errors.patch +++ /dev/null @@ -1,23 +0,0 @@ -From 5e99f24ee7d4aa9ff5178f63a79a8a313c32e44d Mon Sep 17 00:00:00 2001 -From: Mike Blumenkrantz -Date: Tue, 19 Mar 2024 08:37:47 -0400 -Subject: [PATCH] glx: silence more implicit-load zink errors - ---- - src/glx/drisw_glx.c | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) - -Index: mesa-24.0.5/src/glx/drisw_glx.c -=================================================================== ---- mesa-24.0.5.orig/src/glx/drisw_glx.c -+++ mesa-24.0.5/src/glx/drisw_glx.c -@@ -980,7 +980,8 @@ driswCreateScreenDriver(int screen, stru - extensions, - &driver_configs, implicit, psc); - if (psc->driScreen == NULL) { -- ErrorMessageF("glx: failed to create drisw screen\n"); -+ if (!pdpyp->zink || !implicit) -+ ErrorMessageF("glx: failed to create drisw screen\n"); - goto handle_error; - } - diff --git a/Mesa.changes b/Mesa.changes index fa058a9..8aab715 100644 --- a/Mesa.changes +++ b/Mesa.changes @@ -1,3 +1,40 @@ +------------------------------------------------------------------- +Fri Jun 14 09:24:21 UTC 2024 - Stefan Dirsch + +- Update to new feature release 24.1.0 + --> https://docs.mesa3d.org/relnotes/24.1.0 +- Some interesting highlights include: + * NVIDIA Vulkan driver NVK is now considered ready for prime time. + Distro packagers are now recommended to include `nouveau` in the + `vulkan-drivers` list so that their users can have the option of using it + instead of the proprietary NVIDIA driver. + * Intel Vulkan driver Anv switched to truly asynchronous VM bind, and Xe + support for error dump to debug GPU hangs was added. + * Apple OpenGL driver Asahi has reached OpenGL 4.6 and OpenGL ES 3.2 + support. + * Broadcom Vulkan driver V3DV gained support for VK_KHR_dynamic_rendering. + * Arm Mali OpenGL driver Panfrost was prepared for Gen10 (Gxxx), and + Vulkan driver PanVK was modernised for better Midgard (Txxx) and + Bifrost (Gxxx) support. + * All Vulkan drivers have gained support for explicit synchronisation on + Wayland and X11. +- adjusted patches: + * n_stop-iris-flicker.patch + * python36-buildfix1.patch +- supersedes patches: + * 0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch + * 0002-glx-fix-some-indentation.patch + * 0003-glx-add-an-implicit-param-to-createScreen.patch + * 0004-glx-pass-implicit-load-param-through-allocation.patch + * 0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch + * 0006-gbm-plumb-an-implicit-param-through-device-creation.patch + * 0007-frontends-dri-plumb-an-implicit-param-through-screen.patch + * 0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch + * 0009-zink-don-t-print-error-messages-when-failing-an-impl.patch + * 0010-glx-silence-more-implicit-load-zink-errors.patch +- added libvdpau_d3d12 package +- small cleanup in specfile + ------------------------------------------------------------------- Thu Jun 13 13:26:14 UTC 2024 - Stefan Dirsch diff --git a/Mesa.spec b/Mesa.spec index 814c9b9..e482a58 100644 --- a/Mesa.spec +++ b/Mesa.spec @@ -42,7 +42,7 @@ %define glamor 1 %define _name_archive mesa -%define _version 24.0.9 +%define _version 24.1.0 %define with_opencl 0 %define with_rusticl 0 %define with_vulkan 0 @@ -57,11 +57,15 @@ %define vdpau_nouveau 0 %define vdpau_radeon 0 %define vdpau_virtio_gpu 0 +%define vdpau_d3d12 0 %ifarch %{ix86} x86_64 aarch64 %{arm} ppc64 ppc64le riscv64 %define vdpau_nouveau 1 %define vdpau_radeon 1 %define vdpau_virtio_gpu 1 +%ifarch %{ix86} x86_64 + %define vdpau_d3d12 1 +%endif %endif %ifarch %{ix86} x86_64 @@ -118,12 +122,15 @@ # Not built because virtio_gpu driver is not built. %define vdpau_virtio_gpu 0 + # Not built because d3d12 driver is not built. + %define vdpau_d3d12 0 + # Vulkan includes radv driver which requires llvm %define with_vulkan 0 %endif Name: Mesa%{psuffix} -Version: 24.0.9 +Version: 24.1.0 Release: 0 Summary: System for rendering 3-D graphics License: MIT @@ -147,16 +154,6 @@ Patch54: n_drirc-disable-rgb10-for-chromium-on-amd.patch Patch58: u_dep_xcb.patch Patch100: U_fix-mpeg1_2-decode-mesa-20.2.patch Patch400: n_stop-iris-flicker.patch -Patch501: 0001-loader-delete-unused-param-from-pipe_loader_sw_probe.patch -Patch502: 0002-glx-fix-some-indentation.patch -Patch503: 0003-glx-add-an-implicit-param-to-createScreen.patch -Patch504: 0004-glx-pass-implicit-load-param-through-allocation.patch -Patch505: 0005-dri-plumb-a-implicit-param-through-createNewScreen-i.patch -Patch506: 0006-gbm-plumb-an-implicit-param-through-device-creation.patch -Patch507: 0007-frontends-dri-plumb-an-implicit-param-through-screen.patch -Patch508: 0008-pipe-loader-plumb-a-flag-for-implicit-driver-load-th.patch -Patch509: 0009-zink-don-t-print-error-messages-when-failing-an-impl.patch -Patch510: 0010-glx-silence-more-implicit-load-zink-errors.patch %ifarch %{ix86} x86_64 BuildRequires: DirectX-Headers %endif @@ -641,6 +638,13 @@ Group: System/Libraries %description -n libvdpau_virtio_gpu This package contains the VDPAU state tracker for VirtIO GPU. +%package -n libvdpau_d3d12 +Summary: VDPAU state tracker for d3d12 +Group: System/Libraries + +%description -n libvdpau_d3d12 +This package contains the VDPAU state tracker for d3d12 + %package -n Mesa-libOpenCL Summary: Mesa OpenCL implementation (Clover) Group: System/Libraries @@ -778,16 +782,6 @@ rm -rf docs/README.{VMS,WIN32,OS2} %patch -P 58 -p1 %patch -P 100 -p1 %patch -P 400 -p1 -%patch -P 501 -p1 -%patch -P 502 -p1 -%patch -P 503 -p1 -%patch -P 504 -p1 -%patch -P 505 -p1 -%patch -P 506 -p1 -%patch -P 507 -p1 -%patch -P 508 -p1 -%patch -P 509 -p1 -%patch -P 510 -p1 # Remove requires to vulkan libs from baselibs.conf on platforms # where vulkan build is disabled; ugly ... @@ -877,6 +871,8 @@ egl_platforms=x11,wayland %endif %ifarch %{ix86} x86_64 -Dgallium-drivers=r300,r600,radeonsi,nouveau,swrast,svga,virgl,iris,crocus,i915,d3d12,zink \ + -Dgallium-d3d12-video=enabled \ + -Dgallium-d3d12-graphics=enabled \ %else %ifarch %{arm} aarch64 -Dgallium-drivers=r300,r600,radeonsi,nouveau,swrast,virgl,freedreno,vc4,etnaviv,lima,panfrost,v3d,svga,tegra,zink \ @@ -1103,16 +1099,13 @@ echo "The \"Mesa\" package does not have the ability to render, but is supplemen %{_libdir}/vdpau/libvdpau_r600.so.1 %{_libdir}/vdpau/libvdpau_r600.so.1.0 %{_libdir}/vdpau/libvdpau_r600.so.1.0.0 -%endif -%ifarch %{ix86} x86_64 ppc64 ppc64le %{arm} aarch64 riscv64 %files -n libvdpau_radeonsi %{_libdir}/vdpau/libvdpau_radeonsi.so %{_libdir}/vdpau/libvdpau_radeonsi.so.1 %{_libdir}/vdpau/libvdpau_radeonsi.so.1.0 %{_libdir}/vdpau/libvdpau_radeonsi.so.1.0.0 %endif -%endif %if %{vdpau_virtio_gpu} %files -n libvdpau_virtio_gpu @@ -1122,6 +1115,15 @@ echo "The \"Mesa\" package does not have the ability to render, but is supplemen %{_libdir}/vdpau/libvdpau_virtio_gpu.so.1.0.0 %endif +%if %{vdpau_d3d12} +%files -n libvdpau_d3d12 +%{_libdir}/vdpau/libvdpau_d3d12.so +%{_libdir}/vdpau/libvdpau_d3d12.so.1 +%{_libdir}/vdpau/libvdpau_d3d12.so.1.0 +%{_libdir}/vdpau/libvdpau_d3d12.so.1.0.0 +%endif +%endif + %if "%{flavor}" != "drivers" %files libglapi0 %{_libdir}/libglapi.so.0* diff --git a/mesa-24.0.9.tar.xz b/mesa-24.0.9.tar.xz deleted file mode 100644 index e238ead..0000000 --- a/mesa-24.0.9.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:51aa686ca4060e38711a9e8f60c8f1efaa516baf411946ed7f2c265cd582ca4c -size 20197892 diff --git a/mesa-24.0.9.tar.xz.sig b/mesa-24.0.9.tar.xz.sig deleted file mode 100644 index 99eeb3bf62e6b3d464ca371d871c620f5fcb6af05d260ada3298bbee45556739..0000000000000000000000000000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 310 zcmV-60m=S}0W$;u0SEvc79j*zRUP45mXBjW!btXwjxn#pBq*i@0%l?eC;$ox5RHy8 zufrrLre7`x|8U_PtJRm}5x{Gk#<8dy7*fcJC7!Fpt`%PyT-LStI4Dg|Ou2Vj4HHp7qlZ&(tv0i$~ z0A*6+|9G$ZA4qsk!8PnD#djWMIGWb*hVOs(EFnE>)jX7D+X34xiIFW;)YVbSStJ-#-0whiDK0=Mm@abQVgK(UU zzms>|_IIeC777jUe#i&ty4#1sOh{R~u`t`K_?^QukC6CKmr-$1F+r6lyV$LS)C0_d z_JLj_vxbeo4i&-`7*#0a{;)0LJ}}K@W(NcDAeQ*_@Ms2>h&e!9t7|qcGJ}bz8_8>5 zGS*2gYG|K}9tgem_handle, - .offset = bo->address, -- .flags = bo->real.kflags | (written ? EXEC_OBJECT_WRITE : 0) | -- (iris_bo_is_external(bo) ? 0 : EXEC_OBJECT_ASYNC), -+ .flags = bo->real.kflags | (written ? EXEC_OBJECT_WRITE : 0), - }; - ++validation_count; - } +--- mesa-24.1.0.orig/src/gallium/drivers/iris/i915/iris_kmd_backend.c ++++ mesa-24.1.0/src/gallium/drivers/iris/i915/iris_kmd_backend.c +@@ -317,7 +317,6 @@ i915_batch_submit(struct iris_batch *bat + uint32_t flags = EXEC_OBJECT_SUPPORTS_48B_ADDRESS | EXEC_OBJECT_PINNED; + flags |= bo->real.capture ? EXEC_OBJECT_CAPTURE : 0; + flags |= bo == batch->screen->workaround_bo ? EXEC_OBJECT_ASYNC : 0; +- flags |= iris_bo_is_external(bo) ? 0 : EXEC_OBJECT_ASYNC; + flags |= written ? EXEC_OBJECT_WRITE : 0; + + index_for_handle[bo->gem_handle] = validation_count; diff --git a/python36-buildfix1.patch b/python36-buildfix1.patch index 782d9b4..21b5124 100644 --- a/python36-buildfix1.patch +++ b/python36-buildfix1.patch @@ -1,6 +1,8 @@ ---- mesa-23.3.3/src/nouveau/headers/class_parser.py.orig 2024-01-20 12:47:36.464476669 +0100 -+++ mesa-23.3.3/src/nouveau/headers/class_parser.py 2024-01-20 13:04:30.212851443 +0100 -@@ -9,6 +9,16 @@ +Index: mesa-24.1.0/src/nouveau/headers/class_parser.py +=================================================================== +--- mesa-24.1.0.orig/src/nouveau/headers/class_parser.py ++++ mesa-24.1.0/src/nouveau/headers/class_parser.py +@@ -9,6 +9,16 @@ import sys from mako.template import Template @@ -15,9 +17,9 @@ + return s + METHOD_ARRAY_SIZES = { - 'BIND_GROUP_CONSTANT_BUFFER' : 16, - 'CALL_MME_DATA' : 256, -@@ -273,7 +283,7 @@ + 'BIND_GROUP_CONSTANT_BUFFER' : 16, + 'CALL_MME_DATA' : 256, +@@ -293,7 +303,7 @@ def parse_header(nvcl, f): if ":" in list[2]: state = 1 elif teststr in list[1]: @@ -26,7 +28,7 @@ else: state = 1 -@@ -283,7 +293,7 @@ +@@ -303,7 +313,7 @@ def parse_header(nvcl, f): if ("0x" in list[2]): state = 1 else: @@ -35,7 +37,7 @@ bitfield = list[2].split(":") curmthd.field_name_start[field] = bitfield[1] curmthd.field_name_end[field] = bitfield[0] -@@ -304,13 +314,13 @@ +@@ -324,13 +334,13 @@ def parse_header(nvcl, f): is_array = 0 if (':' in list[2]): continue @@ -52,7 +54,7 @@ x = method() x.name = name x.addr = list[2] -@@ -336,8 +346,8 @@ +@@ -357,8 +367,8 @@ def main(): clheader = os.path.basename(args.in_h) nvcl = clheader