diff options
author | Eric Engestrom <[email protected]> | 2019-04-24 16:42:25 +0100 |
---|---|---|
committer | Eric Engestrom <[email protected]> | 2019-09-06 23:16:05 +0100 |
commit | 4dcb1fff19383ae451f3228e55d3fc987a7ab46d (patch) | |
tree | bc2bd1bc0ac69cced57f329974d4aff436913df4 /src/intel/vulkan/anv_device.c | |
parent | ba73564b520d6a6b48f00d68702f20fca8a2ce4e (diff) |
anv: add support for driconf
No option is supported yet, this is just the boilerplate.
Cc: [email protected]
Signed-off-by: Eric Engestrom <[email protected]>
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Reviewed-by: Lionel Landwerlin <[email protected]>
Diffstat (limited to 'src/intel/vulkan/anv_device.c')
-rw-r--r-- | src/intel/vulkan/anv_device.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c index 3497a01f900..3363c8fa791 100644 --- a/src/intel/vulkan/anv_device.c +++ b/src/intel/vulkan/anv_device.c @@ -40,6 +40,7 @@ #include "util/os_file.h" #include "util/u_atomic.h" #include "util/u_string.h" +#include "util/xmlpool.h" #include "git_sha1.h" #include "vk_util.h" #include "common/gen_defines.h" @@ -47,6 +48,10 @@ #include "genxml/gen7_pack.h" +static const char anv_dri_options_xml[] = +DRI_CONF_BEGIN +DRI_CONF_END; + /* This is probably far to big but it reflects the max size used for messages * in OpenGLs KHR_debug. */ @@ -770,6 +775,10 @@ VkResult anv_CreateInstance( VG(VALGRIND_CREATE_MEMPOOL(instance, 0, false)); + driParseOptionInfo(&instance->available_dri_options, anv_dri_options_xml); + driParseConfigFiles(&instance->dri_options, &instance->available_dri_options, + 0, "anv", NULL); + *pInstance = anv_instance_to_handle(instance); return VK_SUCCESS; @@ -800,6 +809,9 @@ void anv_DestroyInstance( glsl_type_singleton_decref(); _mesa_locale_fini(); + driDestroyOptionCache(&instance->dri_options); + driDestroyOptionInfo(&instance->available_dri_options); + vk_free(&instance->alloc, instance); } |