iris/resource: Check devinfo::has_local_mem before using BO_ALLOC_LMEM
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Nanley Chery <nanley.g.chery@intel.com> Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20322>
This commit is contained in:
@@ -471,7 +471,8 @@ 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 && screen->devinfo->has_local_mem &&
|
||||
isl_aux_usage_has_ccs(aux_usage)) {
|
||||
assert((flags & BO_ALLOC_SMEM) == 0);
|
||||
flags |= BO_ALLOC_LMEM;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user