v3dv: Switch to v3d_X(..)

Use the common helper.

Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Acked-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32277>
This commit is contained in:
Christian Gmeiner
2024-11-05 09:51:37 +01:00
committed by Marge Bot
parent 3b4636c769
commit 5d186d1386
12 changed files with 110 additions and 126 deletions
+37 -37
View File
@@ -518,7 +518,7 @@ v3dv_job_start_frame(struct v3dv_job *job,
return;
}
v3dv_X(job->device, job_emit_binning_prolog)(job, tiling,
v3d_X((&job->device->devinfo), job_emit_binning_prolog)(job, tiling,
allocate_tile_state_for_all_layers ? tiling->layers : 1);
job->ez_state = V3D_EZ_UNDECIDED;
@@ -561,7 +561,7 @@ cmd_buffer_end_render_pass_frame(struct v3dv_cmd_buffer *cmd_buffer)
job->frame_tiling.msaa,
true);
v3dv_X(job->device, job_emit_enable_double_buffer)(job);
v3d_X((&job->device->devinfo), job_emit_enable_double_buffer)(job);
}
/* At this point we have decided whether we want to use double-buffer or
@@ -570,12 +570,12 @@ cmd_buffer_end_render_pass_frame(struct v3dv_cmd_buffer *cmd_buffer)
*/
v3dv_job_allocate_tile_state(job);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_render_pass_rcl)(cmd_buffer);
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_render_pass_rcl)(cmd_buffer);
}
/* Only emit the binning flush for the last job in resume/suspend chain */
if (!job->suspending)
v3dv_X(cmd_buffer->device, job_emit_binning_flush)(job);
v3d_X((&cmd_buffer->device->devinfo), job_emit_binning_flush)(job);
}
struct v3dv_job *
@@ -699,7 +699,7 @@ v3dv_cmd_buffer_finish_job(struct v3dv_cmd_buffer *cmd_buffer)
cmd_buffer_end_render_pass_frame(cmd_buffer);
} else {
assert(job->type == V3DV_JOB_TYPE_GPU_CL_INCOMPLETE);
v3dv_X(cmd_buffer->device, cmd_buffer_end_render_pass_secondary)(cmd_buffer);
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_end_render_pass_secondary)(cmd_buffer);
}
}
@@ -1216,11 +1216,11 @@ cmd_buffer_state_set_attachment_clear_color(struct v3dv_cmd_buffer *cmd_buffer,
uint32_t internal_type, internal_bpp;
const struct v3dv_format *format =
v3dv_X(cmd_buffer->device, get_format)(attachment->desc.format);
v3d_X((&cmd_buffer->device->devinfo), get_format)(attachment->desc.format);
/* We don't allow multi-planar formats for render pass attachments */
assert(format->plane_count == 1);
v3dv_X(cmd_buffer->device, get_internal_type_bpp_for_output_format)
v3d_X((&cmd_buffer->device->devinfo), get_internal_type_bpp_for_output_format)
(format->planes[0].rt_type, &internal_type, &internal_bpp);
uint32_t internal_size = 4 << internal_bpp;
@@ -1228,7 +1228,7 @@ cmd_buffer_state_set_attachment_clear_color(struct v3dv_cmd_buffer *cmd_buffer,
struct v3dv_cmd_buffer_attachment_state *attachment_state =
&cmd_buffer->state.attachments[attachment_idx];
v3dv_X(cmd_buffer->device, get_hw_clear_color)
v3d_X((&cmd_buffer->device->devinfo), get_hw_clear_color)
(color, internal_type, internal_size, &attachment_state->clear_value.color[0]);
attachment_state->vk_clear_value.color = *color;
@@ -1753,7 +1753,7 @@ cmd_buffer_subpass_create_job(struct v3dv_cmd_buffer *cmd_buffer,
uint8_t max_internal_bpp, total_color_bpp;
bool msaa;
v3dv_X(job->device, framebuffer_compute_internal_bpp_msaa)
v3d_X((&job->device->devinfo), framebuffer_compute_internal_bpp_msaa)
(framebuffer, state->attachments, subpass,
&max_internal_bpp, &total_color_bpp, &msaa);
@@ -2084,7 +2084,7 @@ v3dv_CmdExecuteCommands(VkCommandBuffer commandBuffer,
V3DV_FROM_HANDLE(v3dv_cmd_buffer, primary, commandBuffer);
if (primary->state.pass != NULL) {
v3dv_X(primary->device, cmd_buffer_execute_inside_pass)
v3d_X((&primary->device->devinfo), cmd_buffer_execute_inside_pass)
(primary, commandBufferCount, pCommandBuffers);
} else {
cmd_buffer_execute_outside_pass(primary,
@@ -2258,7 +2258,7 @@ v3dv_CmdSetViewport(VkCommandBuffer commandBuffer,
pViewports);
for (uint32_t i = firstViewport; i < total_count; i++) {
v3dv_X(cmd_buffer->device, viewport_compute_xform)
v3d_X((&cmd_buffer->device->devinfo), viewport_compute_xform)
(&dyn->vp.viewports[i], v3dv_dyn->viewport.scale[i],
v3dv_dyn->viewport.translate[i]);
}
@@ -2368,7 +2368,7 @@ emit_scissor(struct v3dv_cmd_buffer *cmd_buffer)
cmd_buffer->state.clip_window.extent.width = maxx - minx;
cmd_buffer->state.clip_window.extent.height = maxy - miny;
v3dv_X(cmd_buffer->device, job_emit_clip_window)
v3d_X((&cmd_buffer->device->devinfo), job_emit_clip_window)
(cmd_buffer->state.job, &cmd_buffer->state.clip_window);
BITSET_CLEAR(vk_dyn->dirty, MESA_VK_DYNAMIC_VP_SCISSORS);
@@ -2981,7 +2981,7 @@ v3dv_cmd_buffer_emit_pre_draw(struct v3dv_cmd_buffer *cmd_buffer,
struct v3dv_device *device = cmd_buffer->device;
if (dirty_uniform_state || (*dirty & V3DV_CMD_DIRTY_VERTEX_BUFFER))
v3dv_X(device, cmd_buffer_emit_gl_shader_state)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_gl_shader_state)(cmd_buffer);
if (*dirty & (V3DV_CMD_DIRTY_PIPELINE) ||
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_RS_CULL_MODE) ||
@@ -2990,11 +2990,11 @@ v3dv_cmd_buffer_emit_pre_draw(struct v3dv_cmd_buffer *cmd_buffer,
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_DS_DEPTH_BOUNDS_TEST_ENABLE) ||
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_RS_DEPTH_BIAS_ENABLE) ||
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_RS_RASTERIZER_DISCARD_ENABLE)) {
v3dv_X(device, cmd_buffer_emit_configuration_bits)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_configuration_bits)(cmd_buffer);
}
if (*dirty & (V3DV_CMD_DIRTY_PIPELINE)) {
v3dv_X(device, cmd_buffer_emit_varyings_state)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_varyings_state)(cmd_buffer);
}
if (BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_VP_SCISSORS) ||
@@ -3003,10 +3003,10 @@ v3dv_cmd_buffer_emit_pre_draw(struct v3dv_cmd_buffer *cmd_buffer,
}
if (BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_VP_VIEWPORTS))
v3dv_X(device, cmd_buffer_emit_viewport)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_viewport)(cmd_buffer);
if (*dirty & V3DV_CMD_DIRTY_INDEX_BUFFER)
v3dv_X(device, cmd_buffer_emit_index_buffer)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_index_buffer)(cmd_buffer);
bool any_dynamic_stencil_dirty =
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_DS_STENCIL_COMPARE_MASK) ||
@@ -3015,38 +3015,38 @@ v3dv_cmd_buffer_emit_pre_draw(struct v3dv_cmd_buffer *cmd_buffer,
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_DS_STENCIL_OP);
if (*dirty & V3DV_CMD_DIRTY_PIPELINE || any_dynamic_stencil_dirty)
v3dv_X(device, cmd_buffer_emit_stencil)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_stencil)(cmd_buffer);
if (*dirty & V3DV_CMD_DIRTY_PIPELINE ||
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_RS_DEPTH_BIAS_FACTORS)) {
v3dv_X(device, cmd_buffer_emit_depth_bias)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_depth_bias)(cmd_buffer);
}
if (BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_DS_DEPTH_BOUNDS_TEST_BOUNDS))
v3dv_X(device, cmd_buffer_emit_depth_bounds)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_depth_bounds)(cmd_buffer);
if (*dirty & V3DV_CMD_DIRTY_PIPELINE ||
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_CB_BLEND_CONSTANTS)) {
v3dv_X(device, cmd_buffer_emit_blend)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_blend)(cmd_buffer);
}
if (*dirty & V3DV_CMD_DIRTY_OCCLUSION_QUERY)
v3dv_X(device, cmd_buffer_emit_occlusion_query)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_occlusion_query)(cmd_buffer);
if (BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_RS_LINE_WIDTH))
v3dv_X(device, cmd_buffer_emit_line_width)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_line_width)(cmd_buffer);
if (dyn->ia.primitive_topology == VK_PRIMITIVE_TOPOLOGY_POINT_LIST &&
!job->emitted_default_point_size) {
v3dv_X(device, cmd_buffer_emit_default_point_size)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_default_point_size)(cmd_buffer);
}
if (*dirty & V3DV_CMD_DIRTY_PIPELINE)
v3dv_X(device, cmd_buffer_emit_sample_state)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_sample_state)(cmd_buffer);
if (*dirty & V3DV_CMD_DIRTY_PIPELINE ||
BITSET_TEST(dyn->dirty, MESA_VK_DYNAMIC_CB_COLOR_WRITE_ENABLES)) {
v3dv_X(device, cmd_buffer_emit_color_write_mask)(cmd_buffer);
v3d_X((&device->devinfo), cmd_buffer_emit_color_write_mask)(cmd_buffer);
}
/* We disable double-buffer mode if indirect draws are used because in that
@@ -3083,7 +3083,7 @@ cmd_buffer_draw(struct v3dv_cmd_buffer *cmd_buffer,
if (likely(!pass->multiview_enabled)) {
cmd_buffer_set_view_index(cmd_buffer, 0);
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, false, false, vertex_count);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw)(cmd_buffer, info);
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw)(cmd_buffer, info);
return;
}
@@ -3091,7 +3091,7 @@ cmd_buffer_draw(struct v3dv_cmd_buffer *cmd_buffer,
while (view_mask) {
cmd_buffer_set_view_index(cmd_buffer, u_bit_scan(&view_mask));
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, false, false, vertex_count);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw)(cmd_buffer, info);
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw)(cmd_buffer, info);
}
}
@@ -3163,7 +3163,7 @@ v3dv_CmdDrawIndexed(VkCommandBuffer commandBuffer,
if (likely(!pass->multiview_enabled)) {
cmd_buffer_set_view_index(cmd_buffer, 0);
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, true, false, vertex_count);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw_indexed)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw_indexed)
(cmd_buffer, indexCount, instanceCount,
firstIndex, vertexOffset, firstInstance);
return;
@@ -3173,7 +3173,7 @@ v3dv_CmdDrawIndexed(VkCommandBuffer commandBuffer,
while (view_mask) {
cmd_buffer_set_view_index(cmd_buffer, u_bit_scan(&view_mask));
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, true, false, vertex_count);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw_indexed)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw_indexed)
(cmd_buffer, indexCount, instanceCount,
firstIndex, vertexOffset, firstInstance);
}
@@ -3205,7 +3205,7 @@ v3dv_CmdDrawMultiIndexedEXT(VkCommandBuffer commandBuffer,
if (likely(!pass->multiview_enabled)) {
cmd_buffer_set_view_index(cmd_buffer, 0);
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, true, false, vertex_count);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw_indexed)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw_indexed)
(cmd_buffer, draw->indexCount, instanceCount,
draw->firstIndex, vertexOffset, firstInstance);
continue;
@@ -3214,7 +3214,7 @@ v3dv_CmdDrawMultiIndexedEXT(VkCommandBuffer commandBuffer,
while (view_mask) {
cmd_buffer_set_view_index(cmd_buffer, u_bit_scan(&view_mask));
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, true, false, vertex_count);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw_indexed)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw_indexed)
(cmd_buffer, draw->indexCount, instanceCount,
draw->firstIndex, vertexOffset, firstInstance);
}
@@ -3239,7 +3239,7 @@ v3dv_CmdDrawIndirect(VkCommandBuffer commandBuffer,
if (likely(!pass->multiview_enabled)) {
cmd_buffer_set_view_index(cmd_buffer, 0);
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, false, true, 0);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw_indirect)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw_indirect)
(cmd_buffer, buffer, offset, drawCount, stride);
return;
}
@@ -3248,7 +3248,7 @@ v3dv_CmdDrawIndirect(VkCommandBuffer commandBuffer,
while (view_mask) {
cmd_buffer_set_view_index(cmd_buffer, u_bit_scan(&view_mask));
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, false, true, 0);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_draw_indirect)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_draw_indirect)
(cmd_buffer, buffer, offset, drawCount, stride);
}
}
@@ -3271,7 +3271,7 @@ v3dv_CmdDrawIndexedIndirect(VkCommandBuffer commandBuffer,
if (likely(!pass->multiview_enabled)) {
cmd_buffer_set_view_index(cmd_buffer, 0);
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, true, true, 0);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_indexed_indirect)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_indexed_indirect)
(cmd_buffer, buffer, offset, drawCount, stride);
return;
}
@@ -3280,7 +3280,7 @@ v3dv_CmdDrawIndexedIndirect(VkCommandBuffer commandBuffer,
while (view_mask) {
cmd_buffer_set_view_index(cmd_buffer, u_bit_scan(&view_mask));
v3dv_cmd_buffer_emit_pre_draw(cmd_buffer, true, true, 0);
v3dv_X(cmd_buffer->device, cmd_buffer_emit_indexed_indirect)
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_emit_indexed_indirect)
(cmd_buffer, buffer, offset, drawCount, stride);
}
}
@@ -4590,7 +4590,7 @@ v3dv_CmdEndRenderingKHR(VkCommandBuffer commandBuffer)
* we will patch the branch address when we know the resuming job.
*/
if (state->suspending)
v3dv_X(cmd_buffer->device, cmd_buffer_suspend)(cmd_buffer);
v3d_X((&cmd_buffer->device->devinfo), cmd_buffer_suspend)(cmd_buffer);
v3dv_cmd_buffer_subpass_finish(cmd_buffer);
v3dv_cmd_buffer_finish_job(cmd_buffer);
+12 -12
View File
@@ -41,7 +41,7 @@ descriptor_bo_map(struct v3dv_device *device,
* descriptor data, so their descriptor BO size is 0 even though they
* do use BO memory.
*/
uint32_t bo_size = v3dv_X(device, descriptor_bo_size)(binding_layout->type);
uint32_t bo_size = v3d_X((&device->devinfo), descriptor_bo_size)(binding_layout->type);
assert(bo_size > 0 ||
binding_layout->type == VK_DESCRIPTOR_TYPE_INLINE_UNIFORM_BLOCK);
@@ -133,7 +133,7 @@ v3dv_descriptor_map_get_descriptor_bo(struct v3dv_device *device,
&set->layout->binding[binding_number];
uint32_t bo_size = v3dv_X(device, descriptor_bo_size)(binding_layout->type);
uint32_t bo_size = v3d_X((&device->devinfo), descriptor_bo_size)(binding_layout->type);
assert(binding_layout->type == VK_DESCRIPTOR_TYPE_INLINE_UNIFORM_BLOCK ||
bo_size > 0);
@@ -225,7 +225,7 @@ v3dv_descriptor_map_get_sampler_state(struct v3dv_device *device,
type == VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER);
if (type == VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER)
reloc.offset += v3dv_X(device, combined_image_sampler_sampler_state_offset)(map->plane[index]);
reloc.offset += v3d_X((&device->devinfo), combined_image_sampler_sampler_state_offset)(map->plane[index]);
return reloc;
}
@@ -283,7 +283,7 @@ v3dv_descriptor_map_get_texture_shader_state(struct v3dv_device *device,
type == VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER);
if (type == VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER)
reloc.offset += v3dv_X(device, combined_image_sampler_texture_state_offset)(map->plane[index]);
reloc.offset += v3d_X((&device->devinfo), combined_image_sampler_texture_state_offset)(map->plane[index]);
return reloc;
}
@@ -493,7 +493,7 @@ v3dv_CreateDescriptorPool(VkDevice _device,
bo_size += pCreateInfo->pPoolSizes[i].descriptorCount;
} else {
descriptor_count += pCreateInfo->pPoolSizes[i].descriptorCount;
bo_size += v3dv_X(device, descriptor_bo_size)(pCreateInfo->pPoolSizes[i].type) *
bo_size += v3d_X((&device->devinfo), descriptor_bo_size)(pCreateInfo->pPoolSizes[i].type) *
pCreateInfo->pPoolSizes[i].descriptorCount;
}
}
@@ -800,7 +800,7 @@ v3dv_CreateDescriptorSetLayout(VkDevice _device,
set_layout->binding[binding_number].descriptor_offset =
set_layout->bo_size;
set_layout->bo_size +=
v3dv_X(device, descriptor_bo_size)(set_layout->binding[binding_number].type) *
v3d_X((&device->devinfo), descriptor_bo_size)(set_layout->binding[binding_number].type) *
binding->descriptorCount * set_layout->binding[binding_number].plane_stride;
} else {
/* We align all our buffers, inline buffers too. We made sure to take
@@ -957,7 +957,7 @@ descriptor_set_create(struct v3dv_device *device,
for (uint8_t plane = 0; plane < samplers[i].plane_count; plane++) {
uint32_t combined_offset =
layout->binding[b].type == VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER ?
v3dv_X(device, combined_image_sampler_sampler_state_offset)(plane) : 0;
v3d_X((&device->devinfo), combined_image_sampler_sampler_state_offset)(plane) : 0;
void *desc_map =
descriptor_bo_map(device, set, &layout->binding[b], i);
desc_map += combined_offset;
@@ -1051,7 +1051,7 @@ descriptor_bo_copy(struct v3dv_device *device,
src_array_index);
memcpy(dst_map, src_map,
v3dv_X(device, descriptor_bo_size)(src_binding_layout->type) *
v3d_X((&device->devinfo), descriptor_bo_size)(src_binding_layout->type) *
src_binding_layout->plane_stride);
}
@@ -1096,7 +1096,7 @@ write_image_descriptor(struct v3dv_device *device,
for (uint8_t plane = 0; plane < plane_count; plane++) {
if (iview) {
uint32_t offset = desc_type == VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER ?
v3dv_X(device, combined_image_sampler_texture_state_offset)(plane) : 0;
v3d_X((&device->devinfo), combined_image_sampler_texture_state_offset)(plane) : 0;
void *plane_desc_map = desc_map + offset;
@@ -1110,7 +1110,7 @@ write_image_descriptor(struct v3dv_device *device,
if (sampler && !binding_layout->immutable_samplers_offset) {
uint32_t offset = desc_type == VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER ?
v3dv_X(device, combined_image_sampler_sampler_state_offset)(plane) : 0;
v3d_X((&device->devinfo), combined_image_sampler_sampler_state_offset)(plane) : 0;
void *plane_desc_map = desc_map + offset;
/* For immutable samplers this was already done as part of the
@@ -1329,7 +1329,7 @@ v3dv_UpdateDescriptorSets(VkDevice _device,
dst_descriptor++;
src_descriptor++;
if (v3dv_X(device, descriptor_bo_size)(src_binding_layout->type) > 0) {
if (v3d_X((&device->devinfo), descriptor_bo_size)(src_binding_layout->type) > 0) {
descriptor_bo_copy(device,
dst_set, dst_binding_layout,
j + copyset->dstArrayElement,
@@ -1369,7 +1369,7 @@ v3dv_GetDescriptorSetLayoutSupport(
break;
}
uint32_t desc_bo_size = v3dv_X(device, descriptor_bo_size)(binding->descriptorType);
uint32_t desc_bo_size = v3d_X((&device->devinfo), descriptor_bo_size)(binding->descriptorType);
if (desc_bo_size > 0 &&
(UINT32_MAX - bo_size) / desc_bo_size < binding->descriptorCount) {
supported = false;
+4 -4
View File
@@ -867,7 +867,7 @@ get_device_properties(const struct v3dv_physical_device *device,
(UINT32_MAX - sizeof(struct v3dv_descriptor_set)) /
sizeof(struct v3dv_descriptor);
const uint32_t max_gpu_descriptors =
(UINT32_MAX / v3dv_X(device, max_descriptor_bo_size)());
(UINT32_MAX / v3d_X((&device->devinfo), max_descriptor_bo_size)());
VkSubgroupFeatureFlags subgroup_ops = VK_SUBGROUP_FEATURE_BASIC_BIT;
if (device->devinfo.ver >= 71) {
@@ -1873,14 +1873,14 @@ v3dv_CreateDevice(VkPhysicalDevice physicalDevice,
#if MESA_DEBUG
v3dv_X(device, device_check_prepacked_sizes)();
v3d_X((&device->devinfo), device_check_prepacked_sizes)();
#endif
init_device_meta(device);
v3dv_bo_cache_init(device);
v3dv_pipeline_cache_init(&device->default_pipeline_cache, device, 0,
device->instance->default_pipeline_cache_enabled);
device->default_attribute_float =
v3dv_X(device, create_default_attribute_values)(device, NULL);
v3d_X((&device->devinfo), create_default_attribute_values)(device, NULL);
device->device_address_mem_ctx = ralloc_context(NULL);
util_dynarray_init(&device->device_address_bo_list,
@@ -2966,7 +2966,7 @@ v3dv_CreateSampler(VkDevice _device,
}
}
v3dv_X(device, pack_sampler_state)(device, sampler, pCreateInfo, bc_info);
v3d_X((&device->devinfo), pack_sampler_state)(device, sampler, pCreateInfo, bc_info);
*pSampler = v3dv_sampler_to_handle(sampler);
+7 -7
View File
@@ -37,7 +37,7 @@
const uint8_t *
v3dv_get_format_swizzle(struct v3dv_device *device, VkFormat f, uint8_t plane)
{
const struct v3dv_format *vf = v3dv_X(device, get_format)(f);
const struct v3dv_format *vf = v3d_X((&device->devinfo), get_format)(f);
static const uint8_t fallback[] = {0, 1, 2, 3};
if (!vf)
@@ -109,9 +109,9 @@ v3dv_get_compatible_tfu_format(struct v3dv_device *device,
if (out_vk_format)
*out_vk_format = vk_format;
const struct v3dv_format *format = v3dv_X(device, get_format)(vk_format);
const struct v3dv_format *format = v3d_X((&device->devinfo), get_format)(vk_format);
assert(format->plane_count == 1);
assert(v3dv_X(device, tfu_supports_tex_format)(format->planes[0].tex_type));
assert(v3d_X((&device->devinfo), tfu_supports_tex_format)(format->planes[0].tex_type));
return format;
}
@@ -256,7 +256,7 @@ image_format_features(struct v3dv_physical_device *pdevice,
}
if (flags & VK_FORMAT_FEATURE_2_COLOR_ATTACHMENT_BIT &&
v3dv_X(pdevice, format_supports_blending)(v3dv_format)) {
v3d_X((&pdevice->devinfo), format_supports_blending)(v3dv_format)) {
flags |= VK_FORMAT_FEATURE_2_COLOR_ATTACHMENT_BLEND_BIT;
}
@@ -323,7 +323,7 @@ v3dv_buffer_format_supports_features(struct v3dv_device *device,
VkFormat vk_format,
VkFormatFeatureFlags2 features)
{
const struct v3dv_format *v3dv_format = v3dv_X(device, get_format)(vk_format);
const struct v3dv_format *v3dv_format = v3d_X((&device->devinfo), get_format)(vk_format);
const VkFormatFeatureFlags2 supported =
buffer_format_features(vk_format, v3dv_format);
return (supported & features) == features;
@@ -335,7 +335,7 @@ v3dv_GetPhysicalDeviceFormatProperties2(VkPhysicalDevice physicalDevice,
VkFormatProperties2 *pFormatProperties)
{
V3DV_FROM_HANDLE(v3dv_physical_device, pdevice, physicalDevice);
const struct v3dv_format *v3dv_format = v3dv_X(pdevice, get_format)(format);
const struct v3dv_format *v3dv_format = v3d_X((&pdevice->devinfo), get_format)(format);
VkFormatFeatureFlags2 linear2, optimal2, buffer2;
linear2 = image_format_features(pdevice, format, v3dv_format,
@@ -421,7 +421,7 @@ get_image_format_properties(
VkImageFormatProperties *pImageFormatProperties,
VkSamplerYcbcrConversionImageFormatProperties *pYcbcrImageFormatProperties)
{
const struct v3dv_format *v3dv_format = v3dv_X(physical_device, get_format)(info->format);
const struct v3dv_format *v3dv_format = v3d_X((&physical_device->devinfo), get_format)(info->format);
VkFormatFeatureFlags2 format_feature_flags =
image_format_features(physical_device, info->format, v3dv_format, tiling);
if (!format_feature_flags)
+8 -8
View File
@@ -461,7 +461,7 @@ v3dv_image_init(struct v3dv_device *device,
: DRM_FORMAT_MOD_LINEAR;
const struct v3dv_format *format =
v3dv_X(device, get_format)(image->vk.format);
v3d_X((&device->devinfo), get_format)(image->vk.format);
v3dv_assert(format != NULL && format->plane_count);
assert(pCreateInfo->samples == VK_SAMPLE_COUNT_1_BIT ||
@@ -818,7 +818,7 @@ create_image_view(struct v3dv_device *device,
}
iview->vk.view_format = format;
iview->format = v3dv_X(device, get_format)(format);
iview->format = v3d_X((&device->devinfo), get_format)(format);
assert(iview->format && iview->format->plane_count);
for (uint8_t plane = 0; plane < iview->plane_count; plane++) {
@@ -829,9 +829,9 @@ create_image_view(struct v3dv_device *device,
if (vk_format_is_depth_or_stencil(iview->vk.view_format)) {
iview->planes[plane].internal_type =
v3dv_X(device, get_internal_depth_type)(iview->vk.view_format);
v3d_X((&device->devinfo), get_internal_depth_type)(iview->vk.view_format);
} else {
v3dv_X(device, get_internal_type_bpp_for_output_format)
v3d_X((&device->devinfo), get_internal_type_bpp_for_output_format)
(iview->format->planes[plane].rt_type,
&iview->planes[plane].internal_type,
&iview->planes[plane].internal_bpp);
@@ -846,7 +846,7 @@ create_image_view(struct v3dv_device *device,
iview->planes[plane].channel_reverse = v3dv_format_swizzle_needs_reverse(format_swizzle);
}
v3dv_X(device, pack_texture_shader_state)(device, iview);
v3d_X((&device->devinfo), pack_texture_shader_state)(device, iview);
*pView = v3dv_image_view_to_handle(iview);
@@ -924,11 +924,11 @@ v3dv_CreateBufferView(VkDevice _device,
view->size = view->offset + range;
view->num_elements = num_elements;
view->vk_format = pCreateInfo->format;
view->format = v3dv_X(device, get_format)(view->vk_format);
view->format = v3d_X((&device->devinfo), get_format)(view->vk_format);
/* We don't support multi-plane formats for buffer views */
assert(view->format->plane_count == 1);
v3dv_X(device, get_internal_type_bpp_for_output_format)
v3d_X((&device->devinfo), get_internal_type_bpp_for_output_format)
(view->format->planes[0].rt_type, &view->internal_type, &view->internal_bpp);
const VkBufferUsageFlags2CreateInfoKHR *flags2 =
@@ -943,7 +943,7 @@ v3dv_CreateBufferView(VkDevice _device,
if (usage & VK_BUFFER_USAGE_UNIFORM_TEXEL_BUFFER_BIT ||
usage & VK_BUFFER_USAGE_STORAGE_TEXEL_BUFFER_BIT)
v3dv_X(device, pack_texture_shader_state_from_buffer_view)(device, view);
v3d_X((&device->devinfo), pack_texture_shader_state_from_buffer_view)(device, view);
*pView = v3dv_buffer_view_to_handle(view);
+5 -5
View File
@@ -46,7 +46,7 @@ get_hw_clear_color(struct v3dv_device *device,
* not the compatible format.
*/
if (fb_format == image_format) {
v3dv_X(device, get_hw_clear_color)(color, internal_type, internal_size,
v3d_X((&device->devinfo), get_hw_clear_color)(color, internal_type, internal_size,
hw_color);
} else {
union util_color uc;
@@ -78,7 +78,7 @@ clear_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
return false;
uint32_t internal_type, internal_bpp;
v3dv_X(cmd_buffer->device, get_internal_type_bpp_for_image_aspects)
v3d_X((&cmd_buffer->device->devinfo), get_internal_type_bpp_for_image_aspects)
(fb_format, range->aspectMask,
&internal_type, &internal_bpp);
@@ -132,18 +132,18 @@ clear_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
image->vk.samples > VK_SAMPLE_COUNT_1_BIT);
struct v3dv_meta_framebuffer framebuffer;
v3dv_X(job->device, meta_framebuffer_init)(&framebuffer, fb_format,
v3d_X((&job->device->devinfo), meta_framebuffer_init)(&framebuffer, fb_format,
internal_type,
&job->frame_tiling);
v3dv_X(job->device, job_emit_binning_flush)(job);
v3d_X((&job->device->devinfo), job_emit_binning_flush)(job);
/* If this triggers it is an application bug: the spec requires
* that any aspects to clear are present in the image.
*/
assert(range->aspectMask & image->vk.aspects);
v3dv_X(job->device, meta_emit_clear_image_rcl)
v3d_X((&job->device->devinfo), meta_emit_clear_image_rcl)
(job, image, &framebuffer, &hw_clear_value,
range->aspectMask, min_layer, max_layer, level);
+24 -24
View File
@@ -449,7 +449,7 @@ copy_image_to_buffer_tlb(struct v3dv_cmd_buffer *cmd_buffer,
}
uint32_t internal_type, internal_bpp;
v3dv_X(cmd_buffer->device, get_internal_type_bpp_for_image_aspects)
v3d_X((&cmd_buffer->device->devinfo), get_internal_type_bpp_for_image_aspects)
(fb_format, region->imageSubresource.aspectMask,
&internal_type, &internal_bpp);
@@ -480,11 +480,11 @@ copy_image_to_buffer_tlb(struct v3dv_cmd_buffer *cmd_buffer,
false);
struct v3dv_meta_framebuffer framebuffer;
v3dv_X(job->device, meta_framebuffer_init)(&framebuffer, fb_format,
v3d_X((&job->device->devinfo), meta_framebuffer_init)(&framebuffer, fb_format,
internal_type, &job->frame_tiling);
v3dv_X(job->device, job_emit_binning_flush)(job);
v3dv_X(job->device, meta_emit_copy_image_to_buffer_rcl)
v3d_X((&job->device->devinfo), job_emit_binning_flush)(job);
v3d_X((&job->device->devinfo), meta_emit_copy_image_to_buffer_rcl)
(job, buffer, image, &framebuffer, region);
v3dv_cmd_buffer_finish_job(cmd_buffer);
@@ -1260,7 +1260,7 @@ copy_image_tfu(struct v3dv_cmd_buffer *cmd_buffer,
const struct v3d_resource_slice *src_slice =
&src->planes[src_plane].slices[src_mip_level];
v3dv_X(cmd_buffer->device, meta_emit_tfu_job)(
v3d_X((&cmd_buffer->device->devinfo), meta_emit_tfu_job)(
cmd_buffer,
dst->planes[dst_plane].mem->bo->handle,
dst_offset,
@@ -1328,7 +1328,7 @@ copy_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
region->dstSubresource.aspectMask ==
region->srcSubresource.aspectMask);
uint32_t internal_type, internal_bpp;
v3dv_X(cmd_buffer->device, get_internal_type_bpp_for_image_aspects)
v3d_X((&cmd_buffer->device->devinfo), get_internal_type_bpp_for_image_aspects)
(fb_format, region->dstSubresource.aspectMask,
&internal_type, &internal_bpp);
@@ -1371,11 +1371,11 @@ copy_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
src->vk.samples > VK_SAMPLE_COUNT_1_BIT);
struct v3dv_meta_framebuffer framebuffer;
v3dv_X(job->device, meta_framebuffer_init)(&framebuffer, fb_format,
v3d_X((&job->device->devinfo), meta_framebuffer_init)(&framebuffer, fb_format,
internal_type, &job->frame_tiling);
v3dv_X(job->device, job_emit_binning_flush)(job);
v3dv_X(job->device, meta_emit_copy_image_rcl)(job, dst, src, &framebuffer, region);
v3d_X((&job->device->devinfo), job_emit_binning_flush)(job);
v3d_X((&job->device->devinfo), meta_emit_copy_image_rcl)(job, dst, src, &framebuffer, region);
v3dv_cmd_buffer_finish_job(cmd_buffer);
@@ -1538,7 +1538,7 @@ copy_image_blit(struct v3dv_cmd_buffer *cmd_buffer,
if (format == VK_FORMAT_UNDEFINED)
return false;
const struct v3dv_format *f = v3dv_X(cmd_buffer->device, get_format)(format);
const struct v3dv_format *f = v3d_X((&cmd_buffer->device->devinfo), get_format)(format);
assert(f->plane_count < 2);
if (!f->plane_count || f->planes[0].tex_type == TEXTURE_DATA_FORMAT_NO)
return false;
@@ -1754,7 +1754,7 @@ v3dv_CmdCopyBuffer2(VkCommandBuffer commandBuffer,
cmd_buffer->state.is_transfer = true;
for (uint32_t i = 0; i < pCopyBufferInfo->regionCount; i++) {
v3dv_X(cmd_buffer->device, meta_copy_buffer)
v3d_X((&cmd_buffer->device->devinfo), meta_copy_buffer)
(cmd_buffer,
dst_buffer->mem->bo, dst_buffer->mem_offset,
src_buffer->mem->bo, src_buffer->mem_offset,
@@ -1810,7 +1810,7 @@ v3dv_CmdUpdateBuffer(VkCommandBuffer commandBuffer,
.size = dataSize,
};
struct v3dv_job *copy_job =
v3dv_X(cmd_buffer->device, meta_copy_buffer)
v3d_X((&cmd_buffer->device->devinfo), meta_copy_buffer)
(cmd_buffer, dst_buffer->mem->bo, dst_buffer->mem_offset,
src_bo, 0, &region);
@@ -1846,7 +1846,7 @@ v3dv_CmdFillBuffer(VkCommandBuffer commandBuffer,
size -= size % 4;
}
v3dv_X(cmd_buffer->device, meta_fill_buffer)
v3d_X((&cmd_buffer->device->devinfo), meta_fill_buffer)
(cmd_buffer, bo, dstOffset, size, data);
cmd_buffer->state.is_transfer = false;
@@ -1963,7 +1963,7 @@ copy_buffer_to_image_tfu(struct v3dv_cmd_buffer *cmd_buffer,
const uint32_t dst_offset =
dst_bo->offset + v3dv_layer_offset(image, mip_level, layer, plane);
v3dv_X(cmd_buffer->device, meta_emit_tfu_job)(
v3d_X((&cmd_buffer->device->devinfo), meta_emit_tfu_job)(
cmd_buffer,
dst_bo->handle,
dst_offset,
@@ -2024,7 +2024,7 @@ copy_buffer_to_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
}
uint32_t internal_type, internal_bpp;
v3dv_X(cmd_buffer->device, get_internal_type_bpp_for_image_aspects)
v3d_X((&cmd_buffer->device->devinfo), get_internal_type_bpp_for_image_aspects)
(fb_format, region->imageSubresource.aspectMask,
&internal_type, &internal_bpp);
@@ -2055,11 +2055,11 @@ copy_buffer_to_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
false);
struct v3dv_meta_framebuffer framebuffer;
v3dv_X(job->device, meta_framebuffer_init)(&framebuffer, fb_format,
v3d_X((&job->device->devinfo), meta_framebuffer_init)(&framebuffer, fb_format,
internal_type, &job->frame_tiling);
v3dv_X(job->device, job_emit_binning_flush)(job);
v3dv_X(job->device, meta_emit_copy_buffer_to_image_rcl)
v3d_X((&job->device->devinfo), job_emit_binning_flush)(job);
v3d_X((&job->device->devinfo), meta_emit_copy_buffer_to_image_rcl)
(job, image, buffer, &framebuffer, region);
v3dv_cmd_buffer_finish_job(cmd_buffer);
@@ -3500,7 +3500,7 @@ blit_tfu(struct v3dv_cmd_buffer *cmd_buffer,
const struct v3d_resource_slice *dst_slice = &dst->planes[0].slices[dst_mip_level];
const struct v3d_resource_slice *src_slice = &src->planes[0].slices[src_mip_level];
v3dv_X(cmd_buffer->device, meta_emit_tfu_job)(
v3d_X((&cmd_buffer->device->devinfo), meta_emit_tfu_job)(
cmd_buffer,
dst->planes[0].mem->bo->handle,
dst_offset,
@@ -4875,7 +4875,7 @@ resolve_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
return false;
}
if (!v3dv_X(cmd_buffer->device, format_supports_tlb_resolve)(src->format))
if (!v3d_X((&cmd_buffer->device->devinfo), format_supports_tlb_resolve)(src->format))
return false;
const VkFormat fb_format = src->vk.format;
@@ -4902,7 +4902,7 @@ resolve_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
const uint32_t height = DIV_ROUND_UP(region->extent.height, block_h);
uint32_t internal_type, internal_bpp;
v3dv_X(cmd_buffer->device, get_internal_type_bpp_for_image_aspects)
v3d_X((&cmd_buffer->device->devinfo), get_internal_type_bpp_for_image_aspects)
(fb_format, region->srcSubresource.aspectMask,
&internal_type, &internal_bpp);
@@ -4911,11 +4911,11 @@ resolve_image_tlb(struct v3dv_cmd_buffer *cmd_buffer,
true);
struct v3dv_meta_framebuffer framebuffer;
v3dv_X(job->device, meta_framebuffer_init)(&framebuffer, fb_format,
v3d_X((&job->device->devinfo), meta_framebuffer_init)(&framebuffer, fb_format,
internal_type, &job->frame_tiling);
v3dv_X(job->device, job_emit_binning_flush)(job);
v3dv_X(job->device, meta_emit_resolve_image_rcl)(job, dst, src,
v3d_X((&job->device->devinfo), job_emit_binning_flush)(job);
v3d_X((&job->device->devinfo), meta_emit_resolve_image_rcl)(job, dst, src,
&framebuffer, region);
v3dv_cmd_buffer_finish_job(cmd_buffer);
+4 -4
View File
@@ -36,8 +36,8 @@ static void
set_try_tlb_resolve(struct v3dv_device *device,
struct v3dv_render_pass_attachment *att)
{
const struct v3dv_format *format = v3dv_X(device, get_format)(att->desc.format);
att->try_tlb_resolve = v3dv_X(device, format_supports_tlb_resolve)(format);
const struct v3dv_format *format = v3d_X((&device->devinfo), get_format)(att->desc.format);
att->try_tlb_resolve = v3d_X((&device->devinfo), format_supports_tlb_resolve)(format);
}
static void
@@ -333,13 +333,13 @@ get_granularity(struct v3dv_device *device,
uint32_t max_internal_bpp = 0;
uint32_t total_color_bpp = 0;
for (int i = 0; i < count; i++) {
const struct v3dv_format *format = v3dv_X(device, get_format)(formats[i]);
const struct v3dv_format *format = v3d_X((&device->devinfo), get_format)(formats[i]);
assert(format);
/* We don't support rendering to YCbCr images */
assert(format->plane_count == 1);
uint32_t internal_type, internal_bpp;
v3dv_X(device, get_internal_type_bpp_for_output_format)
v3d_X((&device->devinfo), get_internal_type_bpp_for_output_format)
(format->planes[0].rt_type, &internal_type, &internal_bpp);
max_internal_bpp = MAX2(max_internal_bpp, internal_bpp);
+5 -5
View File
@@ -2816,7 +2816,7 @@ pipeline_init_dynamic_state(struct v3dv_device *device,
/* FIXME: right now we don't support multiViewport so viewporst[0] would
* work now, but would need to change if we allow multiple viewports.
*/
v3dv_X(device, viewport_compute_xform)(&dyn->vp.viewports[0],
v3d_X((&device->devinfo), viewport_compute_xform)(&dyn->vp.viewports[0],
v3dv_dyn->viewport.scale[0],
v3dv_dyn->viewport.translate[0]);
@@ -2920,7 +2920,7 @@ pipeline_init(struct v3dv_pipeline *pipeline,
if (depth_clip_control)
pipeline->negative_one_to_one = depth_clip_control->negativeOneToOne;
v3dv_X(device, pipeline_pack_state)(pipeline, cb_info, ds_info,
v3d_X((&device->devinfo), pipeline_pack_state)(pipeline, cb_info, ds_info,
rs_info, pv_info, ls_info,
ms_info,
&pipeline_state);
@@ -2945,11 +2945,11 @@ pipeline_init(struct v3dv_pipeline *pipeline,
vk_find_struct_const(vi_info->pNext,
PIPELINE_VERTEX_INPUT_DIVISOR_STATE_CREATE_INFO_EXT);
v3dv_X(device, pipeline_pack_compile_state)(pipeline, vi_info, vd_info);
v3d_X((&device->devinfo), pipeline_pack_compile_state)(pipeline, vi_info, vd_info);
if (v3dv_X(device, pipeline_needs_default_attribute_values)(pipeline)) {
if (v3d_X((&device->devinfo), pipeline_needs_default_attribute_values)(pipeline)) {
pipeline->default_attribute_values =
v3dv_X(pipeline->device, create_default_attribute_values)(pipeline->device, pipeline);
v3d_X((&pipeline->device->devinfo), create_default_attribute_values)(pipeline->device, pipeline);
if (!pipeline->default_attribute_values)
return VK_ERROR_OUT_OF_DEVICE_MEMORY;
-16
View File
@@ -2589,22 +2589,6 @@ u64_compare(const void *key1, const void *key2)
return memcmp(key1, key2, sizeof(uint64_t)) == 0;
}
/* Helper to call hw ver specific functions */
#define v3dv_X(device, thing) ({ \
__typeof(&v3d42_##thing) v3d_X_thing; \
switch (device->devinfo.ver) { \
case 42: \
v3d_X_thing = &v3d42_##thing; \
break; \
case 71: \
v3d_X_thing = &v3d71_##thing; \
break; \
default: \
unreachable("Unsupported hardware generation"); \
} \
v3d_X_thing; \
})
/* v3d_macros from common requires v3dX and V3DX definitions. Below we need to
* define v3dX for each version supported, because when we compile code that
* is not version-specific, all version-specific macros need to be already
+1 -1
View File
@@ -1357,7 +1357,7 @@ v3dv_EnumeratePhysicalDeviceQueueFamilyPerformanceQueryCountersKHR(
{
V3DV_FROM_HANDLE(v3dv_physical_device, pDevice, physicalDevice);
return v3dv_X(pDevice, enumerate_performance_query_counters)(pDevice,
return v3d_X((&pDevice->devinfo), enumerate_performance_query_counters)(pDevice,
pCounterCount,
pCounters,
pCounterDescriptions);
+3 -3
View File
@@ -1182,7 +1182,7 @@ queue_create_noop_job(struct v3dv_queue *queue)
return vk_error(device, VK_ERROR_OUT_OF_HOST_MEMORY);
v3dv_job_init(queue->noop_job, V3DV_JOB_TYPE_GPU_CL, device, NULL, -1);
v3dv_X(device, job_emit_noop)(queue->noop_job);
v3d_X((&device->devinfo), job_emit_noop)(queue->noop_job);
/* We use no-op jobs to signal semaphores/fences. These jobs needs to be
* serialized across all hw queues to comply with Vulkan's signal operation
@@ -1236,7 +1236,7 @@ v3dv_queue_driver_submit(struct vk_queue *vk_queue,
list_for_each_entry_safe(struct v3dv_job, job,
&cmd_buffer->jobs, list_link) {
if (job->suspending) {
job = v3dv_X(job->device,
job = v3d_X((&job->device->devinfo),
cmd_buffer_prepare_suspend_job_for_submit)(job);
if (!job)
return VK_ERROR_OUT_OF_DEVICE_MEMORY;
@@ -1251,7 +1251,7 @@ v3dv_queue_driver_submit(struct vk_queue *vk_queue,
if (job->resuming) {
assert(first_suspend_job);
assert(current_suspend_job);
v3dv_X(job->device, job_patch_resume_address)(first_suspend_job,
v3d_X((&job->device->devinfo), job_patch_resume_address)(first_suspend_job,
current_suspend_job,
job);
current_suspend_job = NULL;