zink: set vkusage/vkflags for buffer resource objects

this needs to be populated for other places in the driver that need it

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20912>
This commit is contained in:
Mike Blumenkrantz
2023-01-25 11:19:07 -05:00
committed by Marge Bot
parent c545300f30
commit 3c562cfc06
+2
View File
@@ -686,6 +686,8 @@ resource_object_create(struct zink_screen *screen, const struct pipe_resource *t
flags = VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT | VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT;
obj->is_buffer = true;
obj->transfer_dst = true;
obj->vkflags = bci.flags;
obj->vkusage = bci.usage;
} else {
bool winsys_modifier = (export_types & VK_EXTERNAL_MEMORY_HANDLE_TYPE_DMA_BUF_BIT_EXT) && whandle && whandle->modifier != DRM_FORMAT_MOD_INVALID;
uint64_t mods[10];