zink: switch to passing VkPhysicalDeviceFeatures2 in VkDeviceCreateInfo
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Wed, 3 Jun 2020 12:45:57 +0000 (08:45 -0400)
committerMarge Bot <eric+marge@anholt.net>
Wed, 17 Jun 2020 20:42:01 +0000 (20:42 +0000)
extensions need to have their feature structs passed in pNext to be enabled,
so switch to using the feature struct here in preparation for that

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5163>

src/gallium/drivers/zink/zink_screen.c

index ee5ff5041031cce97c471cd7009efc4e8430961f..71b7345dc88d331d553743ca03e47ed5d19251b5 100644 (file)
@@ -829,7 +829,10 @@ zink_internal_create_screen(struct sw_winsys *winsys, int fd)
    dci.sType = VK_STRUCTURE_TYPE_DEVICE_CREATE_INFO;
    dci.queueCreateInfoCount = 1;
    dci.pQueueCreateInfos = &qci;
-   dci.pEnabledFeatures = &screen->feats;
+   /* extensions don't have bool members in pEnabledFeatures.
+    * this requires us to pass the whole VkPhysicalDeviceFeatures2 struct
+    */
+   dci.pNext = &feats;
    const char *extensions[4] = {
       VK_KHR_MAINTENANCE1_EXTENSION_NAME,
    };