iris: make sure to not mix compressed vs non-compressed
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run

This commit implements the following requirement:

   "Keep any UMD-recycling of compression-enabled/disabled
    memory separate."

As additional info there are 2 related wa's for the issue:

   Wa_14018443005
   Wa_18038669374

Cc: mesa-stable
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34499>
This commit is contained in:
Tapani Pälli 2025-04-14 09:47:25 +03:00 committed by Marge Bot
parent c2a4657862
commit 6d70ec449f

View file

@ -1038,6 +1038,12 @@ alloc_bo_from_cache(struct iris_bufmgr *bufmgr,
if (cur->real.capture != !!(flags & BO_ALLOC_CAPTURE))
continue;
/* Make sure we don't recycle compressed vs non-compressed. */
if ((iris_heap_is_compressed(flags_to_heap(bufmgr, flags))) !=
iris_heap_is_compressed(cur->real.heap)) {
continue;
}
/* If the last BO in the cache is busy, there are no idle BOs. Bail,
* either falling back to a non-matching memzone, or if that fails,
* allocating a fresh buffer.