zink: only use host mem for staging resources with linear tiling

VK_EXT_4444_formats strikes again

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9985>
This commit is contained in:
Mike Blumenkrantz 2021-02-03 17:29:24 -05:00 committed by Marge Bot
parent 6433661cda
commit a565ead64a
1 changed files with 1 additions and 1 deletions

View File

@ -429,7 +429,7 @@ resource_object_create(struct zink_screen *screen, const struct pipe_resource *t
}
vkGetImageMemoryRequirements(screen->dev, obj->image, &reqs);
if (templ->usage == PIPE_USAGE_STAGING)
if (templ->usage == PIPE_USAGE_STAGING && ici.tiling == VK_IMAGE_TILING_LINEAR)
flags = VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT;
else
flags = VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT;