iris/resource: Assert that DG2 CCS buffers don't also try to set BO_ALLOC_SMEM

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17349>
This commit is contained in:
Jordan Justen 2022-05-16 02:35:11 -07:00 committed by Marge Bot
parent 7bd3a6b757
commit b79da470f2
1 changed files with 3 additions and 1 deletions

View File

@ -471,8 +471,10 @@ iris_resource_alloc_flags(const struct iris_screen *screen,
PIPE_RESOURCE_FLAG_MAP_PERSISTENT))
flags |= BO_ALLOC_SMEM;
if (screen->devinfo.verx10 >= 125 && isl_aux_usage_has_ccs(aux_usage))
if (screen->devinfo.verx10 >= 125 && isl_aux_usage_has_ccs(aux_usage)) {
assert((flags & BO_ALLOC_SMEM) == 0);
flags |= BO_ALLOC_LMEM;
}
if ((templ->bind & PIPE_BIND_SHARED) ||
util_format_get_num_planes(templ->format) > 1)