Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
PojavLauncherTeam
GitHub Repository: PojavLauncherTeam/mesa
Path: blob/21.2-virgl/src/virtio/venus-protocol/vn_protocol_driver_info.h
4560 views
1
/* This file is generated by venus-protocol. See vn_protocol_driver.h. */
2
3
/*
4
* Copyright 2020 Google LLC
5
* SPDX-License-Identifier: MIT
6
*/
7
8
#ifndef VN_PROTOCOL_DRIVER_INFO_H
9
#define VN_PROTOCOL_DRIVER_INFO_H
10
11
#include "vn_protocol_driver_defines.h"
12
13
static inline uint32_t
14
vn_info_wire_format_version(void)
15
{
16
return 0;
17
}
18
19
static inline uint32_t
20
vn_info_vk_xml_version(void)
21
{
22
return VK_MAKE_VERSION(1, 2, 168);
23
}
24
25
static inline int
26
vn_info_extension_compare(const void *a, const void *b)
27
{
28
return strcmp(a, *(const char **)b);
29
}
30
31
static inline uint32_t
32
vn_info_extension_spec_version(const char *name)
33
{
34
static uint32_t ext_count = 54;
35
static const char *ext_names[54] = {
36
"VK_EXT_command_serialization",
37
"VK_EXT_descriptor_indexing",
38
"VK_EXT_external_memory_dma_buf",
39
"VK_EXT_host_query_reset",
40
"VK_EXT_image_drm_format_modifier",
41
"VK_EXT_queue_family_foreign",
42
"VK_EXT_sampler_filter_minmax",
43
"VK_EXT_scalar_block_layout",
44
"VK_EXT_separate_stencil_usage",
45
"VK_EXT_shader_viewport_index_layer",
46
"VK_EXT_transform_feedback",
47
"VK_KHR_16bit_storage",
48
"VK_KHR_8bit_storage",
49
"VK_KHR_bind_memory2",
50
"VK_KHR_buffer_device_address",
51
"VK_KHR_create_renderpass2",
52
"VK_KHR_dedicated_allocation",
53
"VK_KHR_depth_stencil_resolve",
54
"VK_KHR_descriptor_update_template",
55
"VK_KHR_device_group",
56
"VK_KHR_device_group_creation",
57
"VK_KHR_draw_indirect_count",
58
"VK_KHR_driver_properties",
59
"VK_KHR_external_fence",
60
"VK_KHR_external_fence_capabilities",
61
"VK_KHR_external_memory",
62
"VK_KHR_external_memory_capabilities",
63
"VK_KHR_external_memory_fd",
64
"VK_KHR_external_semaphore",
65
"VK_KHR_external_semaphore_capabilities",
66
"VK_KHR_get_memory_requirements2",
67
"VK_KHR_get_physical_device_properties2",
68
"VK_KHR_image_format_list",
69
"VK_KHR_imageless_framebuffer",
70
"VK_KHR_maintenance1",
71
"VK_KHR_maintenance2",
72
"VK_KHR_maintenance3",
73
"VK_KHR_multiview",
74
"VK_KHR_relaxed_block_layout",
75
"VK_KHR_sampler_mirror_clamp_to_edge",
76
"VK_KHR_sampler_ycbcr_conversion",
77
"VK_KHR_separate_depth_stencil_layouts",
78
"VK_KHR_shader_atomic_int64",
79
"VK_KHR_shader_draw_parameters",
80
"VK_KHR_shader_float16_int8",
81
"VK_KHR_shader_float_controls",
82
"VK_KHR_shader_subgroup_extended_types",
83
"VK_KHR_spirv_1_4",
84
"VK_KHR_storage_buffer_storage_class",
85
"VK_KHR_timeline_semaphore",
86
"VK_KHR_uniform_buffer_standard_layout",
87
"VK_KHR_variable_pointers",
88
"VK_KHR_vulkan_memory_model",
89
"VK_MESA_venus_protocol",
90
};
91
static const uint32_t ext_versions[54] = {
92
0,
93
2,
94
1,
95
1,
96
1,
97
1,
98
2,
99
1,
100
1,
101
1,
102
1,
103
1,
104
1,
105
1,
106
1,
107
1,
108
3,
109
1,
110
1,
111
4,
112
1,
113
1,
114
1,
115
1,
116
1,
117
1,
118
1,
119
1,
120
1,
121
1,
122
1,
123
2,
124
1,
125
1,
126
2,
127
1,
128
1,
129
1,
130
1,
131
3,
132
14,
133
1,
134
1,
135
1,
136
1,
137
4,
138
1,
139
1,
140
1,
141
2,
142
1,
143
1,
144
3,
145
100000,
146
};
147
const char **found;
148
149
found = bsearch(name, ext_names, ext_count, sizeof(ext_names[0]),
150
vn_info_extension_compare);
151
152
return found ? ext_versions[found - ext_names] : 0;
153
}
154
155
#endif /* VN_PROTOCOL_DRIVER_INFO_H */
156
157