summaryrefslogtreecommitdiffstats
path: root/src/vulkan/anv_device.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2015-11-10 16:42:34 -0800
committerJason Ekstrand <[email protected]>2015-11-10 16:42:34 -0800
commit3a3d79b38e27babab7c5b2d79032e0879d6a7c44 (patch)
tree909b71095405b06c578e79ea45b86c5d20781dcf /src/vulkan/anv_device.c
parent750b8f9e983832c8725ac2e7a040470959a3d8f2 (diff)
anv/gen7: Implement the VS state depth-stall workaround
Diffstat (limited to 'src/vulkan/anv_device.c')
-rw-r--r--src/vulkan/anv_device.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/vulkan/anv_device.c b/src/vulkan/anv_device.c
index 3c6760b832d..1328516c48e 100644
--- a/src/vulkan/anv_device.c
+++ b/src/vulkan/anv_device.c
@@ -667,6 +667,8 @@ VkResult anv_CreateDevice(
anv_state_pool_init(&device->surface_state_pool,
&device->surface_state_block_pool);
+ anv_bo_init_new(&device->workaround_bo, device, 1024);
+
anv_block_pool_init(&device->scratch_block_pool, device, 0x10000);
device->info = *physical_device->info;
@@ -705,6 +707,9 @@ void anv_DestroyDevice(
anv_state_pool_free(&device->dynamic_state_pool, device->border_colors);
#endif
+ anv_gem_munmap(device->workaround_bo.map, device->workaround_bo.size);
+ anv_gem_close(device, device->workaround_bo.gem_handle);
+
anv_bo_pool_finish(&device->batch_bo_pool);
anv_state_pool_finish(&device->dynamic_state_pool);
anv_block_pool_finish(&device->dynamic_state_block_pool);