zink: clamp zink_gfx_lib_cache::stages_present for generated tcs
this otherwise does not reflect reality
Fixes: d786f52f1f ("zink: prevent crash when freeing")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27358>
(cherry picked from commit 36e7350e0b86080bfcb3b6db481c89a97691dacb)
This commit is contained in:
parent
a9c5611b49
commit
10eb12968b
2 changed files with 3 additions and 1 deletions
|
|
@ -3214,7 +3214,7 @@
|
|||
"description": "zink: clamp zink_gfx_lib_cache::stages_present for generated tcs",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "d786f52f1ff10fba42e87530933a2a4c68de49a8",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -1006,6 +1006,8 @@ create_lib_cache(struct zink_gfx_program *prog, bool generated_tcs)
|
|||
{
|
||||
struct zink_gfx_lib_cache *libs = CALLOC_STRUCT(zink_gfx_lib_cache);
|
||||
libs->stages_present = prog->stages_present;
|
||||
if (generated_tcs)
|
||||
libs->stages_present &= ~BITFIELD_BIT(MESA_SHADER_TESS_CTRL);
|
||||
simple_mtx_init(&libs->lock, mtx_plain);
|
||||
if (generated_tcs)
|
||||
_mesa_set_init(&libs->libs, NULL, hash_pipeline_lib_generated_tcs, equals_pipeline_lib_generated_tcs);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue