turnip: Add missing VKAPI_ATTR annotations

Make sure the types match.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4478>
This commit is contained in:
Kristian H. Kristensen 2020-04-07 08:45:03 -07:00 committed by Marge Bot
parent 80c13a81b1
commit e99f6f2ea1
3 changed files with 5 additions and 5 deletions

View file

@ -338,7 +338,7 @@ tu_physical_device_finish(struct tu_physical_device *device)
close(device->master_fd);
}
static void *
static VKAPI_ATTR void *
default_alloc_func(void *pUserData,
size_t size,
size_t align,
@ -347,7 +347,7 @@ default_alloc_func(void *pUserData,
return malloc(size);
}
static void *
static VKAPI_ATTR void *
default_realloc_func(void *pUserData,
void *pOriginal,
size_t size,
@ -357,7 +357,7 @@ default_realloc_func(void *pUserData,
return realloc(pOriginal, size);
}
static void
static VKAPI_ATTR void
default_free_func(void *pUserData, void *pMemory)
{
free(pMemory);

View file

@ -75,7 +75,7 @@ struct tu_dispatch_table {
#ifdef ${e.guard}
% endif
% for layer in LAYERS:
${e.return_type} ${e.prefixed_name(layer)}(${e.decl_params()});
VKAPI_ATTR ${e.return_type} ${e.prefixed_name(layer)}(${e.decl_params()});
% endfor
% if e.guard is not None:
#endif // ${e.guard}

View file

@ -29,7 +29,7 @@
#include "wsi_common.h"
#include "drm-uapi/drm_fourcc.h"
static PFN_vkVoidFunction
static VKAPI_PTR PFN_vkVoidFunction
tu_wsi_proc_addr(VkPhysicalDevice physicalDevice, const char *pName)
{
return tu_lookup_entrypoint_unchecked(pName);