venus: update venus-protocol headers
authorYiwei Zhang <zzyiwei@chromium.org>
Mon, 12 Apr 2021 21:34:24 +0000 (21:34 +0000)
committerMarge Bot <eric+marge@anholt.net>
Thu, 15 Apr 2021 00:58:00 +0000 (00:58 +0000)
Add support for external memory fd properties query and import
- vkGetMemoryResourcePropertiesMESA
- VkImportMemoryResourceInfoMESA
- VkMemoryResourcePropertiesMESA

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10195>

34 files changed:
src/virtio/venus-protocol/vn_protocol_driver.h
src/virtio/venus-protocol/vn_protocol_driver_buffer.h
src/virtio/venus-protocol/vn_protocol_driver_buffer_view.h
src/virtio/venus-protocol/vn_protocol_driver_command_buffer.h
src/virtio/venus-protocol/vn_protocol_driver_command_pool.h
src/virtio/venus-protocol/vn_protocol_driver_cs.h
src/virtio/venus-protocol/vn_protocol_driver_defines.h
src/virtio/venus-protocol/vn_protocol_driver_descriptor_pool.h
src/virtio/venus-protocol/vn_protocol_driver_descriptor_set.h
src/virtio/venus-protocol/vn_protocol_driver_descriptor_set_layout.h
src/virtio/venus-protocol/vn_protocol_driver_descriptor_update_template.h
src/virtio/venus-protocol/vn_protocol_driver_device.h
src/virtio/venus-protocol/vn_protocol_driver_device_memory.h
src/virtio/venus-protocol/vn_protocol_driver_event.h
src/virtio/venus-protocol/vn_protocol_driver_fence.h
src/virtio/venus-protocol/vn_protocol_driver_framebuffer.h
src/virtio/venus-protocol/vn_protocol_driver_handles.h
src/virtio/venus-protocol/vn_protocol_driver_image.h
src/virtio/venus-protocol/vn_protocol_driver_image_view.h
src/virtio/venus-protocol/vn_protocol_driver_info.h
src/virtio/venus-protocol/vn_protocol_driver_instance.h
src/virtio/venus-protocol/vn_protocol_driver_pipeline.h
src/virtio/venus-protocol/vn_protocol_driver_pipeline_cache.h
src/virtio/venus-protocol/vn_protocol_driver_pipeline_layout.h
src/virtio/venus-protocol/vn_protocol_driver_query_pool.h
src/virtio/venus-protocol/vn_protocol_driver_queue.h
src/virtio/venus-protocol/vn_protocol_driver_render_pass.h
src/virtio/venus-protocol/vn_protocol_driver_sampler.h
src/virtio/venus-protocol/vn_protocol_driver_sampler_ycbcr_conversion.h
src/virtio/venus-protocol/vn_protocol_driver_semaphore.h
src/virtio/venus-protocol/vn_protocol_driver_shader_module.h
src/virtio/venus-protocol/vn_protocol_driver_structs.h
src/virtio/venus-protocol/vn_protocol_driver_transport.h
src/virtio/venus-protocol/vn_protocol_driver_types.h

index e2628ad..b057c42 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index c96db23..b1209f3 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index bcf46a3..7d66023 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index bf05722..7b9f666 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index e3f332a..3802995 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 95b689d..1dc9926 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index ef5bcfe..2f09998 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
@@ -18,6 +18,8 @@
 
 /* VkStructureType */
 #define VK_STRUCTURE_TYPE_RING_CREATE_INFO_MESA ((VkStructureType)1000384000)
+#define VK_STRUCTURE_TYPE_MEMORY_RESOURCE_PROPERTIES_MESA ((VkStructureType)1000384001)
+#define VK_STRUCTURE_TYPE_IMPORT_MEMORY_RESOURCE_INFO_MESA ((VkStructureType)1000384002)
 
 typedef enum VkCommandTypeEXT {
     VK_COMMAND_TYPE_vkCreateInstance_EXT = 0,
@@ -254,6 +256,7 @@ typedef enum VkCommandTypeEXT {
     VK_COMMAND_TYPE_vkDestroyRingMESA_EXT = 189,
     VK_COMMAND_TYPE_vkNotifyRingMESA_EXT = 190,
     VK_COMMAND_TYPE_vkWriteRingExtraMESA_EXT = 191,
+    VK_COMMAND_TYPE_vkGetMemoryResourcePropertiesMESA_EXT = 192,
 } VkCommandTypeEXT;
 
 typedef enum VkCommandFlagBitsEXT {
@@ -296,4 +299,16 @@ typedef struct VkRingCreateInfoMESA {
     size_t extraSize;
 } VkRingCreateInfoMESA;
 
+typedef struct VkMemoryResourcePropertiesMESA {
+    VkStructureType sType;
+    void* pNext;
+    uint32_t memoryTypeBits;
+} VkMemoryResourcePropertiesMESA;
+
+typedef struct VkImportMemoryResourceInfoMESA {
+    VkStructureType sType;
+    const void* pNext;
+    uint32_t resourceId;
+} VkImportMemoryResourceInfoMESA;
+
 #endif /* VN_PROTOCOL_DRIVER_DEFINES_H */
index 7941d03..13c2716 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 9b6fceb..195d9a9 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index fd446bd..8e1800a 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 4cec93c..afced4a 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 8feef22..71d40b8 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index f437a60..fd59a9f 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 292e99e..659075d 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 4026210..8579bbc 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 42d6fae..d2c08fc 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 9ce8aab..8920826 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 67d0474..4a62ce2 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index f842f1d..c41790e 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index e2d7350..449b422 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 7aa9a66..8349bcc 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index d741ff5..61c214d 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 1a2e097..e83cfe8 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 2e86797..7cafb69 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index f2911ed..f854eb9 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 1c0e8d2..63c162a 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 3252eae..82f0417 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index f8333d9..d65fc2b 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index f94adb0..7a3084c 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 65e6921..c435e36 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 2cafb63..de5700b 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 78b6e77..75116ee 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
index 02a203c..7235ea7 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC
@@ -124,6 +124,114 @@ vn_encode_VkRingCreateInfoMESA(struct vn_cs_encoder *enc, const VkRingCreateInfo
     vn_encode_VkRingCreateInfoMESA_self(enc, val);
 }
 
+/* struct VkMemoryResourcePropertiesMESA chain */
+
+static inline size_t
+vn_sizeof_VkMemoryResourcePropertiesMESA_pnext(const void *val)
+{
+    /* no known/supported struct */
+    return vn_sizeof_simple_pointer(NULL);
+}
+
+static inline size_t
+vn_sizeof_VkMemoryResourcePropertiesMESA_self(const VkMemoryResourcePropertiesMESA *val)
+{
+    size_t size = 0;
+    /* skip val->{sType,pNext} */
+    size += vn_sizeof_uint32_t(&val->memoryTypeBits);
+    return size;
+}
+
+static inline size_t
+vn_sizeof_VkMemoryResourcePropertiesMESA(const VkMemoryResourcePropertiesMESA *val)
+{
+    size_t size = 0;
+
+    size += vn_sizeof_VkStructureType(&val->sType);
+    size += vn_sizeof_VkMemoryResourcePropertiesMESA_pnext(val->pNext);
+    size += vn_sizeof_VkMemoryResourcePropertiesMESA_self(val);
+
+    return size;
+}
+
+static inline void
+vn_decode_VkMemoryResourcePropertiesMESA_pnext(struct vn_cs_decoder *dec, const void *val)
+{
+    /* no known/supported struct */
+    if (vn_decode_simple_pointer(dec))
+        assert(false);
+}
+
+static inline void
+vn_decode_VkMemoryResourcePropertiesMESA_self(struct vn_cs_decoder *dec, VkMemoryResourcePropertiesMESA *val)
+{
+    /* skip val->{sType,pNext} */
+    vn_decode_uint32_t(dec, &val->memoryTypeBits);
+}
+
+static inline void
+vn_decode_VkMemoryResourcePropertiesMESA(struct vn_cs_decoder *dec, VkMemoryResourcePropertiesMESA *val)
+{
+    VkStructureType stype;
+    vn_decode_VkStructureType(dec, &stype);
+    assert(stype == VK_STRUCTURE_TYPE_MEMORY_RESOURCE_PROPERTIES_MESA);
+
+    assert(val->sType == stype);
+    vn_decode_VkMemoryResourcePropertiesMESA_pnext(dec, val->pNext);
+    vn_decode_VkMemoryResourcePropertiesMESA_self(dec, val);
+}
+
+static inline size_t
+vn_sizeof_VkMemoryResourcePropertiesMESA_pnext_partial(const void *val)
+{
+    /* no known/supported struct */
+    return vn_sizeof_simple_pointer(NULL);
+}
+
+static inline size_t
+vn_sizeof_VkMemoryResourcePropertiesMESA_self_partial(const VkMemoryResourcePropertiesMESA *val)
+{
+    size_t size = 0;
+    /* skip val->{sType,pNext} */
+    /* skip val->memoryTypeBits */
+    return size;
+}
+
+static inline size_t
+vn_sizeof_VkMemoryResourcePropertiesMESA_partial(const VkMemoryResourcePropertiesMESA *val)
+{
+    size_t size = 0;
+
+    size += vn_sizeof_VkStructureType(&val->sType);
+    size += vn_sizeof_VkMemoryResourcePropertiesMESA_pnext_partial(val->pNext);
+    size += vn_sizeof_VkMemoryResourcePropertiesMESA_self_partial(val);
+
+    return size;
+}
+
+static inline void
+vn_encode_VkMemoryResourcePropertiesMESA_pnext_partial(struct vn_cs_encoder *enc, const void *val)
+{
+    /* no known/supported struct */
+    vn_encode_simple_pointer(enc, NULL);
+}
+
+static inline void
+vn_encode_VkMemoryResourcePropertiesMESA_self_partial(struct vn_cs_encoder *enc, const VkMemoryResourcePropertiesMESA *val)
+{
+    /* skip val->{sType,pNext} */
+    /* skip val->memoryTypeBits */
+}
+
+static inline void
+vn_encode_VkMemoryResourcePropertiesMESA_partial(struct vn_cs_encoder *enc, const VkMemoryResourcePropertiesMESA *val)
+{
+    assert(val->sType == VK_STRUCTURE_TYPE_MEMORY_RESOURCE_PROPERTIES_MESA);
+    vn_encode_VkStructureType(enc, &(VkStructureType){ VK_STRUCTURE_TYPE_MEMORY_RESOURCE_PROPERTIES_MESA });
+    vn_encode_VkMemoryResourcePropertiesMESA_pnext_partial(enc, val->pNext);
+    vn_encode_VkMemoryResourcePropertiesMESA_self_partial(enc, val);
+}
+
 static inline size_t vn_sizeof_vkSetReplyCommandStreamMESA(const VkCommandStreamDescriptionMESA* pStream)
 {
     const VkCommandTypeEXT cmd_type = VK_COMMAND_TYPE_vkSetReplyCommandStreamMESA_EXT;
@@ -484,6 +592,69 @@ static inline void vn_decode_vkWriteRingExtraMESA_reply(struct vn_cs_decoder *de
     /* skip value */
 }
 
+static inline size_t vn_sizeof_vkGetMemoryResourcePropertiesMESA(VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties)
+{
+    const VkCommandTypeEXT cmd_type = VK_COMMAND_TYPE_vkGetMemoryResourcePropertiesMESA_EXT;
+    const VkFlags cmd_flags = 0;
+    size_t cmd_size = vn_sizeof_VkCommandTypeEXT(&cmd_type) + vn_sizeof_VkFlags(&cmd_flags);
+
+    cmd_size += vn_sizeof_VkDevice(&device);
+    cmd_size += vn_sizeof_uint32_t(&resourceId);
+    cmd_size += vn_sizeof_simple_pointer(pMemoryResourceProperties);
+    if (pMemoryResourceProperties)
+        cmd_size += vn_sizeof_VkMemoryResourcePropertiesMESA_partial(pMemoryResourceProperties);
+
+    return cmd_size;
+}
+
+static inline void vn_encode_vkGetMemoryResourcePropertiesMESA(struct vn_cs_encoder *enc, VkCommandFlagsEXT cmd_flags, VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties)
+{
+    const VkCommandTypeEXT cmd_type = VK_COMMAND_TYPE_vkGetMemoryResourcePropertiesMESA_EXT;
+
+    vn_encode_VkCommandTypeEXT(enc, &cmd_type);
+    vn_encode_VkFlags(enc, &cmd_flags);
+
+    vn_encode_VkDevice(enc, &device);
+    vn_encode_uint32_t(enc, &resourceId);
+    if (vn_encode_simple_pointer(enc, pMemoryResourceProperties))
+        vn_encode_VkMemoryResourcePropertiesMESA_partial(enc, pMemoryResourceProperties);
+}
+
+static inline size_t vn_sizeof_vkGetMemoryResourcePropertiesMESA_reply(VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties)
+{
+    const VkCommandTypeEXT cmd_type = VK_COMMAND_TYPE_vkGetMemoryResourcePropertiesMESA_EXT;
+    size_t cmd_size = vn_sizeof_VkCommandTypeEXT(&cmd_type);
+
+    VkResult ret;
+    cmd_size += vn_sizeof_VkResult(&ret);
+    /* skip device */
+    /* skip resourceId */
+    cmd_size += vn_sizeof_simple_pointer(pMemoryResourceProperties);
+    if (pMemoryResourceProperties)
+        cmd_size += vn_sizeof_VkMemoryResourcePropertiesMESA(pMemoryResourceProperties);
+
+    return cmd_size;
+}
+
+static inline VkResult vn_decode_vkGetMemoryResourcePropertiesMESA_reply(struct vn_cs_decoder *dec, VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties)
+{
+    VkCommandTypeEXT command_type;
+    vn_decode_VkCommandTypeEXT(dec, &command_type);
+    assert(command_type == VK_COMMAND_TYPE_vkGetMemoryResourcePropertiesMESA_EXT);
+
+    VkResult ret;
+    vn_decode_VkResult(dec, &ret);
+    /* skip device */
+    /* skip resourceId */
+    if (vn_decode_simple_pointer(dec)) {
+        vn_decode_VkMemoryResourcePropertiesMESA(dec, pMemoryResourceProperties);
+    } else {
+        pMemoryResourceProperties = NULL;
+    }
+
+    return ret;
+}
+
 static inline void vn_submit_vkSetReplyCommandStreamMESA(struct vn_instance *vn_instance, VkCommandFlagsEXT cmd_flags, const VkCommandStreamDescriptionMESA* pStream, struct vn_instance_submit_command *submit)
 {
     uint8_t local_cmd_data[VN_SUBMIT_LOCAL_CMD_SIZE];
@@ -631,6 +802,27 @@ static inline void vn_submit_vkWriteRingExtraMESA(struct vn_instance *vn_instanc
         free(cmd_data);
 }
 
+static inline void vn_submit_vkGetMemoryResourcePropertiesMESA(struct vn_instance *vn_instance, VkCommandFlagsEXT cmd_flags, VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties, struct vn_instance_submit_command *submit)
+{
+    uint8_t local_cmd_data[VN_SUBMIT_LOCAL_CMD_SIZE];
+    void *cmd_data = local_cmd_data;
+    size_t cmd_size = vn_sizeof_vkGetMemoryResourcePropertiesMESA(device, resourceId, pMemoryResourceProperties);
+    if (cmd_size > sizeof(local_cmd_data)) {
+        cmd_data = malloc(cmd_size);
+        if (!cmd_data)
+            cmd_size = 0;
+    }
+
+    submit->command = VN_CS_ENCODER_INITIALIZER(cmd_data, cmd_size);
+    if (cmd_size)
+        vn_encode_vkGetMemoryResourcePropertiesMESA(&submit->command, cmd_flags, device, resourceId, pMemoryResourceProperties);
+    submit->reply_size = cmd_flags & VK_COMMAND_GENERATE_REPLY_BIT_EXT ? vn_sizeof_vkGetMemoryResourcePropertiesMESA_reply(device, resourceId, pMemoryResourceProperties) : 0;
+    vn_instance_submit_command(vn_instance, submit);
+
+    if (cmd_data != local_cmd_data)
+        free(cmd_data);
+}
+
 static inline void vn_call_vkSetReplyCommandStreamMESA(struct vn_instance *vn_instance, const VkCommandStreamDescriptionMESA* pStream)
 {
     struct vn_instance_submit_command submit;
@@ -743,4 +935,23 @@ static inline void vn_async_vkWriteRingExtraMESA(struct vn_instance *vn_instance
     vn_submit_vkWriteRingExtraMESA(vn_instance, 0, ring, offset, value, &submit);
 }
 
+static inline VkResult vn_call_vkGetMemoryResourcePropertiesMESA(struct vn_instance *vn_instance, VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties)
+{
+    struct vn_instance_submit_command submit;
+    vn_submit_vkGetMemoryResourcePropertiesMESA(vn_instance, VK_COMMAND_GENERATE_REPLY_BIT_EXT, device, resourceId, pMemoryResourceProperties, &submit);
+    if (submit.reply_bo) {
+        const VkResult ret = vn_decode_vkGetMemoryResourcePropertiesMESA_reply(&submit.reply, device, resourceId, pMemoryResourceProperties);
+        vn_renderer_bo_unref(submit.reply_bo);
+        return ret;
+    } else {
+        return VK_ERROR_OUT_OF_HOST_MEMORY;
+    }
+}
+
+static inline void vn_async_vkGetMemoryResourcePropertiesMESA(struct vn_instance *vn_instance, VkDevice device, uint32_t resourceId, VkMemoryResourcePropertiesMESA* pMemoryResourceProperties)
+{
+    struct vn_instance_submit_command submit;
+    vn_submit_vkGetMemoryResourcePropertiesMESA(vn_instance, 0, device, resourceId, pMemoryResourceProperties, &submit);
+}
+
 #endif /* VN_PROTOCOL_DRIVER_TRANSPORT_H */
index bfea8f6..de85cf5 100644 (file)
@@ -1,4 +1,4 @@
-/* This file is generated by venus-protocol git-2564dba1. */
+/* This file is generated by venus-protocol git-e05ae158. */
 
 /*
  * Copyright 2020 Google LLC