vulkan/instance: Use vk_error in vk_instance_init
authorJason Ekstrand <jason@jlekstrand.net>
Fri, 24 Sep 2021 20:52:04 +0000 (15:52 -0500)
committerMarge Bot <eric+marge@anholt.net>
Thu, 7 Oct 2021 20:51:36 +0000 (20:51 +0000)
commit330f4c9bc918977aae65bbb92504fa4922ced793
tree7a89c687eaed5612eed820fdf3d790ac0c5e3aa1
parentad27db2ae99a1d61152699490dbec6e2f2c19aa0
vulkan/instance: Use vk_error in vk_instance_init

We have to be a bit careful here.  Calling log functions during instance
initialization can be a bit sketchy.  However, we know that __vk_log_impl
only ever touches the callbacks lists if instance->base.client_visible
so it's safe to call vk_error as soon as we've set up instance_callbacks.

Tested-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13045>
src/vulkan/util/vk_instance.c