mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-06-18 19:28:24 +02:00
anv: Use anv_device_get_bindless_surface_state_pool()
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: José Roberto de Souza <jose.souza@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/42133>
This commit is contained in:
parent
9713a94ca3
commit
9ef38baad8
5 changed files with 9 additions and 9 deletions
|
|
@ -95,12 +95,12 @@ anv_DestroyBufferView(VkDevice _device, VkBufferView bufferView,
|
|||
return;
|
||||
|
||||
if (view->general.state.alloc_size > 0) {
|
||||
anv_state_pool_free(&device->bindless_surface_state_pool,
|
||||
anv_state_pool_free(anv_device_get_bindless_surface_state_pool(device),
|
||||
view->general.state);
|
||||
}
|
||||
|
||||
if (view->storage.state.alloc_size > 0) {
|
||||
anv_state_pool_free(&device->bindless_surface_state_pool,
|
||||
anv_state_pool_free(anv_device_get_bindless_surface_state_pool(device),
|
||||
view->storage.state);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -157,7 +157,7 @@ decode_get_bo(void *v_batch, bool ppgtt, uint64_t address)
|
|||
if (get_bo_from_pool(&ret_bo, &anv_device_get_scratch_surface_state_pool(device)->block_pool, address))
|
||||
return ret_bo;
|
||||
if (device->physical->indirect_descriptors &&
|
||||
get_bo_from_pool(&ret_bo, &device->bindless_surface_state_pool.block_pool, address))
|
||||
get_bo_from_pool(&ret_bo, &anv_device_get_bindless_surface_state_pool(device)->block_pool, address))
|
||||
return ret_bo;
|
||||
if (get_bo_from_pool(&ret_bo, &anv_device_get_internal_surface_state_pool(device)->block_pool, address))
|
||||
return ret_bo;
|
||||
|
|
@ -1049,7 +1049,7 @@ VkResult anv_CreateDevice(
|
|||
* structures to zero and they have a valid descriptor.
|
||||
*/
|
||||
device->null_surface_state =
|
||||
anv_state_pool_alloc(&device->bindless_surface_state_pool,
|
||||
anv_state_pool_alloc(anv_device_get_bindless_surface_state_pool(device),
|
||||
device->isl_dev.ss.size,
|
||||
device->isl_dev.ss.align);
|
||||
isl_null_fill_state(&device->isl_dev, device->null_surface_state.map,
|
||||
|
|
|
|||
|
|
@ -295,17 +295,17 @@ anv_image_view_finish(struct anv_image_view *iview)
|
|||
if (!iview->use_surface_state_stream) {
|
||||
for (uint32_t plane = 0; plane < iview->n_planes; plane++) {
|
||||
if (iview->planes[plane].optimal_sampler.state.alloc_size) {
|
||||
anv_state_pool_free(&device->bindless_surface_state_pool,
|
||||
anv_state_pool_free(anv_device_get_bindless_surface_state_pool(device),
|
||||
iview->planes[plane].optimal_sampler.state);
|
||||
}
|
||||
|
||||
if (iview->planes[plane].general_sampler.state.alloc_size) {
|
||||
anv_state_pool_free(&device->bindless_surface_state_pool,
|
||||
anv_state_pool_free(anv_device_get_bindless_surface_state_pool(device),
|
||||
iview->planes[plane].general_sampler.state);
|
||||
}
|
||||
|
||||
if (iview->planes[plane].storage.state.alloc_size) {
|
||||
anv_state_pool_free(&device->bindless_surface_state_pool,
|
||||
anv_state_pool_free(anv_device_get_bindless_surface_state_pool(device),
|
||||
iview->planes[plane].storage.state);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2904,7 +2904,7 @@ anv_device_maybe_alloc_surface_state(struct anv_device *device,
|
|||
if (device->physical->indirect_descriptors) {
|
||||
if (surface_state_stream)
|
||||
return anv_state_stream_alloc(surface_state_stream, 64, 64);
|
||||
return anv_state_pool_alloc(&device->bindless_surface_state_pool, 64, 64);
|
||||
return anv_state_pool_alloc(anv_device_get_bindless_surface_state_pool(device), 64, 64);
|
||||
} else {
|
||||
return ANV_STATE_NULL;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -412,7 +412,7 @@ setup_execbuf_for_cmd_buffers(struct anv_execbuf *execbuf,
|
|||
return result;
|
||||
|
||||
if (device->physical->va.bindless_surface_state_pool.size > 0) {
|
||||
result = pin_state_pool(device, execbuf, &device->bindless_surface_state_pool);
|
||||
result = pin_state_pool(device, execbuf, anv_device_get_bindless_surface_state_pool(device));
|
||||
if (result != VK_SUCCESS)
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue