anv/device: Add a boolean for robust buffer access
authorJason Ekstrand <jason.ekstrand@intel.com>
Sat, 14 May 2016 21:52:36 +0000 (14:52 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Fri, 20 May 2016 04:18:59 +0000 (21:18 -0700)
src/intel/vulkan/anv_device.c
src/intel/vulkan/anv_private.h

index 5b5b095f28d4834a42d30722b198c252872c9193..e9f555c9d117a773549c0ab18d3b388b6069e964 100644 (file)
@@ -848,6 +848,9 @@ VkResult anv_CreateDevice(
     */
    device->can_chain_batches = device->info.gen >= 8;
 
+   device->robust_buffer_access = pCreateInfo->pEnabledFeatures &&
+      pCreateInfo->pEnabledFeatures->robustBufferAccess;
+
    pthread_mutex_init(&device->mutex, NULL);
 
    anv_bo_pool_init(&device->batch_bo_pool, device);
index 33cbff9ff3a1b39d157353087eca81d5cc988466..953d95df2c13cc9633984c82c085df78dfff8a55 100644 (file)
@@ -678,6 +678,7 @@ struct anv_device {
     int                                         context_id;
     int                                         fd;
     bool                                        can_chain_batches;
+    bool                                        robust_buffer_access;
 
     struct anv_bo_pool                          batch_bo_pool;