v3dv: fix the command buffer private object framework for 32-bit

Graphics / Mesa 3D Graphics Library / Mesa - Iago Toral Quiroga [igalia.com] - 13 October 2020 21:21 UTC

We were declaring the destroy callback function as taking a pointer for the
vulkan object handle and relying on an implicit conversion to the Vulkan handle type, however that would be incorrect on 32-bit platforms, where non-dispatchable Vulkan objects (the kind that we may allocate privately during command buffer recording), are defined as uint64_t, so the signature of the destry callback type doesn't match the signature of the actual Vulkan function, leading to bogus results. Fix that by using uint64_t instead.

This fixes compilation warnings and also crashes in some tests when compiling and executing natively in Rpi4.

Part-of:

ce681aac70f v3dv: fix the command buffer private object framework for 32-bit
src/broadcom/vulkan/v3dv_cmd_buffer.c | 2 +-
src/broadcom/vulkan/v3dv_meta_clear.c | 4 ++--
src/broadcom/vulkan/v3dv_meta_copy.c | 14 +++++++-------
src/broadcom/vulkan/v3dv_private.h | 6 +++---
4 files changed, 13 insertions(+), 13 deletions(-)

Upstream: cgit.freedesktop.org


  • Share