Commit graph

209547 commits

Author SHA1 Message Date
Eric Engestrom
766909b321 docs: add sha sum for 25.2.8
Some checks failed
macOS-CI / macOS-CI (dri) (push) Has been cancelled
macOS-CI / macOS-CI (xlib) (push) Has been cancelled
2025-12-04 08:48:50 +01:00
Eric Engestrom
f97d7dcca0 VERSION: bump for 25.2.8 2025-12-04 08:30:32 +01:00
Eric Engestrom
f64c62f875 docs: add release notes for 25.2.8 2025-12-04 08:30:32 +01:00
Aitor Camacho
bbfd4afb78 vulkan/wsi: Fix double destroy of present_id_timeline at swapchain create
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Fixes: c888da3d48 ("vulkan/wsi: Add mechanism to wait for WSI semaphore unsignal.")

Reviewed-by: Hans-Kristian Arntzen <post@arntzen-software.no>
Signed-off-by: Aitor Camacho <aitor@lunarg.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38754>
(cherry picked from commit df19ec3020)
2025-12-03 11:34:51 +01:00
Samuel Pitoiset
99cd75fd5a radv: reduce maxTexelBufferElements to 1<<29
It's the number of elements. RADV exposes VK_FORMAT_R64_{UINT,SINT}
formats for texel buffers, so the maximum is 1<<29 to fit in the
32-bit bounds checking.

Fixes KHR-GL46.texture_buffer_size_clamping.* with Zink and new VKCTS
dEQP-VK.texture.misc.max_elements.*.

Cc: mesa-stable.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38140>
(cherry picked from commit fda1262eed)
2025-12-03 11:34:51 +01:00
Ian Romanick
8650b613ca lavapipe: fp16 flrp must also be lowered
Prevents failures with fp16 in lavapipe and Zink on lavapipe when
"nir/lower_flrp: Check and set shader_info::flrp_lowered" is
applied. Lowering with an incomplete mask on the first call to
nir_lower_flrp will prevent later calls (with the complete mask) from
doing anything.

Fixes: b38879f8c5 ("vallium: initial import of the vulkan frontend")
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12526>
(cherry picked from commit 341e2d3283)
2025-12-03 11:34:51 +01:00
Aitor Camacho
5153a5d8c1 vulkan/cmd_queue: Use vk_strdup and free allocated string memory
Fixes: 9082715ab0 ("vk/cmd_queue: generate copies for string struct members")

Reviewed-by: Karmjit Mahil <karmjit.mahil@igalia.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Signed-off-by: Aitor Camacho <aitor@lunarg.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38634>
(cherry picked from commit 16c98f4f18)
2025-12-03 11:34:51 +01:00
Natalie Vock
1846c7cc9b radv: Move VMID reservation to vkCreateDevice
DXVK's DXGI implementation can create extra instances used for
enumerating physical devices besides the games' instance. When reserving
VMIDs for SPM, the DXGI instances may snatch the VMID reservation early,
making VMID reservation for the instance that actually needs it fail.
This starts being a problem on kernels 6.18+ where only one user may
reserve a VMID at a time.

Move reserving VMIDs to SQTT initialization inside vkCreateDevice so
that only the instances that actually create logical devices try
reserving VMIDs.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38746>
(cherry picked from commit a7a4abc8d8)
2025-12-03 11:34:51 +01:00
Benjamin Cheng
a72e8eefa1 radv/video: Override direct_spatial_mv_pred to 1
VCN always uses spatial direct mode.

Cc: mesa-stable
Reviewed-by: David Rosca <david.rosca@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38686>
(cherry picked from commit 9e37969179)
2025-12-03 11:34:51 +01:00
Benjamin Cheng
540dd28ad0 radv/video: Fix H264/H265 reference selection
The order of pReferenceSlots is not well-defined by spec. Instead we
need to look at the RefPicList0/1 which provides slot indices.

Cc: mesa-stable
Reviewed-by: David Rosca <david.rosca@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38686>
(cherry picked from commit ab56ce154b)
2025-12-03 11:34:51 +01:00
Benjamin Cheng
6619a8ad51 radv/video: Fix num_ref_idx_l{0,1} related overrides
Since we only support 1 L0/L1 ref, the default num refs in the PPS
should always be 0. With that there never any need to set the override
flag in the slice header (until more references are supported).
Also the ref pic list modifications should be clamped to the size of the
ref pic list.

This fixes an issue seen with dEQP-VK.video.encode.h264.i_p_b_13_*.

Cc: mesa-stable
Reviewed-by: David Rosca <david.rosca@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38686>
(cherry picked from commit 2e21eec921)
2025-12-03 11:34:51 +01:00
Calder Young
4ae7a2b3de intel: Fix calculation of max_scratch_ids on fused devices
The subslice IDs provided by the SR0.0 EU register are not adjusted to account
for fusing, so the upper bound max_scratch_ids can vary from device to device
depending on what specific slices were fused during manufacturing.

Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38689>
(cherry picked from commit c0d809820f)
2025-12-03 11:34:51 +01:00
Tapani Pälli
c06671291f anv: add furmark workaround layer
Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14274
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38410>
(cherry picked from commit ba89826b75)
2025-12-03 11:34:51 +01:00
Timothy Arceri
b87eb92752 util/driconf: Add linux version of Penumbra fixes
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38563>
(cherry picked from commit d10036362f)
2025-12-03 11:34:51 +01:00
Emma Anholt
701ee045bf tu: Fix leak of compute shader pipeline->base.executables_mem_ctx;
Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14358
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38684>
(cherry picked from commit 89da258e71)
2025-12-03 11:34:51 +01:00
Calder Young
300cb6962a anv: Fix ray query shadow stack buffer size
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38685>
(cherry picked from commit 09e8a54087)
2025-12-03 11:34:50 +01:00
Ian Romanick
53e9ba2b61 brw: Force allow_spilling when spill_all is set
This ensures that g0 is reserved for spilling since there is going to be
spilling.

Fixes: 8bca7e520c ("intel/brw: Only force g0's liveness to be the whole program if spilling")
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37827>
(cherry picked from commit 1fc2f52d36)
2025-12-03 11:34:50 +01:00
Natalie Vock
c31904ab25 radv/rt: Correctly copy culling flags when updating to separate AS
This was missing and led to the field being uninitialized.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38488>
(cherry picked from commit b7f011e653)
2025-12-03 11:34:50 +01:00
Natalie Vock
3047d4abb1 radv/rt: Keep updated nodes always active
In updateable AS, we keep all nodes active even if they're
degenerate/NaN, because too many games ignore API rules about not
making inactive nodes active (and some vendor tips outright advise this
behavior). We also need to match this by keeping everything active in
the update side. The ALWAYS_ACTIVE macro has been long removed and
replaced by VK_BVH_BUILD_FLAG, too. Since updating only happens to
updateable AS, don't even check for the flag, just implement the
always-active handling.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38488>
(cherry picked from commit bc1eea90b9)
2025-12-03 11:34:50 +01:00
Lionel Landwerlin
90c11540ea nir/lower_printf: fix missing singleton add
If we're using the singleton, we need to add to it.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38638>
(cherry picked from commit 4b9aa9dc91)
2025-12-03 11:34:50 +01:00
Lionel Landwerlin
235e72ca16 nir/lower_printf: fix array alignment
The pointer arithmetic doesn't need a 4byte alignment, otherwise
everything is broken.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38638>
(cherry picked from commit d24633023f)
2025-12-03 11:34:50 +01:00
Lionel Landwerlin
1951e60185 spirv: fix printf generation
Not having the uses_printf will drop the printf info in serialization.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38638>
(cherry picked from commit 67faf6dfbd)
2025-12-03 11:34:50 +01:00
Lionel Landwerlin
21043e33d3 nir: fix lower_printf with no arguments
SPIRV generated printf with no arguments have an undef source (not the
expected deref).

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38638>
(cherry picked from commit 6940b8fcd7)
2025-12-03 11:34:50 +01:00
Sushma Venkatesh Reddy
1febe35f10 drirc: Add anv_assume_full_subgroups for Detroit: Become Human
Add workaround to assume full 32-thread subgroups. This fixes rendering
corruption when running the Detriot: Become Human game using anv driver.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14120

Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38670>
(cherry picked from commit 36d7cd0514)
2025-12-03 11:34:50 +01:00
Valentine Burley
b3a0fa30f7 egl: Disable kopper on Android
Kopper is not supported on Android, and attempting to use it breaks zink
on the platform.

Disable kopper automatically when running on Android, fixing zink without
`LIBGL_KOPPER_DISABLE`.

Fixes: 3294cad341 ("egl: Rename dri2_detect_swrast() and also detect kopper")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14331
Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Antonio Ospite <antonio.ospite@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38626>
(cherry picked from commit 8a1ea724b4)
2025-12-03 11:34:50 +01:00
Samuel Pitoiset
0b4e4c4231 radv: fix per-submit RGP captures on video queues
SQTT user data packets aren't supported either.

Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38575>
(cherry picked from commit af461de026)
2025-12-03 11:34:50 +01:00
Faith Ekstrand
4e1069e7a5 vulkan/drm-syncobj: Stop returning early waiting for sync files
In the WAIT_ALL case in spin_wait_for_sync_file(), we were returning the
moment we saw the first success.  However, this isn't a wait-all, it's a
bad wait-any.  We should instead just continue on to check the next sync
until we've ensured that every sync in the array has a sync file.  The
only reason this wasn't blowing up in our face is because it only
affects non-timeline drivers (pretty rare these days) and because most
of the places where we use WAIT_PENDING on non-timeline drivers is to
guard a sync file export and those typically have only a single sync in
the array.

Cc: mesa-stable
Reviewed-by: Gurchetan Singh <gurchetansingh@google.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38635>
(cherry picked from commit e4e619d685)
2025-12-03 11:34:50 +01:00
Tapani Pälli
17f6c783c2 drirc: set intel_disable_threaded_context for Amnesia The Bunker
Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14084
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38567>
(cherry picked from commit 21f646d196)
2025-12-03 11:34:49 +01:00
Tapani Pälli
007cefe58b drirc/iris: add drirc to disable threaded context
Cc: mesa-stable
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38567>
(cherry picked from commit 4daabf76b4)
2025-12-03 11:34:49 +01:00
Ian Forbes
a8388e6eb2 svga: Check if Stencil buffer is NULL
Fixes a nullptr dereference on older HW versions.

Fixes: f29d939824 ("svga: rework framebuffer state")
Signed-off-by: Ian Forbes <ian.forbes@broadcom.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38623>
(cherry picked from commit 4e16a5b68b)
2025-12-03 11:34:49 +01:00
Patrick Lerda
e05a6d7628 r600: fix error filters compatibility
The shader-db functionality was interfering with the error
filters.

Two new options are added: R600_DEBUG=shaderdb and
R600_DEBUG=precompile. The option precompile is added
to maintain the compatibility with the shader-db repository.

This change fixes 22 of these tests:
deqp-gles31/functional/debug/error_filters/case_.*: warn pass
deqp-gles31/functional/debug/error_groups/case_.*: warn pass

Fixes: 28d6a5af25 ("r600: Add shader precompile and shader-db support.")
Signed-off-by: Patrick Lerda <patrick9876@free.fr>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38485>
(cherry picked from commit f005c0b5ad)
2025-12-03 11:34:49 +01:00
Lionel Landwerlin
b017ebd408 brw: compute final copy propagation resulting source
Fixes this test on Xe2+:

INTEL_DEBUG=no32 ./deqp-vk -n dEQP-VK.spirv_assembly.instruction.maint9_vectorization.bit_field_u_extract.result_v16i-base_v16i-offset_s64u-count_s16i

Generate invalid code for that platform:

and(16)         g37<1>UW        g65<16,4,4>UW   0x000fUW        { align1 1H I@5 };
	ERROR: Invalid register region for source 0.  See special restrictions section.

Several helpers like has_subdword_integer_region_restriction() do not
see the final type of the source, so compute it early.

Maybe new_src could be used in more cases. Being conservative for now.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38548>
(cherry picked from commit 8f9acc0150)
2025-12-03 11:34:49 +01:00
Dave Airlie
adbaaf291c dozen: return INCOMPATIBLE_DRIVER on instance create failure
When probing on generic Linux platforms, the loading of d3d12 and
the first init of could fail, but the error returned causes a
loader warning to be printed.

Use the correct error return to stop this.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38611>
(cherry picked from commit c00b66fa71)
2025-12-03 11:34:49 +01:00
Eric Engestrom
6872db98fb meson: auto-disable draw-use-llvm when llvm=disabled
The option's description is:
> Whether to use LLVM for the Gallium draw module, if LLVM is included.

Let's disable it right away if LLVM is disabled, to avoid some
configurations from failing.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38558>
(cherry picked from commit 37c7d19e46)
2025-12-03 11:34:49 +01:00
Eric Engestrom
0cbf8cc0ca meson: auto-disable amd-use-llvm when llvm=disabled
The option's description is:
> Whether to use LLVM for the AMD drivers, if LLVM is included.

Let's disable it right away if LLVM is disabled, to avoid configurations
like the one in the issue below from failing.

Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14306
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38558>
(cherry picked from commit 69bb927ebf)
2025-12-03 11:34:49 +01:00
Rob Clark
a4350c69b4 freedreno/a6xx: Fix UB in convert_color()
Swizzle can include PIPE_SWIZZLE_0/_1 (4 and 5) which result in indexing
beyond the channel array.

Reported-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Fixes: 76e350671f ("freedreno/a6xx: Sysmem clear fixes")
Signed-off-by: Rob Clark <rob.clark@oss.qualcomm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38593>
(cherry picked from commit f0465ced7f)
2025-12-03 11:34:49 +01:00
Anna Maniscalco
bc639539af radv: recalculate legacy_gs_info on bind
Previously legacy_gs_info calculated based on
gs_info->legacy_gs_info.esgs_itemsize which is calculated based on gs
input varyings.

However, when using ESO vs/tes can have outputs not read by gs, which
leads to underestimating LDS usage.

Cc: mesa-stable
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38514>
(cherry picked from commit 5e8885a339)
2025-12-03 11:34:49 +01:00
Daniel Schürmann
0f909636cc radv/shader_info: rename gs_ring_info -> legacy_gs_info and use union with ngg_info
Reduces the size of radv_shader_info from 784 bytes to 760 bytes.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37931>
(cherry picked from commit e1bcbbf3dd)
2025-12-03 11:34:49 +01:00
Matt Turner
23be36fc01 meson: Fix sysprof-capture-4 dependency
The versioning scheme changed in v45.0 (the previous version was
3.48.0). As such, this version check would wrongly accept e.g. 48.0.

Fixes: e9341568fa ("meson: require sysprof-capture-4 >= 4.49.0")
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38557>
(cherry picked from commit ad14942300)
2025-12-03 11:34:48 +01:00
Pierre-Eric Pelloux-Prayer
0a416fb949 radeonsi/sqtt: clear out sqtt bo on resize
If the resizing fails, we shouldn't use the destroyed bo anymore.

Fixes: 5794a86f19 ("radeonsi/sqtt: support sqtt buffer auto-resizing")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38529>
(cherry picked from commit bac9d17ead)
2025-12-03 11:34:48 +01:00
Lionel Landwerlin
e2cb355e57 anv: Wa_18040903259 only applies to RCS when in GPGPU mode
Sadly this probably won't change anything in terms of perf as the CCS
engine has a bunch of other restrictions.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Fixes: 243c01c703 ("anv/iris: implement Wa_18040903259")
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38484>
(cherry picked from commit 07b7de35cc)
2025-12-03 11:34:48 +01:00
Yiwei Zhang
9766bc29a6 venus: fix racy semaphore feedback counter update
Previously, we update the sfb dst slot upon vn_SignalSemaphore so that
vn_GetSemaphoreCounterValue can poll just the feedback slot itself.
However, that can race with pending sfb cmds that are going to update
the slot value, ending up with stuck sync progression.

This change fixes it by disallowing vn_SignalSemaphore to touch the sfb
dst slot. To ensure counter query being monotonic, vn_GetSemaphoreCounterValue
now takes the greater of signaled counter and the sfb counter read.

Test with dEQP-VK.synchronization* group:
- w/o this: stuck shows up within 2 min with 8 parallel deqp runs
- with this: no stuck for multiple full runs of the same

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14304
Fixes: 5c7e60362c ("venus: enable timeline semaphore feedback")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38516>
(cherry picked from commit 829bd406c0)
2025-12-03 11:34:48 +01:00
Mel Henning
cb76136f7b zink: Lock around screen_debug_marker_{begin,end}
vkQueueBeginDebugUtilsLabelEXT and vkQueueEndDebugUtilsLabelEXT
require queue to be externally synchronized, which means these functions
require the lock. Unfortunately, there's no guarantee that the debug
markers will be matched in the multithreaded case, but I suppose this is
better than crashing.

Fixes: 015eda4a41 ("zink: deduplicate VkDevice and VkInstance")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38414>
(cherry picked from commit 80db8171de)
2025-12-03 11:34:48 +01:00
Mel Henning
dfab270cd5 zink: Lock queue_lock in zink_destroy_screen
Fixes: 015eda4a41 ("zink: deduplicate VkDevice and VkInstance")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38414>
(cherry picked from commit 018178842e)
2025-12-03 11:34:48 +01:00
Mel Henning
bdfbd3f374 zink: Create one queue lock per device
We currently only create one queue per queue family on the device. The
device can be shared between multiple zink_screens, so having one lock
per screen can still lead to multiple locks per queue. Fix this by
allocating queue_lock along with the device.

This fixes an issue that was causing crashes with nvk+zink and
QtWebEngine with QTWEBENGINE_FORCE_USE_GBM=1 This can be reproduced by
resizing the window in either:

 * anki - https://apps.ankiweb.net/ or
 * Qt's simplebrowser example
   https://doc.qt.io/qt-6/qtwebengine-webenginewidgets-simplebrowser-example.html

which would then cause this dmesg error:

    nouveau 0000:01:00.0: anki[92007]: Failed to find syncobj (-> in): handle=40

along with a context loss.
With VK_LOADER_LAYERS_ENABLE=VK_LAYER_KHRONOS_validation we would additionally
get warnings like:

    Validation Error: [ UNASSIGNED-Threading-MultipleThreads-Write ] | MessageID = 0xa05b236e
    vkQueueSubmit(): THREADING ERROR : object of type VkQueue is simultaneously used in current thread 139824449189568 and thread 139823901816512
    Objects: 1
        [0] VkQueue 0x557a666783e0

Fixes: 015eda4a41 ("zink: deduplicate VkDevice and VkInstance")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38414>
(cherry picked from commit 9acce36652)
2025-12-03 11:34:48 +01:00
Mel Henning
9d81ccd4e1 zink: Make screen->queue_lock a pointer
Fixes: 015eda4a41 ("zink: deduplicate VkDevice and VkInstance")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38414>
(cherry picked from commit dff1b9d4e9)
2025-12-03 11:34:48 +01:00
Mel Henning
2a99b939dc zink: Return zink_device in create_logical_device
Fixes: 015eda4a41 ("zink: deduplicate VkDevice and VkInstance")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38414>
(cherry picked from commit f0dc8c0224)
2025-12-03 11:34:48 +01:00
Eric R. Smith
5236fb1683 pan: fix a bifrost disassembly assert failure
We were overflowing an array during bifrost disassembly. This was
only a problem if the user explicitly set an environment variable,
so unlikely to occur in casual use, and also only could be triggered
in very specific, dense code. But we still should get this right!

The specific CTS test that caused the assert is:

'dEQP-VK.graphicsfuzz.stable-quicksort-for-loop-with-injection'

with environment variable `BIFROST_MESA_DEBUG=shaders`. One of the
shaders has a clause with 6 constants (the maximum) and this overflowed
the array because we assume we always have an extra slot (used for
modifier processing).

Cc: mesa-stable
Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38501>
(cherry picked from commit 65ba14519e)
2025-12-03 11:34:48 +01:00
David Rosca
00c1f3aef2 radeonsi/vcn: Reduce allocated size for pre-encode recon pics
We use 4x downscale for pre-encode, so we don't need full size
pre-encode reconstructed pictures.

Cc: mesa-stable
Reviewed-by: Benjamin Cheng <benjamin.cheng@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38303>
(cherry picked from commit 1f83e73145)

[Eric: zero-initialised the two new vars, as per
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38303#note_3201571]
2025-12-03 11:34:47 +01:00
Jianxun Zhang
c49a441bea isl: Disable BMG Modifier (xe2)
This change disables BMG modifier effectively on and vulkan
driver. Iris has its own modifier selection and we haven't
had such failures in GL so far.

LNL platform doens't seem affected.

It workarounds issues with these signatures on 25.2.x:

1) Color strips, text misrendering on Gnome applications like
ptyxis. A GPU hang also occurs with the misrendering.

2) Applying INTEL_DEBUG=noccs makes these issues disappear.

3) Reverting a9aad4565f makes
these issues disappear too.

Troubleshooting similar issues on BMG would be easier with this
revert:
https://gitlab.freedesktop.org/mesa/mesa/-/issues/13759
https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/6097

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13868

Signed-off-by: Jianxun Zhang <jianxun.zhang@intel.com>
Acked-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38415>
2025-12-03 11:34:47 +01:00