radv: track and report if a logical device is lost
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Mon, 13 Jul 2020 11:59:48 +0000 (13:59 +0200)
committerMarge Bot <eric+marge@anholt.net>
Wed, 19 Aug 2020 07:57:51 +0000 (07:57 +0000)
commitd26f62c667099fc3d30a3155335ca4f0e73c8d88
tree2b763ee3befc9c63b73ba364b3352221848d4693
parentc9c53dade01ede6d6ab0a3b280dc309cf1dd317c
radv: track and report if a logical device is lost

This currently covers two situations where it's obvious that
the GPU hung:

1) when wait-of-idle doesn't finish in a finite time
2) when a CS submission is cancelled by the kernel

There is still probably some other situations that aren't yet handled.

According to the Vulkan spec, some operations should return
VK_ERROR_DEVICE_LOST when the corresponding logical device is
known to be lost.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5878>
src/amd/vulkan/radv_device.c
src/amd/vulkan/radv_private.h
src/amd/vulkan/radv_query.c